Open dhebbeker opened 1 year ago
The code coverage (GCDA and GCNO files) is already generated. The HTML report is missing.
This may be helpful (generated via ChatGPT):
name: Unit Test with Coverage
on: [push]
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v2
- name: Install PlatformIO
run: sudo apt-get install -y python3-pip && pip3 install -U platformio
- name: Install lcov
run: sudo apt-get install lcov
- name: Run Unit Tests with Coverage
run: |
platformio test --environment <your_environment> --project-option="build_flags=-ftest-coverage -fprofile-arcs"
- name: Generate Coverage HTML Report
run: |
lcov --capture --directory . --output-file coverage.info
lcov --remove coverage.info '/usr/*' --output-file coverage.info
genhtml coverage.info --output-directory coverage-html
- name: Upload Coverage HTML Report
uses: actions/upload-artifact@v2
with:
name: coverage-report
path: coverage-html
See WIP.
Acceptance criteria:
Depends on:
54