Files
jathu 5818c805bb Create a @periodic Decorator (#191946)
Solves https://github.com/pytorch/test-infra/issues/8296

Adds a `@periodic` decorator for tests that should run only in periodic CI, including interoperability with `@slowTest`. Periodic Linux, ROCm, Inductor, and s390x workflows now explicitly enable these tests.

For now, the only periodic tests are the ones I'm introducing to test the decorator.

_Authored with Codex_
Pull Request resolved: https://github.com/pytorch/pytorch/pull/191946
Approved by: https://github.com/izaitsevfb, https://github.com/huydhn
2026-08-27 18:17:15 +00:00

27 lines
1011 B
INI

[pytest]
addopts =
# show summary of all tests that did not pass
-rEfX
# Make tracebacks shorter
--tb=native
# capture only Python print and C++ py::print, but not C output (low-level Python errors)
--capture=sys
# don't suppress warnings, but don't shove them all to the end either
-p no:warnings
# Use custom pytest shard located in test/pytest_shard_custom.py instead
-p no:pytest-shard
# don't rewrite assertions (usually not a problem in CI due to differences in imports, see #95844)
--assert=plain
testpaths =
test
junit_logging_reruns = all
filterwarnings =
ignore:Module already imported so cannot be rewritten.*hypothesis:pytest.PytestAssertRewriteWarning
xfail_strict = True
markers =
serial: marks tests as needs to be run serially (deselect with '-m "not serial"')
multigpu: marks a distributed test that needs multiple GPUs (deselect with '-m "not multigpu"')
periodic: marks tests that run only in the periodic-strict workflow