Skip to content
Snippets Groups Projects
Unverified Commit 5f62a094 authored by David Robertson's avatar David Robertson Committed by GitHub
Browse files

Detox, part 1 of N (#12119)

* Don't use `tox` for `check-sampleconfig`
* Don't use `tox` for check-newsfragment
parent 313581e4
No related branches found
No related tags found
No related merge requests found
...@@ -10,12 +10,19 @@ concurrency: ...@@ -10,12 +10,19 @@ concurrency:
cancel-in-progress: true cancel-in-progress: true
jobs: jobs:
check-sampleconfig:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
- run: pip install -e .
- run: scripts-dev/generate_sample_config --check
lint: lint:
runs-on: ubuntu-latest runs-on: ubuntu-latest
strategy: strategy:
matrix: matrix:
toxenv: toxenv:
- "check-sampleconfig"
- "check_codestyle" - "check_codestyle"
- "check_isort" - "check_isort"
- "mypy" - "mypy"
...@@ -43,7 +50,7 @@ jobs: ...@@ -43,7 +50,7 @@ jobs:
ref: ${{ github.event.pull_request.head.sha }} ref: ${{ github.event.pull_request.head.sha }}
fetch-depth: 0 fetch-depth: 0
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2
- run: pip install tox - run: "pip install 'towncrier>=18.6.0rc1'"
- run: scripts-dev/check-newsfragment - run: scripts-dev/check-newsfragment
env: env:
PULL_REQUEST_NUMBER: ${{ github.event.number }} PULL_REQUEST_NUMBER: ${{ github.event.number }}
...@@ -51,7 +58,7 @@ jobs: ...@@ -51,7 +58,7 @@ jobs:
# Dummy step to gate other tests on without repeating the whole list # Dummy step to gate other tests on without repeating the whole list
linting-done: linting-done:
if: ${{ !cancelled() }} # Run this even if prior jobs were skipped if: ${{ !cancelled() }} # Run this even if prior jobs were skipped
needs: [lint, lint-crlf, lint-newsfile] needs: [lint, lint-crlf, lint-newsfile, check-sampleconfig]
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- run: "true" - run: "true"
......
Move CI checks out of tox, to facilitate a move to using poetry.
\ No newline at end of file
...@@ -35,7 +35,7 @@ CONTRIBUTING_GUIDE_TEXT="!! Please see the contributing guide for help writing y ...@@ -35,7 +35,7 @@ CONTRIBUTING_GUIDE_TEXT="!! Please see the contributing guide for help writing y
https://github.com/matrix-org/synapse/blob/develop/CONTRIBUTING.md#changelog" https://github.com/matrix-org/synapse/blob/develop/CONTRIBUTING.md#changelog"
# If check-newsfragment returns a non-zero exit code, print the contributing guide and exit # If check-newsfragment returns a non-zero exit code, print the contributing guide and exit
tox -qe check-newsfragment || (echo -e "$CONTRIBUTING_GUIDE_TEXT" >&2 && exit 1) python -m towncrier.check --compare-with=origin/develop || (echo -e "$CONTRIBUTING_GUIDE_TEXT" >&2 && exit 1)
echo echo
echo "--------------------------" echo "--------------------------"
......
...@@ -168,16 +168,6 @@ commands = ...@@ -168,16 +168,6 @@ commands =
extras = lint extras = lint
commands = isort -c --df {[base]lint_targets} commands = isort -c --df {[base]lint_targets}
[testenv:check-newsfragment]
skip_install = true
usedevelop = false
deps = towncrier>=18.6.0rc1
commands =
python -m towncrier.check --compare-with=origin/develop
[testenv:check-sampleconfig]
commands = {toxinidir}/scripts-dev/generate_sample_config --check
[testenv:combine] [testenv:combine]
skip_install = true skip_install = true
usedevelop = false usedevelop = false
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment