Skip to content

Enable npm test on Windows workflow #1158

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 9 commits into
base: develop
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 3 additions & 30 deletions .github/workflows/windows-build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,50 +17,23 @@ on:

jobs:
build:
runs-on: windows-2019
runs-on: windows-2025
strategy:
fail-fast: false
matrix:
node-version: [22.X]
ros_distribution:
- humble
- jazzy
- kilted
- rolling
steps:
- name: Setup Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}

- name: Setup ROS2
uses: ros-tooling/[email protected]
with:
required-ros-distributions: ${{ matrix.ros_distribution }}

- name: Install ROS2 Rolling (Conditional)
if: ${{ matrix.ros_distribution == 'rolling' }}
shell: bash
run: |
wget --quiet https://ci.ros2.org/view/packaging/job/packaging_windows/lastSuccessfulBuild/artifact/ws/ros2-package-windows-AMD64.zip -O rolling.zip
7z x rolling.zip -y -o/c/dev/rolling

- name: Prebuild - Setup VS Dev Environment
uses: seanmiddleditch/gha-setup-vsdevenv@v4

- uses: actions/checkout@v4

- name: Build rclnodejs
shell: cmd
run: |
set RMW_IMPLEMENTATION=rmw_fastrtps_cpp
call "c:\dev\${{ matrix.ros_distribution }}\ros2-windows\setup.bat"
npm i

# On the windows/foxy combination the Eclipse CycloneDDS RMW implementation is used to workaround
# an error when loading the default fastrtps ddl
- name: Test rclnodejs
- name: Run demo
shell: cmd
run: |
set RMW_IMPLEMENTATION=rmw_fastrtps_cpp
call "c:\dev\${{ matrix.ros_distribution }}\ros2-windows\setup.bat"
cmd /c "ros2 run demo_nodes_cpp talker"
Loading