Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 17 additions & 12 deletions .github/workflows/basic_w_report.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
name: Compile - Run - Report
name: Compile - Run - Report
on:
workflow_dispatch:
workflow_dispatch:
pull_request:
branches: [main]
push:
branches: [main]
schedule:
- cron: '30 22 * * 0' # Run every Sunday at 22:30

permissions:
permissions:
contents: read
actions: read
checks: write
Expand All @@ -26,38 +26,43 @@ jobs:
uses: actions/setup-python@v6
with:
python-version: '3.13'
- run:

- name: Install Python packages
run:
pip install junit_reporter

# Install vcpkg tools from the vcpkg-configuration.json and activate an Arm tools license
- name: Activate vcpkg
uses: ARM-software/cmsis-actions/vcpkg@v1

- name: Activate Arm tool license
uses: ARM-software/cmsis-actions/armlm@v1

# Build the project, run the test and convert the log to junit format

- name: Build
run: |
echo "Building get started example ..."
cbuild get_started.csolution.yml --packs --update-rte --context .debug+avh
cbuild get_started.csolution.yml --packs --update-rte --context .debug+avh

- name: Execute
run: |
echo "Running get started example ..."
FVP_MPS2_Cortex-M3 --simlimit 10 -f Project/fvp_config.txt -a out/Project/avh/debug/Project.axf | tee Project.avh.log

- name: Convert log to junit
if: success() || failure()
run: |
echo "Converting log to junit..."
python Project/report.py Project.avh.log
cat Project.avh.xml

# Upload the junit report to the check run of the workflow
- name: Test Report
uses: phoenix-actions/test-reporting@v16
if: success() || failure() # run this step even if previous step failed
with:
name: Test Report # Name of the check run which will be created
path: Project.avh.xml # Path to test results
reporter: jest-junit # Format of test results
name: Test Report # Name of the check run which will be created
path: Project.avh.xml # Path to test results
reporter: jest-junit # Format of test results
# This keeps one workflow and avoids creating a Check Run on PRs, where fork tokens may be read-only.
# After merge / push to main, it still creates the Check Run.
output-to: ${{ github.event_name == 'pull_request' && 'step-summary' || 'checks' }}