@@ -21,35 +21,49 @@ jobs:
2121 test : ${{ steps.test-matrix.outputs.matrix }}
2222 steps :
2323 - name : Harden Runner
24- uses : step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
24+ uses : step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
2525 with :
2626 egress-policy : audit
2727
28- - uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
28+ - uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
2929
3030 - uses : JoshuaTheMiller/conditional-build-matrix@81b51eb8d89e07b86404934b5fecde1cea1163a5 # v2.0.1
31- id : test-matrix
31+ id : test-matrix-base
3232 with :
3333 inputFile : ' .github/matrix_includes.json'
3434 filter : ' [?runTests==`true`]'
3535
36+ - name : Generate matrix with cmake versions
37+ id : test-matrix
38+ run : |
39+ base_matrix='${{ steps.test-matrix-base.outputs.matrix }}'
40+ cmake_versions='["vcpkg", "4.2.1"]'
41+
42+ # Create cross-product of base matrix and cmake versions
43+ result=$(jq -nc --argjson base "$base_matrix" --argjson cmake "$cmake_versions" '
44+ {include: [$base.include[] as $config | $cmake[] as $version | $config + {cmake_version: $version}]}
45+ ')
46+
47+ echo "matrix=$result" >> $GITHUB_OUTPUT
48+
3649 test :
3750 needs : [ matrix_prep ]
3851 runs-on : ${{ matrix.runs_on }}
3952 continue-on-error : true
4053 strategy :
41- matrix : ${{ fromJson(needs.matrix_prep.outputs.test) }}
54+ matrix :
55+ include : ${{ fromJson(needs.matrix_prep.outputs.test) }}
4256
4357 steps :
4458 - name : Harden Runner
45- uses : step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
59+ uses : step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
4660 with :
4761 egress-policy : audit
4862
49- - uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
63+ - uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
5064
5165 - name : Set up Python
52- uses : actions/setup-python@83679a892e2d95755f2dac6acb0bfd1e9ac5d548 # v6.1.0
66+ uses : actions/setup-python@83679a892e2d95755f2dac6acb0bfd1e9ac5d548 # v6.1.0
5367 with :
5468 python-version : ' 3.11'
5569 cache : ' pip'
@@ -59,13 +73,34 @@ jobs:
5973 pip install --upgrade pip
6074 pip install -r test/e2e/requirements.txt
6175
62- - name : Setup vcpkg environment
76+ - name : Create vcpkg config without CMake
77+ if : matrix.cmake_version != 'vcpkg'
78+ shell : bash
79+ run : |
80+ jq 'del(.requires."arm:tools/kitware/cmake")' ./test/vcpkg-configuration.json > ./test/vcpkg-configuration-temp.json
81+
82+ - name : Setup vcpkg environment (with CMake from vcpkg)
83+ if : matrix.cmake_version == 'vcpkg'
6384 uses : ARM-software/cmsis-actions/vcpkg@afc8e1a46fad8a5e1a08f8477b71050d442f60a7 # v1
6485 with :
6586 config : " ./test/vcpkg-configuration.json"
6687 vcpkg-downloads : " ${{ github.workspace }}/.vcpkg/downloads"
6788 cache : " -"
6889
90+ - name : Setup vcpkg environment (without CMake)
91+ if : matrix.cmake_version != 'vcpkg'
92+ uses : ARM-software/cmsis-actions/vcpkg@afc8e1a46fad8a5e1a08f8477b71050d442f60a7 # v1
93+ with :
94+ config : " ./test/vcpkg-configuration-temp.json"
95+ vcpkg-downloads : " ${{ github.workspace }}/.vcpkg/downloads"
96+ cache : " -"
97+
98+ - name : Install CMake ${{ matrix.cmake_version }}
99+ if : matrix.cmake_version != 'vcpkg'
100+ uses : jwlawson/actions-setup-cmake@802fa1a2c4e212495c05bf94dba2704a92a472be # v2.0.2
101+ with :
102+ cmake-version : ' ${{ matrix.cmake_version }}'
103+
69104 - name : Activate Arm tool license
70105 run : |
71106 armlm activate --server https://mdk-preview.keil.arm.com --product KEMDK-COM0
@@ -87,34 +122,34 @@ jobs:
87122 env :
88123 IAR_LMS_BEARER_TOKEN : ${{ secrets.IAR_TOKEN }}
89124 run : |
90- robot --outputdir reports-${{ matrix.target }}-${{ matrix.arch }} \
91- --variable TEST_ENV_FILE:test-env-${{ matrix.target }}-${{ matrix.arch }}.md \
92- --consolewidth=150 --settag ${{ matrix.target }}-${{ matrix.arch }} \
93- --name ${{ matrix.target }}-${{ matrix.arch }} \
125+ robot --outputdir reports-${{ matrix.target }}-${{ matrix.arch }}-cmake${{ matrix.cmake_version }} \
126+ --variable TEST_ENV_FILE:test-env-${{ matrix.target }}-${{ matrix.arch }}-cmake${{ matrix.cmake_version }} .md \
127+ --consolewidth=150 --settag ${{ matrix.target }}-${{ matrix.arch }}-cmake${{ matrix.cmake_version }} \
128+ --name ${{ matrix.target }}-${{ matrix.arch }}-cmake${{ matrix.cmake_version }} \
94129 ./e2e
95130
96131 - name : Archieve test results
97132 if : always()
98- uses : actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0
133+ uses : actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0
99134 with :
100- name : reports-${{ matrix.target }}-${{ matrix.arch }}
101- path : ./test/reports-${{ matrix.target }}-${{ matrix.arch }}
135+ name : reports-${{ matrix.target }}-${{ matrix.arch }}-cmake${{ matrix.cmake_version }}
136+ path : ./test/reports-${{ matrix.target }}-${{ matrix.arch }}-cmake${{ matrix.cmake_version }}
102137
103138 report :
104139 runs-on : ubuntu-latest
105- if : always()
106- needs : test
140+ if : always() && needs.test.result != 'skipped'
141+ needs : [ test ]
107142 permissions : write-all
108143 steps :
109144 - name : Harden Runner
110- uses : step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
145+ uses : step-security/harden-runner@20cf305ff2072d973412fa9b1e3a4f227bda3c76 # v2.14.0
111146 with :
112147 egress-policy : audit
113148
114- - uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
149+ - uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
115150
116151 - name : Set up Python
117- uses : actions/setup-python@83679a892e2d95755f2dac6acb0bfd1e9ac5d548 # v6.1.0
152+ uses : actions/setup-python@83679a892e2d95755f2dac6acb0bfd1e9ac5d548 # v6.1.0
118153 with :
119154 python-version : ' 3.11'
120155 cache : ' pip'
@@ -125,7 +160,7 @@ jobs:
125160 pip install -r test/e2e/requirements.txt
126161
127162 - name : Download reports
128- uses : actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v7.0.0
163+ uses : actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v7.0.0
129164 with :
130165 path : artifacts
131166 pattern : reports-*
@@ -135,8 +170,10 @@ jobs:
135170 continue-on-error : true
136171 run : |
137172 python -m robot.rebot --name Collective_Robot_Results --outputdir collective_robot_results --output output.xml \
138- ./reports-windows-amd64/output.xml \
139- ./reports-linux-amd64/output.xml
173+ ./reports-windows-amd64-cmakevcpkg/output.xml \
174+ ./reports-windows-amd64-cmake4.2.1/output.xml \
175+ ./reports-linux-amd64-cmakevcpkg/output.xml \
176+ ./reports-linux-amd64-cmake4.2.1/output.xml
140177
141178 - name : Generate Summary report
142179 if : always()
@@ -152,7 +189,7 @@ jobs:
152189
153190 - name : Archieve consolidated test results
154191 if : always()
155- uses : actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0
192+ uses : actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0
156193 with :
157194 name : consolidated-reports
158195 path : artifacts/collective_robot_results
0 commit comments