{"categories":[{"label":"Utilities","url":"https://skillfed.io/packages/category/utilities/8"},{"label":"Testing","url":"https://skillfed.io/packages/category/software-development-testing/5"}],"enrichment":{"capability":"A pytest plugin that provides a `runtime_xfail` fixture to mark tests as expected-to-fail based on runtime conditions, allowing both XFAIL and XPASS outcomes.","skillfed_tags":["pytest-plugin","test-marking"],"use_cases":["Mark tests as xfail when a runtime condition (e.g., OS, Python version, or environment variable) indicates expected failure.","Conditionally expect failure in a shared fixture that multiple tests depend on, based on setup-time detection.","Track when platform-specific or version-specific test failures are resolved by using xfail_strict to catch XPASS.","Avoid skipping tests while still recording them as expected failures when a runtime dependency or feature is unavailable."],"what_it_does":"pytest-runtime-xfail fills a gap in pytest's xfail handling by allowing you to decide at runtime whether a test should be marked as expected-to-fail, while still running the test to completion. The standard pytest.xfail() call stops test execution immediately; @pytest.mark.xfail() requires the decision at collection time. This plugin's runtime_xfail fixture lets you make that decision based on conditions known only during test execution, and the test continues running so you can see both XFAIL (test failed as expected) and XPASS (test passed unexpectedly) outcomes.\n\nThe fixture works by adding an xfail marker to the test node dynamically, similar to calling request.node.add_marker(pytest.mark.xfail()) but packaged as a reusable fixture. It respects the xfail_strict configuration option, so passing tests marked with runtime_xfail will fail the test run if strict mode is enabled\u2014useful for detecting when previously-failing tests start passing.","worth_installing":"Yes, if you need runtime-conditional xfail marking in pytest. The plugin solves a real gap in pytest's built-in xfail mechanisms and has no security vulnerabilities. Install friction is minimal. The aging maintenance status (308 days since last release) is a minor concern for a stable, single-purpose fixture, but the repository is not archived and the package is marked Production/Stable."},"id":"pytest-runtime-xfail","links":{"html":"https://skillfed.io/packages/pytest-runtime-xfail","md":"https://skillfed.io/packages/pytest-runtime-xfail.md","pypi":"https://pypi.org/project/pytest-runtime-xfail/"},"maintenance":{"status":"aging"},"meta":{"latest_release":"2025-10-10","license_spdx":null,"license_treatment":"permissive","name":"pytest-runtime-xfail","python_support":"supports_current","summary":"Call runtime_xfail() to mark running test as xfail."},"popularity":{"monthly_downloads":179931,"position":10159,"tier":"top_15000"},"security":{"n_vulnerabilities":0},"version":"1.1.1"}
