Skip to content

Commit ac454e5

Browse files
committed
Further optimize tox run by requiring fewer dependencies
1 parent 1b48445 commit ac454e5

File tree

3 files changed

+12
-13
lines changed

3 files changed

+12
-13
lines changed

.github/workflows/ci.yml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,13 @@ jobs:
2929
${{ runner.os }}-node-
3030
- run: npm install --no-optional --no-audit --no-fund --progress=false
3131
- run: npm run lint
32+
- run: make test-coverage
33+
- run: |
34+
pip install coveralls==3.0.1
35+
coveralls || true
36+
env:
37+
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
38+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
3239
test_compat:
3340
needs: test
3441
runs-on: ubuntu-latest
@@ -42,7 +49,7 @@ jobs:
4249
- python: "3.8"
4350
toxenv: py38-lower_bound_deps,py38-upper_bound_deps
4451
- python: "3.9"
45-
toxenv: py39-lower_bound_deps,py39-upper_bound_deps
52+
toxenv: py39-lower_bound_deps
4653
- python: "3.10.0-alpha.6"
4754
toxenv: py310-upper_bound_deps
4855
steps:
@@ -55,10 +62,3 @@ jobs:
5562
- run: tox --parallel
5663
env:
5764
TOXENV: ${{ matrix.toxenv }}
58-
- run: |
59-
pip install coveralls==3.0.1
60-
coveralls || true
61-
if: ${{ matrix.python == '3.9' }}
62-
env:
63-
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
64-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,10 @@ test: ## Test the project.
2626
python -X dev -W error -m unittest discover
2727

2828
test-watch: ## Restarts the tests whenever a file changes.
29-
nodemon -q -e py -w tests -w draftjs_exporter -x "clear && make test -s || true"
29+
PYTHONDEVMODE=1 nodemon -q -e py -w tests -w draftjs_exporter -x "clear && make test -s || true"
3030

3131
test-coverage: ## Run the tests while generating test coverage data.
32-
coverage run -m unittest discover && coverage report && coverage html
32+
PYTHONDEVMODE=1 coverage run -m unittest discover && coverage report
3333

3434
test-ci: ## Continuous integration test suite.
3535
tox

tox.ini

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,7 @@ usedevelop = True
88
envlist = py{36,37,38,39,310}-{lower_bound_deps,upper_bound_deps}
99

1010
[testenv]
11-
whitelist_externals = make
12-
install_command = pip install -r requirements.txt {opts} {packages}
11+
install_command = pip install {opts} {packages}
1312

1413
basepython =
1514
py36: python3.6
@@ -30,4 +29,4 @@ deps =
3029
upper_bound_deps: lxml<5
3130

3231
commands =
33-
make test-coverage
32+
python -m unittest discover

0 commit comments

Comments
 (0)