4
4
workflow_call :
5
5
inputs :
6
6
label :
7
- description : ' ID associated to the workflow'
7
+ description : ' ID associated to the workflow. Must univocally identify artifacts. '
8
8
required : true
9
9
type : string
10
10
colcon-args :
33
33
required : false
34
34
type : boolean
35
35
default : false
36
+ run-tests :
37
+ description : ' Run test suite of Fast DDS'
38
+ required : false
39
+ type : boolean
40
+ default : true
36
41
37
42
defaults :
38
43
run :
39
44
shell : bash
40
45
41
46
jobs :
42
- reusable-mac-ci :
47
+ fastdds_build :
43
48
# As explained in https://github.com/actions/runner-images/tree/main?tab=readme-ov-file#available-images,
44
49
# *-latest images are not always the latest available versions. The minimum version of the macOS image
45
50
# with clang 15 is macos-13 (see
60
65
submodules : true
61
66
ref : ${{ inputs.fastdds-branch }}
62
67
63
- - uses : eProsima/eProsima-CI/external/setup-python@v0
68
+ - name : Install Fix Python version
69
+ uses : eProsima/eProsima-CI/external/setup-python@v0
64
70
with :
65
71
python-version : ' 3.11'
66
72
91
97
with :
92
98
api_token : ${{ secrets.GITHUB_TOKEN }}
93
99
94
- - name : Set up hosts file for DNS testing
95
- run : |
96
- sudo echo "" | sudo tee -a /etc/hosts
97
- sudo echo "127.0.0.1 localhost.test" | sudo tee -a /etc/hosts
98
- sudo echo "::1 localhost.test" | sudo tee -a /etc/hosts
99
- sudo echo "154.56.134.194 www.eprosima.com.test" | sudo tee -a /etc/hosts
100
- sudo echo "216.58.215.164 www.acme.com.test" | sudo tee -a /etc/hosts
101
- sudo echo "2a00:1450:400e:803::2004 www.acme.com.test" | sudo tee -a /etc/hosts
102
- sudo echo "140.82.121.4 www.foo.com.test" | sudo tee -a /etc/hosts
103
- sudo echo "140.82.121.3 www.foo.com.test" | sudo tee -a /etc/hosts
104
- sudo echo "ff1e::ffff:efff:1 acme.org.test" | sudo tee -a /etc/hosts
105
-
106
100
# TODO(eduponz): Set up libp11 and SoftHSM. NOTE: using SoftHSM requires adding the runner to a group,
107
101
# which entails logout/login or rebooting the machine. This is not feasible in a CI environment.
108
102
@@ -149,9 +143,74 @@ jobs:
149
143
cmake_build_type : ${{ matrix.cmake-build-type }}
150
144
workspace : ${{ github.workspace }}
151
145
146
+ - name : Upload build artifacts
147
+ uses : eProsima/eProsima-CI/external/upload-artifact@v0
148
+ with :
149
+ name : fastdds_build_${{ inputs.label }}
150
+ path : ${{ github.workspace }}
151
+
152
+ fastdds_test :
153
+ needs : fastdds_build
154
+ if : ${{ inputs.run-tests == true }}
155
+ name : fastdds_test (${{ matrix.cmake_build_type }})
156
+ runs-on : macos-13
157
+ strategy :
158
+ fail-fast : false
159
+ matrix :
160
+ cmake-build-type :
161
+ - ' RelWithDebInfo'
162
+ steps :
163
+ - name : Download build artifacts
164
+ uses : eProsima/eProsima-CI/external/download-artifact@v0
165
+ with :
166
+ name : fastdds_build_${{ inputs.label }}
167
+ path : ${{ github.workspace }}
168
+
169
+ - name : Fix permissions after downloading build artifacts
170
+ run : |
171
+ find ${{ github.workspace }}/build -type f -name "*" -exec chmod +x {} \;
172
+ find ${{ github.workspace }}/install -type f -name "*" -exec chmod +x {} \;
173
+
174
+ - name : Install Fix Python version
175
+ uses : eProsima/eProsima-CI/external/setup-python@v0
176
+ with :
177
+ python-version : ' 3.11'
178
+
179
+ - name : Get minimum supported version of CMake
180
+ uses : eProsima/eProsima-CI/external/get-cmake@v0
181
+ with :
182
+ cmakeVersion : ' 3.22.6'
183
+
184
+ - name : Install brew dependencies
185
+ uses : eProsima/eProsima-CI/macos/install_brew_packages@v0
186
+ with :
187
+ packages :
llvm tinyxml2 [email protected]
188
+ update : false
189
+ upgrade : false
190
+
191
+ - name : Install colcon
192
+ uses : eProsima/eProsima-CI/multiplatform/install_colcon@v0
193
+
194
+ - name : Install Python dependencies
195
+ uses : eProsima/eProsima-CI/multiplatform/install_python_packages@v0
196
+ with :
197
+ packages : vcstool xmlschema psutil
198
+ upgrade : false
199
+
200
+ - name : Set up hosts file for DNS testing
201
+ run : |
202
+ sudo echo "" | sudo tee -a /etc/hosts
203
+ sudo echo "127.0.0.1 localhost.test" | sudo tee -a /etc/hosts
204
+ sudo echo "::1 localhost.test" | sudo tee -a /etc/hosts
205
+ sudo echo "154.56.134.194 www.eprosima.com.test" | sudo tee -a /etc/hosts
206
+ sudo echo "216.58.215.164 www.acme.com.test" | sudo tee -a /etc/hosts
207
+ sudo echo "2a00:1450:400e:803::2004 www.acme.com.test" | sudo tee -a /etc/hosts
208
+ sudo echo "140.82.121.4 www.foo.com.test" | sudo tee -a /etc/hosts
209
+ sudo echo "140.82.121.3 www.foo.com.test" | sudo tee -a /etc/hosts
210
+ sudo echo "ff1e::ffff:efff:1 acme.org.test" | sudo tee -a /etc/hosts
211
+
152
212
- name : Colcon test
153
213
id : test
154
- if : ${{ !contains(github.event.pull_request.labels.*.name, 'no-test') }}
155
214
uses : eProsima/eProsima-CI/multiplatform/colcon_test@v0
156
215
with :
157
216
colcon_meta_file : ${{ github.workspace }}/src/fastdds/.github/workflows/config/fastdds_test.meta
@@ -164,7 +223,7 @@ jobs:
164
223
165
224
- name : Test summary
166
225
uses : eProsima/eProsima-CI/multiplatform/junit_summary@v0
167
- if : ${{ !cancelled() && !contains(github.event.pull_request.labels.*.name, 'no-test') }}
226
+ if : ${{ !cancelled() }}
168
227
with :
169
228
junit_reports_dir : " ${{ steps.test.outputs.ctest_results_path }}"
170
229
print_summary : ' True'
0 commit comments