Run pytest with dedicated pytest.ini. (#59842)
Also disable the pytest cache plugin.
This commit is contained in:
parent
f944bd2358
commit
93931810c8
3 changed files with 5 additions and 5 deletions
|
@ -1368,6 +1368,8 @@ def command_units(args):
|
||||||
'-n', str(args.num_workers) if args.num_workers else 'auto',
|
'-n', str(args.num_workers) if args.num_workers else 'auto',
|
||||||
'--color',
|
'--color',
|
||||||
'yes' if args.color else 'no',
|
'yes' if args.color else 'no',
|
||||||
|
'-p', 'no:cacheprovider',
|
||||||
|
'-c', os.path.join(ANSIBLE_ROOT, 'test/runner/pytest.ini'),
|
||||||
'--junit-xml',
|
'--junit-xml',
|
||||||
'test/results/junit/python%s-units.xml' % version,
|
'test/results/junit/python%s-units.xml' % version,
|
||||||
]
|
]
|
||||||
|
|
3
test/runner/pytest.ini
Normal file
3
test/runner/pytest.ini
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
[pytest]
|
||||||
|
xfail_strict = true
|
||||||
|
mock_use_standalone_module = true
|
5
tox.ini
5
tox.ini
|
@ -19,11 +19,6 @@ passenv =
|
||||||
# variable error. See issue: #20424
|
# variable error. See issue: #20424
|
||||||
HOME
|
HOME
|
||||||
|
|
||||||
[pytest]
|
|
||||||
xfail_strict = true
|
|
||||||
cache_dir = .pytest_cache
|
|
||||||
mock_use_standalone_module = true
|
|
||||||
|
|
||||||
[flake8]
|
[flake8]
|
||||||
# These are things that the devs don't agree make the code more readable
|
# These are things that the devs don't agree make the code more readable
|
||||||
# E402 module level import not at top of file
|
# E402 module level import not at top of file
|
||||||
|
|
Loading…
Reference in a new issue