Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ repos:
- id: end-of-file-fixer
- id: trailing-whitespace
- repo: https://github.com/python-jsonschema/check-jsonschema
rev: 0.28.2
rev: 0.28.4
hooks:
- id: check-github-workflows
args: [ "--verbose" ]
Expand All @@ -20,12 +20,12 @@ repos:
- id: tox-ini-fmt
args: ["-p", "fix"]
- repo: https://github.com/tox-dev/pyproject-fmt
rev: "1.8.0"
rev: "2.1.2"
hooks:
- id: pyproject-fmt
additional_dependencies: ["tox>=4.13"]
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: "v0.4.3"
rev: "v0.4.4"
hooks:
- id: ruff-format
- id: ruff
Expand Down
53 changes: 32 additions & 21 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@ keywords = [
"pytest",
]
license.file = "LICENSE"
maintainers = [{ name = "Bernát Gábor", email = "gaborjbernat@gmail.com" }]
maintainers = [
{ name = "Bernát Gábor", email = "gaborjbernat@gmail.com" },
]
requires-python = ">=3.8"
classifiers = [
"Development Status :: 5 - Production/Stable",
Expand All @@ -36,7 +38,7 @@ dynamic = [
]
dependencies = [
"pytest>=8.0.1",
'tomli>=2.0.1; python_version < "3.11"',
"tomli>=2.0.1; python_version<'3.11'",
]
optional-dependencies.test = [
"covdefaults>=2.3",
Expand All @@ -46,53 +48,62 @@ optional-dependencies.test = [
urls.Homepage = "https://github.com/pytest-dev/pytest-env"
urls.Source = "https://github.com/pytest-dev/pytest-env"
urls.Tracker = "https://github.com/pytest-dev/pytest-env/issues"
[project.entry-points.pytest11]
env = "pytest_env.plugin"
entry-points.pytest11.env = "pytest_env.plugin"

[tool.hatch]
build.hooks.vcs.version-file = "src/pytest_env/version.py"
version.source = "vcs"

[tool.ruff]
line-length = 120
target-version = "py38"
lint.isort = { known-first-party = ["pytest_env"], required-imports = ["from __future__ import annotations"] }
lint.select = ["ALL"]
line-length = 120
format.preview = true
format.docstring-code-line-length = 100
format.docstring-code-format = true
lint.select = [
"ALL",
]
lint.ignore = [
"ANN101", # no type annotation for self
"ANN401", # allow Any as type annotation
"COM812", # Conflict with formatter
"CPY", # No copyright statements
"D203", # `one-blank-line-before-class` (D203) and `no-blank-line-before-class` (D211) are incompatible
"D212", # `multi-line-summary-first-line` (D212) and `multi-line-summary-second-line` (D213) are incompatible
"S104", # Possible binding to all interface
"COM812", # Conflict with formatter
"ISC001", # Conflict with formatter
"CPY", # No copyright statements
"S104", # Possible binding to all interface
]
lint.preview = true
format.preview = true
format.docstring-code-format = true
format.docstring-code-line-length = 100
[tool.ruff.lint.per-file-ignores]
"tests/**/*.py" = [
"S101", # asserts allowed in tests...
lint.per-file-ignores."tests/**/*.py" = [
"D", # don"t care about documentation in tests
"FBT", # don"t care about booleans as positional arguments in tests
"INP001", # no implicit namespace
"D", # don"t care about documentation in tests
"S603", # `subprocess` call: check for execution of untrusted input
"PLR2004", # Magic value used in comparison, consider replacing with a constant variable
"S101", # asserts allowed in tests...
"S603", # `subprocess` call: check for execution of untrusted input
]
lint.isort = { known-first-party = [
"pytest_env",
], required-imports = [
"from __future__ import annotations",
] }
lint.preview = true

[tool.codespell]
builtin = "clear,usage,en-GB_to_en-US"
write-changes = true
count = true

[tool.coverage]
run.source = ["pytest_env", "tests"]
run.source = [
"pytest_env",
"tests",
]
run.dynamic_context = "test_function"
run.branch = true
run.parallel = true
run.plugins = ["covdefaults"]
run.plugins = [
"covdefaults",
]
report.fail_under = 100
report.show_missing = true
html.show_contexts = true
Expand Down