Skip to content

Commit 6e19835

Browse files
authored
fix build (#6)
* fix build and updates * drop 3.11
1 parent ba39b7a commit 6e19835

File tree

6 files changed

+25
-18
lines changed

6 files changed

+25
-18
lines changed

.github/workflows/release.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@ jobs:
66
release:
77
runs-on: ubuntu-latest
88
steps:
9-
- uses: actions/checkout@v2
10-
- name: Set up Python 3.7
11-
uses: actions/setup-python@v2
9+
- uses: actions/checkout@v3
10+
- name: Set up Python 3.10
11+
uses: actions/setup-python@v4
1212
with:
13-
python-version: 3.7
13+
python-version: '3.10'
1414
- run: pip install -U nox
1515
- run: nox -s build
1616
- uses: pypa/gh-action-pypi-publish@master

.github/workflows/tests.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ jobs:
88
python-version: ['3.7', '3.8', '3.9', '3.10']
99
name: Python ${{ matrix.python-version }}
1010
steps:
11-
- uses: actions/checkout@v2
12-
- uses: actions/setup-python@v2
11+
- uses: actions/checkout@v3
12+
- uses: actions/setup-python@v4
1313
with:
1414
python-version: ${{ matrix.python-version }}
1515
- run: pip install -U nox

.pre-commit-config.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@ repos:
33
- id: black
44
language_version: python3
55
repo: https://github.com/psf/black
6-
rev: 22.3.0
6+
rev: 22.6.0
77
- repo: https://github.com/pre-commit/pre-commit-hooks
8-
rev: v4.0.1
8+
rev: v4.3.0
99
hooks:
1010
- id: check-toml
1111
- id: check-yaml

noxfile.py

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
"""Automation using nox.
22
"""
33
import glob
4+
import sys
45

56
import nox
67

78
nox.options.reuse_existing_virtualenvs = True
8-
nox.options.sessions = "lint", "tests", "tests-pytest5"
9+
nox.options.sessions = "lint", "tests", "compat"
910
locations = "pytest_test_utils", "tests.py"
1011

1112

@@ -18,10 +19,11 @@ def tests(session: nox.Session) -> None:
1819
session.run("coverage", "report", "--show-missing", "--skip-covered")
1920

2021

21-
@nox.session(python=["3.7"], name="tests-pytest5")
22-
def tests_pytest5(session: nox.Session) -> None:
22+
@nox.session(python=["3.7", "3.8"])
23+
@nox.parametrize("pytest", ["5", "6"])
24+
def compat(session: nox.Session, pytest: str) -> None:
2325
session.install(".[tests]")
24-
session.install("pytest==5.0.0")
26+
session.install(f"pytest=={pytest}")
2527
session.run("coverage", "run", "-m", "pytest", "tests.py")
2628

2729

@@ -37,6 +39,8 @@ def lint(session: nox.Session) -> None:
3739

3840
session.run("pre-commit", "run", *args)
3941
session.run("python", "-m", "mypy")
42+
if sys.version_info >= (3, 11):
43+
return
4044
session.run("python", "-m", "pylint", *locations)
4145

4246

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[build-system]
2-
requires = ["setuptools>=48", "wheel"]
2+
requires = ["setuptools>=48"]
33
build-backend = "setuptools.build_meta"
44

55
[tool.black]

setup.cfg

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
[metadata]
22
name = pytest_test_utils
33
version = 0.0.7
4+
long_description = file: README.md
5+
long_description_content_type = text/markdown
46
license = Apache License 2.0
57
license_file = LICENSE
68
url = https://github.com/iterative/pytest-test-utils
@@ -13,6 +15,7 @@ classifiers =
1315
Programming Language :: Python :: 3.8
1416
Programming Language :: Python :: 3.9
1517
Programming Language :: Python :: 3.10
18+
Programming Language :: Python :: 3.11
1619
Framework :: Pytest
1720

1821
[options]
@@ -24,13 +27,13 @@ install_requires=
2427

2528
[options.extras_require]
2629
tests =
27-
pytest==6.2.5
28-
pytest-sugar==0.9.4
29-
coverage==6.2
30+
pytest==7
31+
pytest-sugar
32+
coverage==6
3033
dev =
3134
%(tests)s
32-
pylint==2.11.1
33-
mypy==0.910
35+
pylint==2.14.3
36+
mypy==0.961
3437

3538
[options.entry_points]
3639
pytest11 =

0 commit comments

Comments
 (0)