Skip to content

Commit 8c2695b

Browse files
committed
Drop py35, py36 and add py310, py311
* Run pyupgrade * Update hooks
1 parent 8db95e1 commit 8c2695b

File tree

7 files changed

+21
-18
lines changed

7 files changed

+21
-18
lines changed

.github/workflows/main.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,19 +10,19 @@ jobs:
1010
strategy:
1111
fail-fast: false
1212
matrix:
13-
python: ["3.5", "3.6", "3.7", "3.8", "3.9"]
13+
python: ["3.7", "3.8", "3.9", "3.10", "3.11"]
1414
os: [ubuntu-latest, windows-latest]
1515
include:
16-
- python: "3.5"
17-
tox_env: "py35"
18-
- python: "3.6"
19-
tox_env: "py36"
2016
- python: "3.7"
2117
tox_env: "py37"
2218
- python: "3.8"
2319
tox_env: "py38"
2420
- python: "3.9"
2521
tox_env: "py39"
22+
- python: "3.10"
23+
tox_env: "py310"
24+
- python: "3.11"
25+
tox_env: "py311"
2626

2727
steps:
2828
- uses: actions/checkout@v3

.pre-commit-config.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
1-
exclude: '^($|.*\.bin)'
21
repos:
32
- repo: https://github.com/ambv/black
4-
rev: 19.3b0
3+
rev: 23.1.0
54
hooks:
65
- id: black
76
args: [--safe, --quiet]
87
- repo: https://github.com/pre-commit/pre-commit-hooks
9-
rev: v2.2.3
8+
rev: v4.4.0
109
hooks:
1110
- id: trailing-whitespace
1211
- id: end-of-file-fixer

CHANGELOG.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
UNRELEASED
2+
----------
3+
4+
* Added support for Python 3.10 and 3.11.
5+
* Dropped support for Python 3.5 and 3.6.
6+
17
0.1.2 (2020-12-11)
28
------------------
39

setup.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@
1111
packages=find_packages(where="src"),
1212
package_dir={"": "src"},
1313
platforms="any",
14-
python_requires=">=3.5",
15-
install_requires=["pytest>=5.2"],
14+
python_requires=">=3.7",
15+
install_requires=["pytest"],
1616
use_scm_version={"write_to": "src/pytest_reportlog/_version.py"},
1717
setup_requires=["setuptools_scm"],
1818
url="https://github.com/pytest-dev/pytest-reportlog",
@@ -30,11 +30,11 @@
3030
"License :: OSI Approved :: MIT License",
3131
"Operating System :: OS Independent",
3232
"Programming Language :: Python :: 3",
33-
"Programming Language :: Python :: 3.5",
34-
"Programming Language :: Python :: 3.6",
3533
"Programming Language :: Python :: 3.7",
3634
"Programming Language :: Python :: 3.8",
3735
"Programming Language :: Python :: 3.9",
36+
"Programming Language :: Python :: 3.10",
37+
"Programming Language :: Python :: 3.11",
3838
"Topic :: Software Development :: Testing",
3939
],
4040
)

src/pytest_reportlog/plugin.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -74,9 +74,7 @@ def pytest_collectreport(self, report):
7474
self._write_json_data(data)
7575

7676
def pytest_terminal_summary(self, terminalreporter):
77-
terminalreporter.write_sep(
78-
"-", "generated report log file: {}".format(self._log_path)
79-
)
77+
terminalreporter.write_sep("-", f"generated report log file: {self._log_path}")
8078

8179

8280
def cleanup_unserializable(d: Dict[str, Any]) -> Dict[str, Any]:

tests/test_reportlog.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ def test_fail():
2626

2727
result = testdir.runpytest("--report-log", str(log_file))
2828
assert result.ret == pytest.ExitCode.TESTS_FAILED
29-
result.stdout.fnmatch_lines(["* generated report log file: {}*".format(log_file)])
29+
result.stdout.fnmatch_lines([f"* generated report log file: {log_file}*"])
3030

3131
json_objs = [json.loads(x) for x in log_file.read_text().splitlines()]
3232
assert len(json_objs) == 10
@@ -68,7 +68,7 @@ def test_fail():
6868
"""
6969
)
7070
fn = tmp_path / "result.log"
71-
result = testdir.runpytest("-n2", "--report-log={}".format(fn))
71+
result = testdir.runpytest("-n2", f"--report-log={fn}")
7272
result.stdout.fnmatch_lines("*1 failed, 1 passed*")
7373

7474
lines = fn.read_text("UTF-8").splitlines()

tox.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[tox]
2-
envlist = py{35,36,37,38,39},linting
2+
envlist = py{37,38,39,310,311},linting
33

44
[testenv]
55
deps =

0 commit comments

Comments
 (0)