-
Notifications
You must be signed in to change notification settings - Fork 0
/
pyproject.toml
108 lines (95 loc) · 2.52 KB
/
pyproject.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
[tool.poetry]
name = "json2vars-setter"
version = "0.2.4"
description = ""
authors = ["7rikazhexde"]
readme = "README.md"
[tool.poetry.dependencies]
python = "^3.10"
[tool.poetry.group.dev.dependencies]
pytest = "^8.3.4"
pre-commit = "^4.0.1"
pytest-cov = "^6.0.0"
pytest-xdist = "^3.6.1"
pytest-html = "^4.1.1"
pytest-mock = "^3.14.0"
pytest-testmon = "^2.1.3"
ruff = "^0.8.4"
mypy = "^1.14.0"
taskipy = "^1.14.1"
[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
[tool.ruff]
exclude = [
".bzr",
".direnv",
".eggs",
".git",
".git-rewrite",
".hg",
".mypy_cache",
".nox",
".pants.d",
".pytype",
".ruff_cache",
".svn",
".tox",
".venv",
"__pypackages__",
"_build",
"buck-out",
"build",
"dist",
"node_modules",
"venv",
]
target-version = "py310"
[tool.ruff.lint]
select = ["E", "F", "I"]
ignore = ["E402", "E501"]
per-file-ignores = {}
[tool.mypy]
files = ["json2vars_setter", "tests", "scripts"]
python_version = "3.12"
show_error_context = true
show_column_numbers = true
ignore_missing_imports = true
disallow_untyped_defs = true
no_implicit_optional = true
warn_return_any = true
warn_unused_ignores = true
warn_redundant_casts = true
[tool.pytest.ini_options]
testpaths = ["json2vars_setter", "tests"]
pythonpath = ["."]
# Enable log output during test execution.
log_cli = true
log_cli_level = "INFO"
log_cli_format = "%(asctime)s [%(levelname)s] %(message)s"
[tool.taskipy.tasks]
test_coverage_verbose = "pytest -s -vv --cov=. --cov-branch --cov-report term-missing --cov-report html"
test_html_report = "pytest --html=htmlcov/report_page.html"
test_ci_xml = "python scripts/run_tests.py --report xml"
test_ci_term = "python scripts/run_tests.py --report term"
test_testmon = "pytest --testmon"
test_coverage = "pytest --cov=. --cov-branch --cov-report=term-missing --cov-report=html"
[tool.coverage.run]
source = ["json2vars_setter"]
# explicitly false to address compatibility issues with testmon and pytest-cov
# testmon and pytest-cov both use internal tracing mechanisms to track Python code execution.
# When branch coverage is enabled, pytest-cov provides more detailed tracing, but conflicts with testmon's behavior. This is a limitation of testmon.
branch = false
[tool.coverage.report]
exclude_lines = [
"pragma: no cover",
"def __repr__",
"if self.debug:",
"if __name__ == .__main__.:",
"raise NotImplementedError",
"pass",
"except ImportError:",
"def main"
]
[tool.coverage.html]
directory = "htmlcov"