diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index 7981a1b..5b16ba8 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -5,8 +5,8 @@ on: push: branches: [main] jobs: - individual-setup-build: - name: Individual Setup and build + individual-setup-build-test: + name: Individual Setup, Build and Test runs-on: ubuntu-22.04 strategy: fail-fast: false @@ -36,6 +36,11 @@ jobs: with: distro: ${{ matrix.distro }} + - name: Test workspace + uses: ./test + with: + distro: ${{ matrix.distro }} + setup-build-test: name: Setup, Build, and Test runs-on: ubuntu-22.04 diff --git a/action.yml b/action.yml index 6b03271..f5f4d28 100644 --- a/action.yml +++ b/action.yml @@ -18,7 +18,4 @@ runs: - uses: ichiro-its/ros2-ws-action/build@18f8d40805c2668f07b836763824d99bb6e33f9b - - shell: bash - run: | - source install/setup.bash - colcon test --event-handlers console_cohesion+ --pytest-with-coverage --return-code-on-test-failure + - uses: ichiro-its/ros2-ws-action/test@3aa0cc0847b20cb0b907952964d5c4e3594c1924 diff --git a/test/action.yaml b/test/action.yaml new file mode 100644 index 0000000..aee2ffa --- /dev/null +++ b/test/action.yaml @@ -0,0 +1,13 @@ +name: ROS 2 Workspace Test +description: Test packages in a ROS 2 workspace +author: ICHIRO ITS +branding: + icon: activity + color: gray-dark +runs: + using: composite + steps: + - shell: bash + run: | + source install/setup.bash + colcon test --event-handlers console_cohesion+ --pytest-with-coverage --return-code-on-test-failure