(items: list[pytest.Item])
| 69 | |
| 70 | |
| 71 | def pytest_collection_modifyitems(items: list[pytest.Item]) -> None: |
| 72 | # Termux builds can omit os.link. Fallback tests still run there. |
| 73 | if not hasattr(os, "link"): # pragma: no cover # the body runs only on Termux/Android, absent from the CI matrix |
| 74 | skip = pytest.mark.skip(reason="test requires os.link (hard links), absent on Termux/Android") |
| 75 | for item in items: |
| 76 | if item.get_closest_marker("requires_hard_links") is not None: |
| 77 | item.add_marker(skip) |
| 78 | |
| 79 | |
| 80 | # Captured at import, before any test forks, so a fork child can tell it is not the session. |
nothing calls this directly
no outgoing calls
no test coverage detected