Skip to content

test : [amdsmi] Add test filter standardization#8995

Draft
dileepr1 wants to merge 1 commit into
developfrom
users/dravindr/tf_amdsmi
Draft

test : [amdsmi] Add test filter standardization#8995
dileepr1 wants to merge 1 commit into
developfrom
users/dravindr/tf_amdsmi

Conversation

@dileepr1

Copy link
Copy Markdown
Contributor

Summary

Adds test-filter / test-category standardization for amdsmi, so TheRock's generic test_runner.py can drive ctest -L {quick|standard|comprehensive|full} for the amdsmitst gtest suite from the installed tree.

Paired with TheRock branch users/dravindr/tr_amdsmi (switches the amdsmi test_script to test_runner.py and adds a COMPONENT_OVERRIDES entry pointing ctest at share/amd_smi/tests/ctest).

Follows the same shared shared/ctest infrastructure as other rocm-systems components; closest analog is rocrtst (gtest binary installed under share/, install-time CTestTestfile.cmake + COMPONENT_OVERRIDES test_dir).

Changes

  • projects/amdsmi/tests/amd_smi_test/test_categories.yaml (new) — quick/standard/comprehensive/full categories with a shared _common_excludes anchor and per-arch exclude_gpu blocks (ex_gpu_gfx90a, ex_gpu_gfx110X, ex_gpu_gfx103X). Patterns/excludes mirror the legacy TheRock/build_tools/github_actions/test_executable_scripts/test_amdsmi.py filters and amdsmitst.exclude.
  • projects/amdsmi/CMakeLists.txt — set ROCM_SYSTEMS_ROOT (guarded) so shared/ctest can be located.
  • projects/amdsmi/tests/amd_smi_test/CMakeLists.txt — include shared/ctest/TestCategories.cmake (guarded), call apply_test_category_labels(amdsmitst ...), and install the generated CTestTestfile.cmake to share/amd_smi/tests/ctest/. It is installed one directory below the amdsmitst binary so the parser's relative ../amdsmitst path resolves. Guarded on shared/ctest so standalone / sparse checkouts keep building.
  • TheRock CI workflow refs — point the 7 general therock-*.yml workflows at users/dravindr/tr_amdsmi so the build+test use the paired TheRock changes.

Notes

  • No artifact-toml change is needed on the TheRock side: amdsmi's tests (and now the generated CTestTestfile.cmake under share/amd_smi/tests/ctest/) already ship in the core-amdsmi_run artifact via the existing share/amd_smi/** glob, which --base-only fetches.

Verification (local)

  • Parser output correct; simulated install-tree ctest -N (13 suites), ctest --print-labels, ctest -L ^quick$, and generic-vs-gfx90a label selection all behave correctly.
  • Minimal CMake configure + --install places CTestTestfile.cmake at share/amd_smi/tests/ctest/.

⚠️ WIP before merge

The 7 TheRock workflow refs currently point at users/dravindr/tr_amdsmi. Revert them to a pinned ROCm/TheRock SHA once the paired tr_amdsmi PR merges.

Made with Cursor

Add quick/standard/comprehensive/full CTest categorization for the
amdsmitst gtest suite so TheRock's generic test_runner.py can drive
`ctest -L <category>` from the installed tree.

- projects/amdsmi/tests/amd_smi_test/test_categories.yaml: categories +
  shared exclude anchor + per-arch exclude_gpu blocks, mirroring the
  legacy TheRock test_amdsmi.py filters and amdsmitst.exclude.
- projects/amdsmi/CMakeLists.txt: set ROCM_SYSTEMS_ROOT for shared/ctest.
- tests/amd_smi_test/CMakeLists.txt: include shared/ctest, call
  apply_test_category_labels(amdsmitst ...) and install the generated
  CTestTestfile.cmake to share/amd_smi/tests/ctest so the relative
  "../amdsmitst" path resolves. Guarded on shared/ctest so standalone
  checkouts keep building.
- Point TheRock CI workflows at users/dravindr/tr_amdsmi.

WIP: revert the TheRock workflow refs to a pinned ROCm/TheRock SHA
before merge, once the paired tr_amdsmi PR lands.

Co-authored-by: Cursor <cursoragent@cursor.com>
@dileepr1
dileepr1 requested a review from a team July 21, 2026 22:46
@dileepr1
dileepr1 requested a review from a team as a code owner July 21, 2026 22:46
@github-actions github-actions Bot added project: amdsmi github actions Pull requests that update GitHub Actions code labels Jul 21, 2026
@therock-pr-bot

Copy link
Copy Markdown

❌ PR Check — Action Required

Check Status Details
🌿 Branch Name ✅ Pass
📝 PR Title/Description ❌ Fail Error: PR description must reference a JIRA ID, ISSUE ID, or a GitHub closing keyword.
Expected: include a JIRA ID / ISSUE ID line (separator : or -, or omitted; value may be a JIRA key, a number with/without #, or a link), OR a closing keyword + issue reference. Accepted examples:
JIRA ID : TESTAUTO-6039
JIRA ID - #330
JIRA ID #330
JIRA ID (on separate line)
ROCM-25757
ISSUE ID : TESTUTO-3334
ISSUE ID #3334
ISSUE ID - TESTAUTO-3433
ISSUE ID (on separate line)
AIRUNTIME-2352
ISSUE ID : https://github.com/<org_name>/<repo_name>/issues/1234
Closes #10
Fixes octo-org/octo-repo#100
Resolves: #123
#123
https://github.com/<org_name>/<repo_name>/issues/123
Current: no valid JIRA/ISSUE/closing-keyword reference found
Forbidden Files ✅ Pass
🧪 Unit Test ✅ Pass PR does not contain code files — Unit Test auto-passed
🔎 pre-commit ⏳ Pending ⏳ Still running…
🚫 Draft PR 🔜 To Be Enabled
🚩 Feature Flag 🔜 To Be Enabled
📊 Code Coverage 🔜 To Be Enabled

⚠️ 1 policy check(s) failed. Please address the issues above before this PR can be Reviewed.

🚫 Please fix the failed policies

  • ❌ PR Title/Description

The Not ready to Review label was added to this PR. Once all policies pass, the label is removed automatically.

📖 Need help? See the Policy FAQ for details on every check and how to fix failures.

@therock-pr-bot

Copy link
Copy Markdown

🚫 Please fix the failed policies before requesting reviews.

The following policy checks failed:

  • ❌ PR Title/Description

The Not ready to Review label has been added to this PR.
Once all policies pass, the label will be removed automatically.

@dileepr1
dileepr1 marked this pull request as draft July 21, 2026 22:52
@dileepr1 dileepr1 changed the title [amdsmi] Add test filter standardization test : [amdsmi] Add test filter standardization Jul 21, 2026
dileepr1 added a commit to ROCm/TheRock that referenced this pull request Jul 22, 2026
Bump the rocm-systems submodule to the tip of the paired branch
users/dravindr/tf_amdsmi (ROCm/rocm-systems@53a45d9e), which adds the
amdsmi test_categories.yaml and installs
share/amd_smi/tests/ctest/CTestTestfile.cmake via
apply_test_category_labels(). This lets TheRock CI build amdsmi with
the install-time CTest categories so test_runner.py can run
`ctest -L <category>`.

WIP: revert the submodule pin to a rocm-systems develop SHA once the
tf_amdsmi PR (ROCm/rocm-systems#8995) merges.

Co-authored-by: Cursor <cursoragent@cursor.com>
@dileepr1

Copy link
Copy Markdown
Contributor Author

Paired TheRock PR (draft): ROCm/TheRock#6784 — switches the amdsmi test job to test_runner.py and pins the rocm-systems submodule at this branch (users/dravindr/tf_amdsmi).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant