Skip to content

Commit 2cf190a

Browse files
[pre-commit.ci] pre-commit autoupdate (#3306)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
1 parent 17435df commit 2cf190a

27 files changed

+39
-39
lines changed

.pre-commit-config.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ repos:
55
- id: end-of-file-fixer
66
- id: trailing-whitespace
77
- repo: https://github.com/python-jsonschema/check-jsonschema
8-
rev: 0.28.6
8+
rev: 0.29.1
99
hooks:
1010
- id: check-github-workflows
1111
args: [ "--verbose" ]
@@ -20,11 +20,11 @@ repos:
2020
- id: tox-ini-fmt
2121
args: ["-p", "fix"]
2222
- repo: https://github.com/tox-dev/pyproject-fmt
23-
rev: "2.1.4"
23+
rev: "2.2.1"
2424
hooks:
2525
- id: pyproject-fmt
2626
- repo: https://github.com/astral-sh/ruff-pre-commit
27-
rev: "v0.5.0"
27+
rev: "v0.5.6"
2828
hooks:
2929
- id: ruff-format
3030
- id: ruff

src/tox/config/loader/api.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ def __repr__(self) -> str:
112112
def __contains__(self, item: str) -> bool:
113113
return item in self.found_keys()
114114

115-
def load( # noqa: PLR0913
115+
def load(
116116
self,
117117
key: str,
118118
of_type: type[V],

src/tox/config/loader/ini/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
class IniLoader(StrConvert, Loader[str]):
2626
"""Load configuration from an ini section (ini file is a string to string dictionary)."""
2727

28-
def __init__( # noqa: PLR0913
28+
def __init__(
2929
self,
3030
section: Section,
3131
parser: ConfigParser,

src/tox/config/main.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
class Config:
2323
"""Main configuration object for tox."""
2424

25-
def __init__( # noqa: PLR0913
25+
def __init__(
2626
self,
2727
config_source: Source,
2828
options: Parsed,
@@ -123,7 +123,7 @@ def core(self) -> CoreConfigSet:
123123
self._core_set = core
124124
return core
125125

126-
def get_section_config( # noqa: PLR0913
126+
def get_section_config(
127127
self,
128128
section: Section,
129129
base: list[str] | None,

src/tox/execute/local_sub_process/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ def interrupt(self) -> None: # noqa: PLR6301
153153

154154

155155
class LocalSubProcessExecuteInstance(ExecuteInstance):
156-
def __init__( # noqa: PLR0913
156+
def __init__(
157157
self,
158158
request: ExecuteRequest,
159159
options: ExecuteOptions,

src/tox/execute/pep517_backend.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ def close(self) -> None:
9898
class LocalSubProcessPep517ExecuteInstance(ExecuteInstance):
9999
"""A backend invocation."""
100100

101-
def __init__( # noqa: PLR0913
101+
def __init__(
102102
self,
103103
request: ExecuteRequest,
104104
options: ExecuteOptions,

src/tox/pytest.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,7 @@ def interrupt(self) -> None: # noqa: PLR6301
194194
return None # pragma: no cover
195195

196196
class MockExecuteInstance(ExecuteInstance):
197-
def __init__( # noqa: PLR0913
197+
def __init__(
198198
self,
199199
request: ExecuteRequest,
200200
options: ExecuteOptions,
@@ -424,7 +424,7 @@ def _init(files: dict[str, Any], base: Path | None = None, prj_path: Path | None
424424
return _init
425425

426426

427-
@pytest.fixture()
427+
@pytest.fixture
428428
def empty_project(tox_project: ToxProjectCreator, monkeypatch: pytest.MonkeyPatch) -> ToxProject:
429429
project = tox_project({"tox.ini": ""})
430430
monkeypatch.chdir(project.path)

src/tox/tox_env/python/pip/req/file.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ def as_args(self) -> Iterator[str]:
111111

112112

113113
class ParsedLine:
114-
def __init__( # noqa: PLR0913
114+
def __init__(
115115
self,
116116
filename: str,
117117
lineno: int,

src/tox/tox_env/python/virtual_env/package/pyproject.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -447,7 +447,7 @@ def _send_msg(
447447
if self._tox_env.conf["fresh_subprocess"]:
448448
self.backend_executor.close()
449449

450-
def _unexpected_response( # noqa: PLR0913
450+
def _unexpected_response(
451451
self,
452452
cmd: str,
453453
got: Any,

src/tox/util/spinner.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ class Spinner:
5454
UNICODE_OUTCOME = Outcome(ok="✔", fail="✖", skip="⚠")
5555
ASCII_OUTCOME = Outcome(ok="+", fail="!", skip="?")
5656

57-
def __init__( # noqa: PLR0913
57+
def __init__(
5858
self,
5959
enabled: bool = True, # noqa: FBT001, FBT002
6060
refresh_rate: float = 0.1,

tests/config/cli/conftest.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
from tox.session.state import State
1919

2020

21-
@pytest.fixture()
21+
@pytest.fixture
2222
def core_handlers() -> dict[str, Callable[[State], int]]:
2323
return {
2424
"config": show_config,

tests/config/cli/test_cli_ini.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
from tox.session.state import State
2626

2727

28-
@pytest.fixture()
28+
@pytest.fixture
2929
def default_options() -> dict[str, Any]:
3030
return {
3131
"colored": "no",
@@ -168,7 +168,7 @@ def test_conf_arg(tmp_path: Path, conf_arg: str, filename: str, content: str) ->
168168
)
169169

170170

171-
@pytest.fixture()
171+
@pytest.fixture
172172
def exhaustive_ini(tmp_path: Path, monkeypatch: MonkeyPatch) -> Path:
173173
to = tmp_path / "tox.ini"
174174
to.write_text(

tests/config/conftest.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,6 @@
99
from tox.config.main import Config
1010

1111

12-
@pytest.fixture()
12+
@pytest.fixture
1313
def empty_config(tox_ini_conf: ToxIniCreator) -> Config:
1414
return tox_ini_conf("")

tests/config/loader/ini/conftest.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
from pathlib import Path
1010

1111

12-
@pytest.fixture()
12+
@pytest.fixture
1313
def mk_ini_conf(tmp_path: Path) -> Callable[[str], ConfigParser]:
1414
def _func(raw: str) -> ConfigParser:
1515
filename = tmp_path / "demo.ini"

tests/config/loader/ini/replace/conftest.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ class ReplaceOne(Protocol):
1919
def __call__(self, conf: str, pos_args: list[str] | None = None) -> str: ...
2020

2121

22-
@pytest.fixture()
22+
@pytest.fixture
2323
def replace_one(tmp_path: Path) -> ReplaceOne:
2424
def example(conf: str, pos_args: list[str] | None = None) -> str:
2525
tox_ini_file = tmp_path / "tox.ini"

tests/config/loader/ini/replace/test_replace_env_var.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ def test_replace_env_var_circular(replace_one: ReplaceOne, monkeypatch: MonkeyPa
9797
assert result == "{env:MAGIC}"
9898

9999

100-
@pytest.fixture()
100+
@pytest.fixture
101101
def reset_env_var_after_delay(monkeypatch: MonkeyPatch) -> Generator[threading.Thread, None, None]:
102102
timeout = 2
103103

tests/config/loader/ini/replace/test_replace_tox_env.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
EnvConfigCreator = Callable[[str], ConfigSet]
1818

1919

20-
@pytest.fixture()
20+
@pytest.fixture
2121
def example(tox_ini_conf: ToxIniCreator) -> EnvConfigCreator:
2222
def func(conf: str) -> ConfigSet:
2323
config = tox_ini_conf(f"""[tox]\nenv_list = a\n[testenv]\n{conf}\n""")

tests/config/test_set_env.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ def __call__(
6060
) -> SetEnv: ...
6161

6262

63-
@pytest.fixture()
63+
@pytest.fixture
6464
def eval_set_env(tox_project: ToxProjectCreator) -> EvalSetEnv:
6565
def func(tox_ini: str, extra_files: dict[str, Any] | None = None, from_cwd: Path | None = None) -> SetEnv:
6666
prj = tox_project({"tox.ini": tox_ini, **(extra_files or {})})

tests/conftest.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ class ToxIniCreator(Protocol):
4646
def __call__(self, conf: str, override: Sequence[Override] | None = None) -> Config: ...
4747

4848

49-
@pytest.fixture()
49+
@pytest.fixture
5050
def tox_ini_conf(tmp_path: Path, monkeypatch: pytest.MonkeyPatch) -> ToxIniCreator:
5151
def func(conf: str, override: Sequence[Override] | None = None) -> Config:
5252
dest = tmp_path / "c"
@@ -78,7 +78,7 @@ def demo_pkg_inline() -> Iterator[Path]:
7878
yield demo_path
7979

8080

81-
@pytest.fixture()
81+
@pytest.fixture
8282
def patch_prev_py(mocker: MockerFixture) -> Callable[[bool], tuple[str, str]]:
8383
def _func(has_prev: bool) -> tuple[str, str]:
8484
ver = sys.version_info[0:2]

tests/journal/test_main_journal.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
from tox.journal.main import Journal
1111

1212

13-
@pytest.fixture()
13+
@pytest.fixture
1414
def base_info() -> dict[str, Any]:
1515
return {
1616
"reportversion": "1",

tests/session/cmd/test_devenv.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ def test_devenv_fail_multiple_target(tox_project: ToxProjectCreator) -> None:
1515
outcome.assert_out_err(msg, "")
1616

1717

18-
@pytest.mark.integration()
18+
@pytest.mark.integration
1919
def test_devenv_ok(tox_project: ToxProjectCreator, enable_pip_pypi_access: str | None) -> None: # noqa: ARG001
2020
content = {
2121
"setup.py": "from setuptools import setup\nsetup(name='demo', version='1.0')",

tests/session/cmd/test_list_envs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
from tox.pytest import ToxProject, ToxProjectCreator
99

1010

11-
@pytest.fixture()
11+
@pytest.fixture
1212
def project(tox_project: ToxProjectCreator) -> ToxProject:
1313
ini = """
1414
[tox]

tests/session/cmd/test_sequential.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ def test_run_sequential_quiet(tox_project: ToxProjectCreator) -> None:
5656
assert Matches(r" a: OK \([\d.]+ seconds\)") == reports[-2]
5757

5858

59-
@pytest.mark.integration()
59+
@pytest.mark.integration
6060
def test_result_json_sequential(
6161
tox_project: ToxProjectCreator,
6262
enable_pip_pypi_access: str | None, # noqa: ARG001
@@ -156,7 +156,7 @@ def test_rerun_sequential_wheel(tox_project: ToxProjectCreator, demo_pkg_inline:
156156
result_rerun.assert_success()
157157

158158

159-
@pytest.mark.integration()
159+
@pytest.mark.integration
160160
def test_rerun_sequential_sdist(tox_project: ToxProjectCreator, demo_pkg_inline: Path) -> None:
161161
proj = tox_project(
162162
{"tox.ini": "[testenv]\npackage=sdist\ncommands=python -c 'from demo_pkg_inline import do; do()'"},

tests/test_provision.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ def pypi_index_self(pypi_server: IndexServer, tox_wheels: list[Path], demo_pkg_i
107107
return self_index
108108

109109

110-
@pytest.fixture()
110+
@pytest.fixture
111111
def _pypi_index_self(pypi_index_self: Index, monkeypatch: MonkeyPatch) -> None:
112112
pypi_index_self.use()
113113
monkeypatch.setenv("PIP_INDEX_URL", pypi_index_self.url)
@@ -127,7 +127,7 @@ def test_provision_requires_nok(tox_project: ToxProjectCreator) -> None:
127127
)
128128

129129

130-
@pytest.mark.integration()
130+
@pytest.mark.integration
131131
@pytest.mark.usefixtures("_pypi_index_self")
132132
def test_provision_requires_ok(tox_project: ToxProjectCreator, tmp_path: Path) -> None:
133133
proj = tox_project({"tox.ini": "[tox]\nrequires=demo-pkg-inline\n[testenv]\npackage=skip"})
@@ -160,7 +160,7 @@ def test_provision_requires_ok(tox_project: ToxProjectCreator, tmp_path: Path) -
160160
assert f"ROOT: remove tox env folder {provision_env}" in result_recreate.out, result_recreate.out
161161

162162

163-
@pytest.mark.integration()
163+
@pytest.mark.integration
164164
@pytest.mark.usefixtures("_pypi_index_self")
165165
def test_provision_platform_check(tox_project: ToxProjectCreator) -> None:
166166
ini = "[tox]\nrequires=demo-pkg-inline\n[testenv]\npackage=skip\n[testenv:.tox]\nplatform=wrong_platform"
@@ -194,7 +194,7 @@ def test_provision_no_recreate_json(tox_project: ToxProjectCreator) -> None:
194194
assert requires == {"minversion": None, "requires": ["p", "tox"]}
195195

196196

197-
@pytest.mark.integration()
197+
@pytest.mark.integration
198198
@pytest.mark.usefixtures("_pypi_index_self")
199199
@pytest.mark.parametrize("plugin_testenv", ["testenv", "testenv:a"])
200200
def test_provision_plugin_runner(tox_project: ToxProjectCreator, tmp_path: Path, plugin_testenv: str) -> None:
@@ -217,7 +217,7 @@ def test_provision_plugin_runner(tox_project: ToxProjectCreator, tmp_path: Path,
217217
assert prov_msg in result_label.out
218218

219219

220-
@pytest.mark.integration()
220+
@pytest.mark.integration
221221
def test_provision_plugin_runner_in_provision(tox_project: ToxProjectCreator, tmp_path: Path) -> None:
222222
"""Ensure that provision environment can be explicitly configured."""
223223
log = tmp_path / "out.log"
@@ -226,7 +226,7 @@ def test_provision_plugin_runner_in_provision(tox_project: ToxProjectCreator, tm
226226
proj.run("r", "-e", "py", "--result-json", str(log))
227227

228228

229-
@pytest.mark.integration()
229+
@pytest.mark.integration
230230
@pytest.mark.usefixtures("_pypi_index_self")
231231
@pytest.mark.parametrize("relative_path", [True, False], ids=["relative", "absolute"])
232232
def test_provision_conf_file(tox_project: ToxProjectCreator, tmp_path: Path, relative_path: bool) -> None:

tests/tox_env/python/virtual_env/package/test_package_cmd_builder.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ def pkg_with_sdist(
4545
return next(dist.iterdir())
4646

4747

48-
@pytest.fixture()
48+
@pytest.fixture
4949
def pkg_with_extras_project_sdist(
5050
pkg_with_extras_project: Path,
5151
pkg_builder: Callable[[Path, Path, list[str], bool], Path],

tests/tox_env/python/virtual_env/test_setuptools.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
from tox.pytest import ToxProjectCreator
1717

1818

19-
@pytest.mark.integration()
19+
@pytest.mark.integration
2020
def test_setuptools_package(
2121
tox_project: ToxProjectCreator,
2222
demo_pkg_setuptools: Path,

tests/tox_env/python/virtual_env/test_virtualenv_api.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
from tox.pytest import MonkeyPatch, ToxProject, ToxProjectCreator
1717

1818

19-
@pytest.fixture()
19+
@pytest.fixture
2020
def virtualenv_opt(monkeypatch: MonkeyPatch, mocker: MockerFixture) -> VirtualEnvOptions:
2121
for key in os.environ:
2222
if key.startswith("VIRTUALENV_"): # pragma: no cover

0 commit comments

Comments
 (0)