11 group: ${{ github.workflow }}-${{ github.ref }}
12 cancel-in-progress: true
15 CMSIS_PACK_ROOT: ${{ github.workspace }}/.packs
16 ARM_UBL_ACTIVATION_CODE: ${{ secrets.ARM_UBL_ACTIVATION_CODE }}
23 compiler: [AC6, GCC, Clang]
28 - name: Checkout CMSIS-FreeRTOS
29 uses: actions/checkout@v4
34 - name: Checkout CMSIS_6
35 uses: actions/checkout@v4
37 repository: ARM-software/CMSIS_6
40 - name: Checkout CMSIS-RTOS2_Validation
41 uses: actions/checkout@v4
43 repository: ARM-software/CMSIS-RTOS2_Validation
44 path: CMSIS-RTOS2_Validation
46 - name: Checkout Cortex_DFP
47 uses: actions/checkout@v4
49 repository: ARM-software/Cortex_DFP
52 - name: Setup Python 3.10
53 uses: actions/setup-python@v5
55 python-version: '3.10'
57 - name: Install system packages
59 sudo add-apt-repository ppa:deadsnakes/ppa
60 sudo apt-get install libpython3.9 libtinfo6
62 - name: Python requirements
64 pip install -r ./CMSIS-RTOS2_Validation/Project/requirements.txt
67 uses: actions/cache@v4
69 key: packs-${{ github.run_id }}-${{ matrix.compiler }}
72 path: /home/runner/.cache/arm/packs
74 - name: Setup vcpkg environment
75 uses: ARM-software/cmsis-actions/vcpkg@main
77 config: ./CMSIS-RTOS2_Validation/Project/vcpkg-configuration.json
78 cache: "-${{ matrix.compiler }}"
80 - name: Activate Arm tool license
82 if [[ -n "${{ env.ARM_UBL_ACTIVATION_CODE }}" ]]; then
83 armlm activate --code ${{ env.ARM_UBL_ACTIVATION_CODE }}
85 armlm activate --server https://mdk-preview.keil.arm.com --product KEMDK-COM0
88 - name: Register local packs
90 cpackget init https://www.keil.com/pack/index.pidx
91 cpackget rm ARM::CMSIS ARM::CMSIS-FreeRTOS ARM::Cortex_DFP || echo "Ok"
93 cpackget add ./CMSIS_6/ARM.CMSIS.pdsc
94 cpackget add ./CMSIS-FreeRTOS/ARM.CMSIS-FreeRTOS.pdsc
95 cpackget add ./Cortex_DFP/ARM.Cortex_DFP.pdsc
96 cpackget add -an ARM.CMSIS-RTX
98 - uses: ammaraskar/gcc-problem-matcher@master
99 if: matrix.compiler == 'GCC'
102 working-directory: ./CMSIS-RTOS2_Validation/Project
104 echo "Build test projects ..."
105 ./build.py --verbose -r FreeRTOS -c ${{ matrix.compiler }} build || echo "::warning::=== Some configurations failed to build! ==="
108 working-directory: ./CMSIS-RTOS2_Validation/Project
110 echo "Run test projects ..."
111 ./build.py --verbose -r FreeRTOS -c ${{ matrix.compiler }} run || echo "::warning::==== Some configurations failed to run! ==="
113 - name: Deactivate Arm tool license
115 working-directory: ./CMSIS-RTOS2_Validation/Project
117 if [[ -n "${{ env.ARM_UBL_ACTIVATION_CODE }}" ]]; then
118 armlm deactivate --code ${{ env.ARM_UBL_ACTIVATION_CODE }}
120 armlm deactivate --product KEMDK-COM0
123 - name: Upload Test Reports
124 if: ${{ !cancelled() }}
125 uses: actions/upload-artifact@v4
127 name: test-results-${{ matrix.compiler }}
128 path: ./CMSIS-RTOS2_Validation/Project/*.junit
131 publish-test-results:
132 needs: [build-and-run]
133 runs-on: ubuntu-24.04
134 if: github.event_name == 'pull_request'
137 GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
140 - name: Download Test Reports
141 uses: actions/download-artifact@v4
145 - name: Publish Test Results
146 if: ${{ env.GITHUB_TOKEN }}
147 uses: EnricoMi/publish-unit-test-result-action@v2
149 commit: ${{ github.event.workflow_run.head_sha }}
150 event_file: ${{ github.event_path }}
151 report_individual_runs: true
152 event_name: ${{ github.event.workflow_run.event }}
153 files: "artifacts/**/*.junit"