Tests refactoring - #1
Merged
Merged
Conversation
Signed-off-by: tzielinski-habana <tomasz.zielinski@intel.com>
There was a problem hiding this comment.
Copilot reviewed 7 out of 7 changed files in this pull request and generated no comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
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.
This pull request updates the determinism test suite to provide more accurate device-based test skipping and to improve coverage for both CUDA and XPU platforms. The changes standardize the use of new decorators for skipping tests depending on device support, add more granular skipping logic for XPU backends, and introduce a new test for RMS norm batch invariance.
Test skipping and device support improvements:
Replaced the old
skip_unsupportedandskip_unsupported_xpudecorators with the newskip_if_not_cuda,skip_if_not_xpu, andskip_unsupported_devicedecorators throughout the test files to more accurately reflect device requirements and improve test reliability across CUDA and XPU platforms. (tests/v1/determinism/test_batch_invariance.py,tests/v1/determinism/test_matmul_batch_invariant.py,tests/v1/determinism/test_nvfp4_batch_invariant.py,tests/v1/determinism/test_online_batch_invariance.py,tests/v1/determinism/test_rms_norm_batch_invariant.py,tests/v1/determinism/utils.py) [1] [2] [3] [4] [5] [6]Added
skip_unsupported_devicedecorator andXPU_BACKENDSlist inutils.py, and updated batch invariance tests to skip unverified backends on XPU, ensuring only supported configurations are tested. (tests/v1/determinism/test_batch_invariance.py,tests/v1/determinism/utils.py) [1] [2] [3] [4] [5] [6]Test coverage and new tests:
Added a new test
test_rms_norm_batch_invarianceto verify that RMS norm outputs are batch-invariant, improving coverage for this core property. (tests/v1/determinism/test_rms_norm_batch_invariant.py)Updated all relevant test functions to use the new device-aware skipping logic, ensuring tests are only run on supported hardware and improving CI reliability. (
tests/v1/determinism/test_matmul_batch_invariant.py,tests/v1/determinism/test_rms_norm_batch_invariant.py,tests/v1/determinism/test_nvfp4_batch_invariant.py,tests/v1/determinism/test_online_batch_invariance.py) [1] [2] [3] [4] [5] [6] [7] [8] [9] [10]These changes make the test suite more robust and ensure that determinism tests are accurately targeted to the supported hardware backends.