Skip to content

Commit 9cf65f0

Browse files
committed
Migrate pytest settings to pyproject.toml
Signed-off-by: Philippe Ombredanne <[email protected]>
1 parent b5a5079 commit 9cf65f0

File tree

2 files changed

+11
-66
lines changed

2 files changed

+11
-66
lines changed

pyproject.toml

Lines changed: 11 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -2,36 +2,24 @@
22
requires = ["setuptools >= 50", "wheel"]
33
build-backend = "setuptools.build_meta"
44

5-
[tool.setuptools_scm]
65

76
[tool.pytest.ini_options]
7+
88
norecursedirs = [
99
".git",
10-
"bin",
1110
"dist",
1211
"build",
1312
"_build",
14-
"dist",
15-
"etc",
16-
"local",
17-
"ci",
1813
"docs",
19-
"man",
20-
"share",
21-
"samples",
2214
".cache",
2315
".settings",
24-
"Include",
25-
"include",
26-
"Lib",
27-
"lib",
28-
"lib64",
29-
"Lib64",
30-
"Scripts",
3116
"thirdparty",
3217
"tmp",
33-
"tests/data",
34-
".eggs"
18+
"venv",
19+
"*/tests/test_data",
20+
".eggs",
21+
"src/*/data",
22+
"tests/*/data"
3523
]
3624

3725
python_files = "*.py"
@@ -41,7 +29,7 @@ python_functions="test"
4129

4230
addopts = [
4331
"-rfExXw",
44-
"--strict",
32+
"--strict-markers",
4533
"--doctest-modules"
4634
]
4735

@@ -50,3 +38,7 @@ profile = "black"
5038
line_length = 100
5139
force_single_line = true
5240
skip_gitignore = true
41+
42+
43+
44+

setup.cfg

Lines changed: 0 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -9,50 +9,3 @@ pypi_release = clean --all sdist bdist_wheel register upload
99

1010
release = clean --all sdist bdist_wheel
1111

12-
13-
[tool:pytest]
14-
DJANGO_SETTINGS_MODULE = vulnerablecode.settings
15-
16-
markers =
17-
webtest: marker for tests which require internet connection.
18-
19-
testpaths =
20-
vulnerabilities
21-
vulnerablecode
22-
23-
norecursedirs =
24-
.git
25-
bin
26-
dist
27-
build
28-
_build
29-
dist
30-
local
31-
ci
32-
docs
33-
man
34-
share
35-
samples
36-
.cache
37-
.settings
38-
Include
39-
include
40-
Lib
41-
lib
42-
lib64
43-
Scripts
44-
thirdparty
45-
tmp
46-
vulnerabilities/tests/test_data
47-
48-
python_files = *.py
49-
50-
python_classes=Test
51-
python_functions=test
52-
53-
addopts =
54-
-rfEsxXw
55-
--strict
56-
--ignore setup.py
57-
--ignore vulnerabilities/lib_oval.py
58-
--doctest-modules

0 commit comments

Comments
 (0)