Skip to content

Commit ddc4b9f

Browse files
committed
Switch from abandoned nose to pytest to support Python 3.10
1 parent 19772d2 commit ddc4b9f

File tree

4 files changed

+10
-12
lines changed

4 files changed

+10
-12
lines changed

Diff for: .github/workflows/pythonpackage.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
with:
2323
fetch-depth: 1000
2424
- name: Set up Python ${{ matrix.python-version }}
25-
uses: actions/setup-python@v1
25+
uses: actions/setup-python@v2
2626
with:
2727
python-version: ${{ matrix.python-version }}
2828
- name: Install dependencies
@@ -35,9 +35,9 @@ jobs:
3535
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
3636
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
3737
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
38-
- name: Test with nose
38+
- name: Test
3939
run: |
40-
pip install nose
40+
pip install pytest
4141
ulimit -n 48
4242
ulimit -n
43-
nosetests -v
43+
pytest -v

Diff for: Makefile

+3-3
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,11 @@ clean-files:
2424
clean: clean-files clean-docs
2525

2626
test:
27-
nosetests
27+
pytest
2828

2929
coverage:
30-
nosetests --with-coverage --cover-package=smmap
31-
30+
pytest --cov smmap --cov-report xml
31+
3232
build:
3333
./setup.py build
3434

Diff for: setup.py

-2
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,4 @@
4747
],
4848
long_description=long_description,
4949
long_description_content_type='text/markdown',
50-
tests_require=('nose', 'nosexcover'),
51-
test_suite='nose.collector'
5250
)

Diff for: tox.ini

+3-3
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@
77
envlist = flake8, py36, py37, py38, py39, py310
88

99
[testenv]
10-
commands = nosetests {posargs:--with-coverage --cover-package=smmap}
10+
commands = {envpython} -m pytest --cov smmap --cov-report xml {posargs}
1111
deps =
12-
nose
13-
nosexcover
12+
pytest
13+
pytest-cov
1414

1515
[testenv:flake8]
1616
commands = flake8 {posargs}

0 commit comments

Comments
 (0)