Skip to content

Test setup-gazebo

Test setup-gazebo #448

Workflow file for this run

name: 'Test setup-gazebo'
on:
pull_request:
push:
branches:
- main
- 'releases/*'
schedule:
# Run the CI automatically twice per day to look for flakyness.
- cron: '0 */12 * * *'
defaults:
run:
shell: bash
jobs:
test_action_linux:
name: 'Unit testing action on GitHub runners'
runs-on: ${{ matrix.ubuntu_distribution }}
strategy:
fail-fast: false
matrix:
ubuntu_distribution:
- ubuntu-20.04
- ubuntu-22.04
- ubuntu-24.04
steps:
- uses: actions/checkout@v4
- uses: actions/[email protected]
with:
node-version: '20.x'
- run: .github/workflows/build-and-test.sh
test_action_linux_docker:
name: 'Unit testing action in a docker container'
runs-on: ubuntu-latest
container:
image: ${{ matrix.docker_image }}
strategy:
fail-fast: false
matrix:
docker_image:
- ubuntu:focal
- ubuntu:jammy
- ubuntu:noble
steps:
- uses: actions/checkout@v4
- uses: actions/[email protected]
with:
node-version: '20.x'
- run: .github/workflows/build-and-test.sh
test_gazebo_install_ubuntu:
name: 'Install Gazebo on Ubuntu GitHub runner'
runs-on: ${{ matrix.ubuntu_distribution }}
strategy:
fail-fast: false
matrix:
ubuntu_distribution:
- ubuntu-20.04
- ubuntu-22.04
- ubuntu-24.04
gazebo_distribution:
- citadel
- fortress
- garden
- harmonic
exclude:
# Gazebo Citadel (Dec 2019 - Dec 2024)
# Compatible ubuntu distributions: 20.04
- ubuntu_distribution: ubuntu-22.04
gazebo_distribution: citadel
- ubuntu_distribution: ubuntu-24.04
gazebo_distribution: citadel
# Gazebo Fortress (Sep 2021 - Sep 2026)
# Compatible ubuntu distributions: 20.04
- ubuntu_distribution: ubuntu-22.04
gazebo_distribution: fortress
- ubuntu_distribution: ubuntu-24.04
gazebo_distribution: fortress
# Gazebo Garden (Sep 2022 - Nov 2024)
# Compatible ubuntu distributions: 20.04
- ubuntu_distribution: ubuntu-22.04
gazebo_distribution: garden
- ubuntu_distribution: ubuntu-24.04
gazebo_distribution: garden
# Gazebo Harmonic (Sep 2023 - Sep 2028)
# Compatible ubuntu distributions: 22.04, 24.04
- ubuntu_distribution: ubuntu-20.04
gazebo_distribution: harmonic
steps:
- uses: actions/checkout@v4
- uses: actions/[email protected]
with:
node-version: '20.x'
- name: 'Check Gazebo installation on Ubuntu runner'
uses: ./
with:
required-gazebo-distributions: ${{ matrix.gazebo_distribution }}
- name: 'Test Gazebo installation'
run: |
if command -v ign > /dev/null; then
ign gazebo --versions
elif command -v gz > /dev/null; then
gz sim --versions
else
echo "Neither ign nor gz command found"
exit 1
fi
test_gazebo_install_ubuntu_docker:
name: 'Install Gazebo on Ubuntu docker'
runs-on: ubuntu-latest
container:
image: ${{ matrix.docker_image }}
strategy:
fail-fast: false
matrix:
docker_image:
- ubuntu:focal
- ubuntu:jammy
- ubuntu:noble
gazebo_distribution:
- citadel
- fortress
- garden
- harmonic
exclude:
# Gazebo Citadel (Dec 2019 - Dec 2024)
# Compatible ubuntu docker images: focal
- docker_image: ubuntu:jammy
gazebo_distribution: citadel
- docker_image: ubuntu:noble
gazebo_distribution: citadel
# Gazebo Fortress (Sep 2021 - Sep 2026)
# Compatible ubuntu docker images: focal
- docker_image: ubuntu:jammy
gazebo_distribution: fortress
- docker_image: ubuntu:noble
gazebo_distribution: fortress
# Gazebo Garden (Sep 2022 - Nov 2024)
# Compatible ubuntu docker images: focal
- docker_image: ubuntu:jammy
gazebo_distribution: garden
- docker_image: ubuntu:noble
gazebo_distribution: garden
# Gazebo Harmonic (Sep 2023 - Sep 2028)
# Compatible ubuntu docker images: jammy, noble
- docker_image: ubuntu:focal
gazebo_distribution: harmonic
steps:
- uses: actions/checkout@v4
- uses: actions/[email protected]
with:
node-version: '20.x'
- name: 'Check Gazebo installation on Ubuntu runner'
uses: ./
with:
required-gazebo-distributions: ${{ matrix.gazebo_distribution }}
- name: 'Test Gazebo installation'
run: |
if command -v ign > /dev/null; then
ign gazebo --versions
elif command -v gz > /dev/null; then
gz sim --versions
else
echo "Neither ign nor gz command found"
exit 1
fi
test_gazebo_install_ubuntu_prerelease_docker:
name: 'Install Gazebo pre-release on Ubuntu docker'
runs-on: ubuntu-latest
container:
image: ${{ matrix.docker_image }}
strategy:
fail-fast: false
matrix:
docker_image:
- ubuntu:jammy
- ubuntu:noble
steps:
- uses: actions/checkout@v4
- uses: actions/[email protected]
with:
node-version: '20.x'
- name: 'Check Gazebo installation on Ubuntu runner'
uses: ./
with:
required-gazebo-distributions: 'harmonic'
use-gazebo-prerelease: 'true'
- name: 'Test Gazebo installation'
run: 'gz sim --versions'
test_gazebo_install_ubuntu_nightly_docker:
name: 'Install Gazebo nightly on Ubuntu docker'
runs-on: ubuntu-latest
container:
image: ubuntu:noble
steps:
- uses: actions/checkout@v4
- uses: actions/[email protected]
with:
node-version: '20.x'
- name: 'Check Gazebo installation on Ubuntu runner'
uses: ./
with:
required-gazebo-distributions: 'ionic'
use-gazebo-nightly: 'true'
- name: 'Test Gazebo installation'
run: 'gz sim --versions'
test_gazebo_install_macos:
name: 'Install Gazebo on macOS'
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
# macOS Ventura
- macos-13
# macOS Sonoma
- macos-14
steps:
- uses: actions/checkout@v4
- uses: actions/[email protected]
with:
node-version: '20.x'
- name: 'Check Gazebo installation on macOS runner'
uses: ./
with:
required-gazebo-distributions: 'harmonic'
- name: 'Test Gazebo installation'
run: 'gz sim --versions'
test_gazebo_install_windows:
name: 'Install Gazebo on Windows'
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- uses: actions/[email protected]
with:
node-version: '20.x'
- uses: conda-incubator/setup-miniconda@v3
- name: 'Check Gazebo installation on Windows runner'
uses: ./
with:
required-gazebo-distributions: 'harmonic'
- name: 'Test Gazebo installation'
shell: pwsh
run: |
conda activate
gz sim --versions
test_install_ros_gz_unofficial:
name: 'Install Iron and Harmonic side-by-side'
env:
ROS_DISTROS: 'iron'
runs-on: ubuntu-latest
container:
image: ubuntu:jammy
steps:
- uses: actions/checkout@v4
- uses: actions/[email protected]
with:
node-version: '20.x'
- name: 'Install ROS 2 Iron'
uses: ros-tooling/[email protected]
with:
required-ros-distributions: ${{ env.ROS_DISTROS }}
- name: 'Install Gazebo Harmonic with ros_gz'
uses: ./
with:
required-gazebo-distributions: 'harmonic'
install-ros-gz: ${{ env.ROS_DISTROS }}
- name: Test Iron ros_gz installation
run: |
source /opt/ros/iron/setup.bash
ros2 pkg list | grep ros_gz
gz sim --version | grep 'version 8.[0-9*].[0-9*]'
test_install_ros_gz_official:
name: 'Install Humble and Fortress side-by-side'
env:
ROS_DISTROS: 'humble'
runs-on: ubuntu-latest
container:
image: ubuntu:jammy
steps:
- uses: actions/checkout@v4
- uses: actions/[email protected]
with:
node-version: '20.x'
- name: 'Install ROS 2 Humble'
uses: ros-tooling/[email protected]
with:
required-ros-distributions: ${{ env.ROS_DISTROS }}
- name: 'Install Gazebo with ros_gz'
uses: ./
with:
required-gazebo-distributions: 'fortress'
install-ros-gz: ${{ env.ROS_DISTROS }}
- name: Test Humble ros_gz installation
run: |
source /opt/ros/humble/setup.bash
ros2 pkg list | grep ros_gz
ign gazebo --version | grep 'version 6.*'
test_install_ros_gz_vendor:
name: 'Install Harmonic on Jazzy through vendor packages'
env:
ROS_DISTROS: 'jazzy'
runs-on: ubuntu-latest
container:
image: ubuntu:noble
steps:
- uses: actions/checkout@v4
- uses: actions/[email protected]
with:
node-version: '20.x'
- name: 'Install ROS 2 Jazzy'
uses: ros-tooling/[email protected]
with:
required-ros-distributions: ${{ env.ROS_DISTROS }}
- name: 'Install Gazebo with ros_gz'
uses: ./
with:
required-gazebo-distributions: 'harmonic'
install-ros-gz: ${{ env.ROS_DISTROS }}
- name: Test Jazzy ros_gz installation
run: |
source /opt/ros/jazzy/setup.bash
! [ $(apt list --installed gz-harmonic) ]
ros2 pkg list | grep ros_gz
gz sim --version | grep 'version 8.[0-9*].[0-9*]'