-
Notifications
You must be signed in to change notification settings - Fork 2
65 lines (55 loc) · 1.69 KB
/
build_and_test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
name: ROS2 Build and Test CI
on:
push:
workflow_dispatch:
jobs:
build_and_test:
runs-on: ubuntu-20.04
container:
image: hashaam1217/subbots_triton_testing:1.0.1
steps:
- name: Ensure Permissions
run: |
sudo mkdir -p /__w/_temp
sudo mkdir -p /__w/_actions
sudo chmod -R 777 /__w/_temp
sudo chmod -R 777 /__w/_actions
- name: Update and upgrade
run: |
sudo apt update -y
sudo apt upgrade -y
- name: Check out ubc-subbots/triton
uses: actions/checkout@v2
- name: Install deps with rosdep
run: |
rosdep init
rosdep update --include-eol
rosdep install -i --from-path src --rosdistro foxy -y
- name: Cache OpenCV
id: opencv-cache
uses: actions/cache@v2
with:
path: ./opencv-install
key: ${{ runner.os }}-opencv-cache
- name: Install OpenCV
uses: rayandrews/with-opencv-action@v1
with:
dir: ./opencv-install
cached: ${{ steps.opencv-cache.outputs.cache-hit }}
opencv-version: '4.5.3'
CMAKE_BUILD_TYPE: RELEASE
ENABLE_PRECOMPILED_HEADERS: OFF
- name: Ignore with colcon build
run: |
touch ./opencv-install/COLCON_IGNORE
- name: Source setup and build then test using colcon
shell: bash
env:
LD_LIBRARY_PATH: /usr/local/lib/
run: |
source /opt/ros/foxy/setup.bash
source /usr/share/gazebo/setup.sh
colcon build --cmake-args -DCMAKE_CXX_STANDARD=14
source ./install/setup.bash
colcon test
colcon test-result --verbose