diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 61508c4..3fc9367 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -1,6 +1,13 @@ CHANGELOG ========= +UNRELEASED +---------- + +* Hide the traceback inside the ``SubTests.test()`` method (`#131`_). + +.. _#131: https://github.com/pytest-dev/pytest-subtests/pull/131 + 0.12.1 (2024-03-07) ------------------- diff --git a/src/pytest_subtests/plugin.py b/src/pytest_subtests/plugin.py index a498456..81ad5c1 100644 --- a/src/pytest_subtests/plugin.py +++ b/src/pytest_subtests/plugin.py @@ -224,6 +224,9 @@ def test( msg: str | None = None, **kwargs: Any, ) -> Generator[None, None, None]: + # Hide from tracebacks. + __tracebackhide__ = True + start = time.time() precise_start = time.perf_counter() exc_info = None