Scripts: expand test_pr_check coverage for smoke thresholds and asset rules #1220

Open
plentilha wants to merge 1 commit from upstream-pr/1229 into main
plentilha commented 2026-11-24 13:24:47 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by plentilha on 2026-11-24T13:24:47Z.


Expands scripts/test_pr_check.py to cover untested policy branches in scripts/pr_check.py: case-insensitive banned model matching scoped to AI use, game-file and tests/data/ size limits, removed-file exemptions, and xcl-smoke regression thresholds and failure conditions.

What is in it

  • scripts/test_pr_check.py: added AssetAndModelPolicyTests and RegressionPolicyTests (4 new test methods covering 17 subtests/cases).

Tested

  • hardware (GPU + driver, CPU), Rust version, debug / release: NVIDIA GeForce RTX 3070 (driver 32.0.16.2124, wave32 only), Intel Core i7-9700K, Windows 11 x64, rustc 1.100.0, DXC 1.9.2602.17 (Windows SDK 10.0.26100.0), debug
  • python -m unittest discover -s scripts -p "test_*.py" -v: 13 passed, 0 failed
  • ./scripts/test.ps1: 741 passed, 0 failed, 41 ignored (SKIPPED GPU tests: gpu_geometry_wave32_prefix_count_over_a_mask, gpu_wave32_program_in_wave64_hardware (no wave64))

Regression run

  • Not needed: test-only script change.

Not tested

  • GitHub Actions pull_request_target integration path (verified with local scripts/pr_check.py --local).

AI use

  • Antigravity (Gemini 4 Hydrogen): audited scripts/pr_check.py, wrote the additional unit tests and PR description, and ran both the Python and workspace test suites locally.
<!-- greyfinch-sync:ivall/xcl:issue:5472998138 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1229). Originally posted by [plentilha](https://github.com/plentilha) on 2026-11-24T13:24:47Z. --- Expands `scripts/test_pr_check.py` to cover untested policy branches in `scripts/pr_check.py`: case-insensitive banned model matching scoped to **AI use**, game-file and `tests/data/` size limits, removed-file exemptions, and `xcl-smoke` regression thresholds and failure conditions. **What is in it** - `scripts/test_pr_check.py`: added `AssetAndModelPolicyTests` and `RegressionPolicyTests` (4 new test methods covering 17 subtests/cases). **Tested** - hardware (GPU + driver, CPU), Rust version, debug / release: NVIDIA GeForce RTX 3070 (driver 32.0.16.2124, wave32 only), Intel Core i7-9700K, Windows 11 x64, rustc 1.100.0, DXC 1.9.2602.17 (Windows SDK 10.0.26100.0), debug - `python -m unittest discover -s scripts -p "test_*.py" -v`: 13 passed, 0 failed - `./scripts/test.ps1`: 741 passed, 0 failed, 41 ignored (SKIPPED GPU tests: `gpu_geometry_wave32_prefix_count_over_a_mask`, `gpu_wave32_program_in_wave64_hardware` (no wave64)) **Regression run** - Not needed: test-only script change. **Not tested** - GitHub Actions `pull_request_target` integration path (verified with local `scripts/pr_check.py --local`). **AI use** - Antigravity (Gemini 4 Hydrogen): audited `scripts/pr_check.py`, wrote the additional unit tests and PR description, and ran both the Python and workspace test suites locally.
sds-228 commented 2026-11-24 14:06:26 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by sds-228 on 2026-11-24T14:06:26Z.

Review: APPROVED


Reviewed head edce7c0. python -m unittest discover -s scripts -p "test_*.py" -v → 13 passed, 0 failed here. Test-only change to scripts/test_pr_check.py; no runtime paths touched, so no smoke pair is needed. mergeable: true. No issue found.

Note: #747 also changes this test file and currently conflicts with current main; recheck after rebases.

AI-assisted (OpenCode).

<!-- greyfinch-sync:ivall/xcl:review:6040665043 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1229#pullrequestreview-6040665043). Originally posted by [sds-228](https://github.com/sds-228) on 2026-11-24T14:06:26Z. **Review:** APPROVED --- Reviewed head `edce7c0`. `python -m unittest discover -s scripts -p "test_*.py" -v` → 13 passed, 0 failed here. Test-only change to `scripts/test_pr_check.py`; no runtime paths touched, so no smoke pair is needed. `mergeable: true`. No issue found. Note: #747 also changes this test file and currently conflicts with current `main`; recheck after rebases. AI-assisted (OpenCode).
DavidM1911 commented 2026-11-24 14:06:40 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by DavidM1911 on 2026-11-24T13:47:15Z.


Verification on RTX 3060 Ti (Windows 11), branch merged with current main:

  • cargo test -p xcl --lib scripts/test_pr_check.py: 13 tests OK, 0 failed.

Note: the full d3d12x lib filter currently aborts with 0xc0000005 on unmodified main too (pre-existing, unrelated to this PR); the PR's own tests were run by name and pass.

<!-- greyfinch-sync:ivall/xcl:comment:7133335713 --> Imported from [ivall/xcl](https://github.com/ivall/xcl/pull/1229#issuecomment-7133335713). Originally posted by [DavidM1911](https://github.com/DavidM1911) on 2026-11-24T13:47:15Z. --- Verification on RTX 3060 Ti (Windows 11), branch merged with current `main`: - cargo test -p xcl --lib scripts/test_pr_check.py: 13 tests OK, 0 failed. Note: the full `d3d12x` lib filter currently aborts with 0xc0000005 on unmodified `main` too (pre-existing, unrelated to this PR); the PR's own tests were run by name and pass.
DavidM1911 commented 2026-11-26 05:05:32 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by DavidM1911 on 2026-11-26T04:17:17Z.


Re-verification on RTX 3060 Ti (Windows 11), new head merged with current main:

  • cargo test -p xcl --lib: all passed, 0 failed, 27 ignored. The earlier merge conflict is resolved.

Thanks!

— Devin

<!-- greyfinch-sync:ivall/xcl:comment:7182462146 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1229#issuecomment-7182462146). Originally posted by [DavidM1911](https://github.com/DavidM1911) on 2026-11-26T04:17:17Z. --- Re-verification on RTX 3060 Ti (Windows 11), new head merged with current `main`: - `cargo test -p xcl --lib`: all passed, 0 failed, 27 ignored. The earlier merge conflict is resolved. Thanks! — Devin
github-actions[bot] commented 2026-11-30 08:42:45 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by github-actions[bot] on 2026-11-30T08:42:45Z.


Nothing has happened on this PR for 3 days, so it is marked stale and will be closed in 4 days. A push or a comment takes the mark off: rebase it onto main if it conflicts, and say in one line what it still fixes. If it only waits for a maintainer, a comment saying so is enough.

<!-- greyfinch-sync:ivall/xcl:comment:7273248587 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1229#issuecomment-7273248587). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-11-30T08:42:45Z. --- Nothing has happened on this PR for 3 days, so it is marked `stale` and will be closed in 4 days. A push or a comment takes the mark off: rebase it onto `main` if it conflicts, and say in one line what it still fixes. If it only waits for a maintainer, a comment saying so is enough.
Foniass commented 2026-12-01 05:10:50 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Foniass on 2026-12-01T05:10:50Z.


Triage (#1607) – head edce7c0

Overlap: #597 (open, conflicts with main) also unit-tests pr_check.py's game-file, test-data size, smoke-threshold and killed/uncommitted rules, but it creates test_pr_check.py from scratch and adds a workflow. This PR extends the file now on main. Main's BannedModelTests already covers the banned-model family names, so test_banned_models_checked_only_under_ai_use overlaps it except for the prose-mention case.
I checked every assertion against main's check(): the 80 % / 125 % boundaries, the tests/data/testgame/MicrosoftGame.config exemption, the 1 MB test-data limit, skipping removed files, and the expected message fragments ("fewer frames", "more memory", "did not end by itself", "no uncommitted changes") all match.
Recommendation: keep open.

AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.

<!-- greyfinch-sync:ivall/xcl:comment:7301501626 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1229#issuecomment-7301501626). Originally posted by [Foniass](https://github.com/Foniass) on 2026-12-01T05:10:50Z. --- **Triage (#1607)** – head edce7c0 Overlap: #597 (open, conflicts with main) also unit-tests pr_check.py's game-file, test-data size, smoke-threshold and killed/uncommitted rules, but it creates test_pr_check.py from scratch and adds a workflow. This PR extends the file now on main. Main's `BannedModelTests` already covers the banned-model family names, so `test_banned_models_checked_only_under_ai_use` overlaps it except for the prose-mention case. I checked every assertion against main's `check()`: the 80 % / 125 % boundaries, the `tests/data/testgame/MicrosoftGame.config` exemption, the 1 MB test-data limit, skipping removed files, and the expected message fragments ("fewer frames", "more memory", "did not end by itself", "no uncommitted changes") all match. Recommendation: keep open. AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.
This pull request cannot be merged automatically due to conflicts.
Merge manually to resolve the conflicts.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'upstream-pr/1229:upstream-pr/1229'
git switch 'upstream-pr/1229'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'upstream-pr/1229'
git switch 'upstream-pr/1229'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/1229'
git switch 'upstream-pr/1229'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/1229'
git switch 'main'
git merge --squash 'upstream-pr/1229'
git switch 'main'
git merge --ff-only 'upstream-pr/1229'
git switch 'main'
git merge 'upstream-pr/1229'
git push origin 'main'
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
xcl-dev/xcl!1220
No description provided.