[TE-5274] Add pytest 9.x CI matrix entry for subtest integration tests#95
Merged
[TE-5274] Add pytest 9.x CI matrix entry for subtest integration tests#95
Conversation
Contributor
Author
|
Appears to be still skipping the 5 tests. |
Contributor
Author
Add a sixth matrix entry (Python 3.13 + pytest 9) so the 5 integration tests in test_integration_subtests.py are actually exercised in CI. Those tests require pytest >= 9.0 for built-in SubtestReport support, but uv.lock pins pytest to 8.4.1 (pytest 9 dropped Python 3.9). Uses uv run --with 'pytest>=9' rather than uv pip install because uv run syncs the environment to uv.lock before execution, which would silently revert a pip-installed override. The --with flag creates an ephemeral overlay that persists through the run, including subprocesses spawned via sys.executable.
63636e5 to
1b794f9
Compare
nprizal
approved these changes
Mar 17, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
PR #94 added subtest handling with 5 integration tests in
test_integration_subtests.py. Those tests need pytest >= 9.0 (which introduced built-inSubtestReport), butuv.lockpins pytest to 8.4.1. All 5 are unconditionally skipped in CI today, so the subtest code path is never exercised end-to-end.We can't bump the lockfile to pytest 9 across the board because pytest 9.0 dropped Python 3.9 support and the collector still targets 3.9.
This adds a sixth CI matrix entry (Python 3.13 + pytest 9) using
uv run --with 'pytest>=9'. The--withflag is important here: a plainuv pip installoverride gets silently reverted whenuv runsyncs the environment back touv.lockbefore execution.--withcreates an ephemeral overlay that persists through the run, including subprocesses spawned viasys.executable(which is how the integration tests invoke pytest).The existing 5 matrix entries are untouched and keep testing against pytest 8.4.1 from the lockfile.
Context
Related to TE-5274 and #94 (subtest handling).
Changes
uv-run-flagsmatrix dimension with apytest>=9include entry for Python 3.13uv run ${{ matrix.uv-run-flags }} pytestVerification
The workflow should show 6 pytest matrix entries instead of 5. The new entry (Python 3.13 + pytest 9.x) should run the 5 integration tests that are skipped everywhere else. AI assisted.
Deployment
Low risk. CI-only change -- no library or test code modified.
Rollback
Yes