|
Ran
|
Jobs
1
|
Files
53
|
Run time
1min
|
Badge
README BADGES
|
push
github
Add support check for content filter feature in subscription (#1451) Corresponding to rclpy [d892204](https://github.com/ros2/rclpy/commit/d892204c2) and rcl's `rcl_subscription_is_cft_supported()` API, this adds `isContentFilterSupported()` to the `Subscription` class. This allows users to query at runtime whether the underlying RMW supports content-filtered topics for a given subscription, rather than relying on hardcoded RMW name checks. Currently gated to ROS 2 Rolling only (`ROS_VERSION > 2505`); on older distros it returns `false`. ### Feature changes - **src/rcl_subscription_bindings.cpp** — Added `IsContentFilterSupported()` N-API function calling `rcl_subscription_is_cft_supported()`, guarded by `#if ROS_VERSION > 2505`. Added `#include <rcl/subscription.h>`. Registered as `"isContentFilterSupported"` in `InitSubscriptionBindings()`. - **lib/subscription.js** — Added `isContentFilterSupported()` method with a distro guard (`DistroUtils.getDistroId() < ROLLING` returns `false`). Added `DistroUtils` import. - **types/subscription.d.ts** — Added `isContentFilterSupported(): boolean` to the `Subscription` interface. - **test/test-subscription-content-filter.js** — Added a separate top-level `describe('subscription isContentFilterSupported')` block that runs on all distros. Validates the return value accounts for both the rolling requirement and RMW capability. - **test/types/index.test-d.ts** — Added `expectType<boolean>` assertion for `isContentFilterSupported()`. ### CI changes - **.github/workflows/linux-x64-build-and-test.yml** — Replaced `setup-ros` with `use-ros2-testing` for rolling with a nightly binary tarball approach, following the [official ROS 2 Rolling binary installation guide](https://docs.ros.org/en/rolling/Installation/Alternatives/Ubuntu-Install-Binary.html): - Configures ROS apt sources via `ros2-apt-source` deb package. - Installs apt packages (`test-msgs`, `mrpt-msgs`, `colcon`, `rosd... (continued)
1480 of 1868 branches covered (79.23%)
Branch coverage included in aggregate %.
3 of 4 new or added lines in 1 file covered. (75.0%)
3039 of 3386 relevant lines covered (89.75%)
448.95 hits per line
| Lines | Coverage | ∆ | File |
|---|---|---|---|
| 1 |
89.74 |
-1.92% | lib/subscription.js |
| ID | Job ID | Ran | Files | Coverage | |
|---|---|---|---|---|---|
| 1 | 23632893791.1 | 53 |
86.01 |
GitHub Action Run |
| Coverage | ∆ | File | Lines | Relevant | Covered | Missed | Hits/Line | Branch Hits | Branch Misses |
|---|