Skip to content

Commit 48c0afe

Browse files
authored
Make run_integration_tests.sh executable (#507)
1 parent a929cbd commit 48c0afe

File tree

5 files changed

+49
-0
lines changed

5 files changed

+49
-0
lines changed
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Integration-Tests
2+
3+
on:
4+
schedule:
5+
- cron: '00 4 * * 0' # Runs at 8:00 am PST (4:00 am UTC) on Sunday
6+
workflow_dispatch:
7+
pull_request:
8+
branches:
9+
- main
10+
- develop
11+
12+
13+
jobs:
14+
ros_integration_test:
15+
runs-on: ubuntu-latest
16+
steps:
17+
- name: Checkout workspace
18+
uses: actions/checkout@v4
19+
20+
- name: ROS Integration Test
21+
uses: ./.github/actions/
22+
with:
23+
script: './scripts/run_integration_tests'

scripts/run_integration_tests.sh

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
#!/bin/bash
2+
set -e
3+
4+
if [[ $LOCAL_RUN != "true" ]]; then
5+
# give user permissions, required for GitHub Actions
6+
sudo chown -R $(whoami):$(whoami) $ROS_WORKSPACE
7+
8+
source /opt/ros/${ROS_DISTRO}/setup.bash
9+
./scripts/setup.sh
10+
./scripts/build.sh
11+
source $ROS_WORKSPACE/install/setup.bash
12+
fi
13+
ls -la
14+
sudo chown -R $(whoami):$(whoami) $ROS_WORKSPACE
15+
16+
echo "Integration tests started"
17+
cd $ROS_WORKSPACE/src/integration_tests
18+
19+
for FILE in $ROS_WORKSPACE/src/integration_tests/testplans/*; do
20+
if [ -f $FILE ]; then
21+
echo "Running $FILE test plan"
22+
ros2 run integration_tests run --ros-args -p testplan:=$FILE
23+
fi
24+
done
25+
26+
echo "Integration tests finished"

0 commit comments

Comments
 (0)