Fix 'rapids_add_test could not infer a target to install' warnings #12056
<!-- This is an auto-generated comment: summarize by coderabbit.ai -->
<!-- review_stack_entry_start -->
<a href="https://app.coderabbit.ai/change-stack/NVIDIA/cccl/pull/12056?scope=ghh_OusAJGA4HG8ljoOV0wJvVx8NmnZIjc2DdjmxOu0xZWA&cs_source=review_comment"><picture><source media="(prefers-color-scheme: dark)" srcset="https://storage.googleapis.com/coderabbit_public_assets/review-stack-in-coderabbit-ui-dark.svg?v=3"><source media="(prefers-color-scheme: light)" srcset="https://storage.googleapis.com/coderabbit_public_assets/review-stack-in-coderabbit-ui.svg?v=3"><img src="https://storage.googleapis.com/coderabbit_public_assets/review-stack-in-coderabbit-ui.svg?v=3" alt="Review in Change Stack →" height="32"></picture></a>
<!-- review_stack_entry_end -->
<!-- recent_review_start -->
No actionable comments were generated in the recent review. 🎉
<details>
<summary><strong>ℹ️ Recent review info</strong></summary>
<dl>
<dd>
<details>
<summary><strong>⚙️ Run configuration</strong></summary>
<dl>
<dd>
65ab4fcc-614e-4fc2-9ec4-c941c1f86fdd</dd>
</dl>
</details>
<details>
<summary><strong>📥 Commits</strong></summary>
<dl>
<dd>
Reviewing files that changed from the base of the PR and between 38671dcfbed77c287817282c6411bb615179dfb9 and 6e17370087fc18d1dc70f27e17c840da007a01d1.
</dd>
</dl>
</details>
<details>
<summary><strong>📒 Files selected for processing: 1</strong></summary>
<dl>
<dd>
cub/test/CMakeLists.txt
</dd>
</dl>
</details>
Included review availability: This review used your included allowance. Your plan provides up to 12 included reviews per hour; 11 remain after this review.
</dd>
</dl>
</details>
<!-- recent_review_end -->
<!-- walkthrough_start -->
<details>
<summary><strong>📝 Summary</strong></summary>
<dl>
<dd>
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
Summary by CodeRabbit
Tests
* Updated test registration for standard and large-memory Catch2 tests, as well as non-Catch2 runtime tests, so each is associated with its executable target. These changes affect the project’s test setup and do not add or change end-user features.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
Three CUB test registrations now pass their executable targets through INSTALL_TARGET: standard-memory Catch2 tests, large-memory Catch2 tests, and non-Catch2 runtime tests.
Changes: Test install target registration
|Layer / File(s)|Summary|
|:---|:---|
|Register test executable targets <br> cub/test/CMakeLists.txt|The standard-memory Catch2, large-memory Catch2, and non-Catch2 runtime test registrations now pass their corresponding executable targets as INSTALL_TARGET.|
</dd>
</dl>
</details>
<!-- walkthrough_end -->
<!-- change_assessment_start -->
Priority: ⬇️ Low
<!-- change_assessment_commit:"6e17370087fc18d1dc70f27e17c840da007a01d1" -->
Change: Bug fix
<!-- change_assessment_end -->
<details>
<summary><strong>Merge Risk:</strong> <strong>⚪ Minimal</strong> · up to <code>6e173</code></summary>
<dl>
<dd>
<!-- final_review_risk_start -->
<!-- final_review_risk_label
Merge Risk: ⚪ Minimal · up to 6e173
-->
<!-- final_review_risk_coverage:{"sourceCommitId":"6e17370087fc18d1dc70f27e17c840da007a01d1","coveredCommitId":"6e17370087fc18d1dc70f27e17c840da007a01d1","kind":"reviewed"} -->
The test registrations use a supported option to avoid target-inference warnings. No identified issue prevents merging after normal checks.
<!-- final_review_risk_end -->
</dd>
</dl>
</details>
<!-- autopilot:start -->
<!-- autopilot:end -->
<!-- tips_start -->
<sub>Comment @coderabbitai help to get the list of available commands.</sub>
<!-- tips_end -->
Approved these changes.
🥳 CI Workflow Results
🟩 Finished in 2h 45m: Pass: 100%/137 | Total: 2d 22h | Max: 2h 33m | Hits: 99%/125486
See results here.
<!-- Sticky Pull Request Commentci-results -->
Approved these changes.
@robertmaynard Note that the INSTALL_TARGET option does not appear to be documented https://github.com/rapidsai/rapids-cmake/blob/main/rapids-cmake/test/add.cmake#L9-L58. Is that intended?
@robertmaynard Note that the INSTALL_TARGET option does not appear to be documented https://github.com/rapidsai/rapids-cmake/blob/main/rapids-cmake/test/add.cmake#L9-L58. Is that intended?
Missed adding the docs when we added that feature ( https://github.com/rapidsai/rapids-cmake/pull/692 )
Approved these changes.
fbusato
Jacobfaib
Description
<!-- Every PR should have a corresponding issue that describes and motivates the work done in the PR -->
Fixes
<!-- Provide a standalone description of changes in this PR. -->
<!-- Note: The pull request title will be included in the CHANGELOG. -->
<!--
Note: CodeRabbit is enabled on this repository as a convenience for maintainers
and contributors. Use your best judgment when considering its review comments and
suggestions — a suggested change may be inadequate, unnecessary, or safe to ignore.
Contributors are not expected to address every comment. Human reviews are what
ultimately matter for merging.
-->
Checklist
<!-- TODO: - [ ] I am familiar with the [Contributing Guidelines](). -->