Repository navigation
Add resource_cast coverage for RMM resources - #2386
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughSummary by CodeRabbit
WalkthroughAdded two test cases to ChangesResource Cast with Limiting Adaptor Tests
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Possibly related PRs
Suggested reviewers
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@cpp/tests/mr/resource_ref_conversion_tests.cpp`:
- Around line 222-247: Rename the two Google Test cases and the constexpr locals
to follow repository naming rules: change TEST(ResourceCast,
FindsConcreteResourceInAnyResource) to TEST(ResourceCast,
finds_concrete_resource_in_any_resource) and TEST(ResourceCast,
FindsConcreteResourceInDeviceAsyncResourceRef) to TEST(ResourceCast,
finds_concrete_resource_in_device_async_resource_ref); also rename the constexpr
std::size_t local named limit to SCREAMING_SNAKE_CASE (e.g., LIMIT) in both
tests so all usages (ASSERT/EXPECT comparisons and limiter construction) are
updated accordingly; leave other local variable names (cuda_mr, limiter,
resource, ref) and the resource_cast calls unchanged.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Enterprise
Run ID: 495cb8e2-fcae-4fe2-add2-e3059161ddd8
📒 Files selected for processing (1)
cpp/tests/mr/resource_ref_conversion_tests.cpp
|
/merge |
Description
Adds C++ test coverage for
cuda::mr::resource_castwith RMM concrete resources. The tests verify successful recovery fromcuda::mr::any_resource<cuda::mr::device_accessible>andrmm::device_async_resource_ref, and verify wrong-type casts returnnullptr.Follow-up from #2011.
Checklist