Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
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
34 changes: 0 additions & 34 deletions .cirrus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,23 +27,6 @@ jammy_task:
jammy_test_artifacts:
path: "bazel-testlogs/**/test.xml"
format: junit
coverage_script:
- apt update && apt install -y lcov
- bazel coverage
--combined_report=lcov
--local_resources=ram=24000
--local_resources=cpu=8
--remote_cache=http://$CIRRUS_HTTP_CACHE_HOST
--remote_download_minimal
--strategy=CoverageReport=local
--experimental_fetch_all_coverage_outputs
//...
- genhtml --branch-coverage
--output coverage_report
"bazel-out/_coverage/_coverage_report.dat"
jammy_coverage_artifacts:
path: "coverage_report/**/*"
type: text/html

noble_task:
timeout_in: 120m
Expand Down Expand Up @@ -73,20 +56,3 @@ noble_task:
noble_test_artifacts:
path: "bazel-testlogs/**/test.xml"
format: junit
coverage_script:
- apt update && apt install -y lcov
- bazel coverage
--combined_report=lcov
--local_resources=ram=24000
--local_resources=cpu=8
--remote_cache=http://$CIRRUS_HTTP_CACHE_HOST
--remote_download_minimal
--strategy=CoverageReport=local
--experimental_fetch_all_coverage_outputs
//...
- genhtml --branch-coverage
--output coverage_report
"bazel-out/_coverage/_coverage_report.dat"
noble_coverage_artifacts:
path: "coverage_report/**/*"
type: text/html
51 changes: 51 additions & 0 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: C3 Coverage
on: [pull_request]
jobs:
# Only run coverage on Noble
coverage:
runs-on: ubuntu-latest
concurrency:
group: ci-${{ github.ref }}
cancel-in-progress: true
container:
image: ghcr.io/dairlab/docker-dair/noble-dair-base:v1.42
credentials:
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
options: --cpus 4
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Install required dependencies
run: apt update && apt install -y lcov
- name: Restore coverage cache
id: c3-cov-cache-restore
uses: actions/cache/restore@v4
with:
path: ~/.cache/bazel
key: c3-noble-bazel-cov-cache-${{ github.ref_name }}
restore-keys: |
c3-noble-bazel-cov-cache-
- name: Generate Coverage
run: bazel coverage
--combined_report=lcov
--local_resources=ram=24000
--local_resources=cpu=4
--jobs=4
//...
- name: Report code coverage
uses: zgosalvez/[email protected]
with:
coverage-files: bazel-out/_coverage/_coverage_report.dat
minimum-coverage: 90
artifact-name: noble-code-coverage-report
github-token: ${{ secrets.GITHUB_TOKEN }}
update-comment: true
- name: Save coverage cache
id: c3-cov-cache-save
if: always() && !cancelled() && steps.c3-cov-cache-restore.outputs.cache-hit != 'true'
uses: actions/cache/save@v4
with:
key: ${{ steps.c3-cov-cache-restore.outputs.cache-primary-key }}
path: ~/.cache/bazel
- run: echo "🍏 This job's status is ${{ job.status }}."
Loading