File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 88
99name : test-coverage
1010
11+ permissions : read-all
12+
1113jobs :
1214 test-coverage :
1315 runs-on : ubuntu-latest
@@ -23,23 +25,34 @@ jobs:
2325
2426 - uses : r-lib/actions/setup-r-dependencies@v2
2527 with :
26- extra-packages : any::covr
28+ extra-packages : any::covr, any::xml2
2729 needs : coverage
2830
2931 - name : Test coverage
3032 run : |
31- covr::codecov (
33+ cov <- covr::package_coverage (
3234 quiet = FALSE,
3335 clean = FALSE,
34- install_path = file.path(Sys.getenv("RUNNER_TEMP"), "package")
36+ install_path = file.path(normalizePath( Sys.getenv("RUNNER_TEMP"), winslash = "/ "), "package")
3537 )
38+ print(cov)
39+ covr::to_cobertura(cov)
3640 shell : Rscript {0}
3741
42+ - uses : codecov/codecov-action@v5
43+ with :
44+ # Fail if error if not on PR, or if on PR and token is given
45+ fail_ci_if_error : ${{ github.event_name != 'pull_request' || secrets.CODECOV_TOKEN }}
46+ files : ./cobertura.xml
47+ plugins : noop
48+ disable_search : true
49+ token : ${{ secrets.CODECOV_TOKEN }}
50+
3851 - name : Show testthat output
3952 if : always()
4053 run : |
4154 ## --------------------------------------------------------------------
42- find ${{ runner.temp }}/package -name 'testthat.Rout*' -exec cat '{}' \; || true
55+ find ' ${{ runner.temp }}/package' -name 'testthat.Rout*' -exec cat '{}' \; || true
4356 shell : bash
4457
4558 - name : Upload test results
Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ knitr::opts_chunk$set(
1919[ ![ DOI] ( https://zenodo.org/badge/DOI/10.5281/zenodo.7754457.svg )] ( https://doi.org/10.5281/zenodo.7754457 )
2020[ ![ R-CMD-check] ( https://github.com/GeoPressure/GeoPressureR/actions/workflows/R-CMD-check.yaml/badge.svg )] ( https://github.com/GeoPressure/GeoPressureR/actions/workflows/R-CMD-check.yaml )
2121[ ![ pkgdown] ( https://github.com/GeoPressure/GeoPressureR/actions/workflows/pkgdown.yaml/badge.svg )] ( https://github.com/GeoPressure/GeoPressureR/actions/workflows/pkgdown.yaml )
22- [ ![ Codecov test coverage] ( https://codecov.io/gh/GeoPressure/GeoPressureR/branch/main/ graph/badge.svg )] ( https://app.codecov.io/gh/GeoPressure/GeoPressureR?branch=main )
22+ [ ![ Codecov test coverage] ( https://codecov.io/gh/GeoPressure/GeoPressureR/graph/badge.svg )] ( https://app.codecov.io/gh/GeoPressure/GeoPressureR )
2323[ ![ lint] ( https://github.com/GeoPressure/GeoPressureR/actions/workflows/jarl-check.yml/badge.svg )] ( https://github.com/GeoPressure/GeoPressureR/actions/workflows/jarl-check.yml )
2424[ ![ format] ( https://github.com/GeoPressure/GeoPressureR/actions/workflows/format-check.yaml/badge.svg )] ( https://github.com/GeoPressure/GeoPressureR/actions/workflows/format-check.yaml )
2525[ ![ Lifecycle: stable] ( https://img.shields.io/badge/lifecycle-stable-brightgreen.svg )] ( https://lifecycle.r-lib.org/articles/stages.html#stable )
Original file line number Diff line number Diff line change 99[ ![ R-CMD-check] ( https://github.com/GeoPressure/GeoPressureR/actions/workflows/R-CMD-check.yaml/badge.svg )] ( https://github.com/GeoPressure/GeoPressureR/actions/workflows/R-CMD-check.yaml )
1010[ ![ pkgdown] ( https://github.com/GeoPressure/GeoPressureR/actions/workflows/pkgdown.yaml/badge.svg )] ( https://github.com/GeoPressure/GeoPressureR/actions/workflows/pkgdown.yaml )
1111[ ![ Codecov test
12- coverage] ( https://codecov.io/gh/GeoPressure/GeoPressureR/branch/main/ graph/badge.svg )] ( https://app.codecov.io/gh/GeoPressure/GeoPressureR?branch=main )
12+ coverage] ( https://codecov.io/gh/GeoPressure/GeoPressureR/graph/badge.svg )] ( https://app.codecov.io/gh/GeoPressure/GeoPressureR )
1313[ ![ lint] ( https://github.com/GeoPressure/GeoPressureR/actions/workflows/jarl-check.yml/badge.svg )] ( https://github.com/GeoPressure/GeoPressureR/actions/workflows/jarl-check.yml )
1414[ ![ format] ( https://github.com/GeoPressure/GeoPressureR/actions/workflows/format-check.yaml/badge.svg )] ( https://github.com/GeoPressure/GeoPressureR/actions/workflows/format-check.yaml )
1515[ ![ Lifecycle:
You can’t perform that action at this time.
0 commit comments