Release prep for connectapi v0.9.0
#1216
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| branches: | |
| - main | |
| name: test-coverage | |
| jobs: | |
| test-coverage: | |
| runs-on: ubuntu-latest | |
| env: | |
| GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: r-lib/actions/setup-pandoc@v2 | |
| - uses: r-lib/actions/setup-r@v2 | |
| with: | |
| use-public-rspm: true | |
| - uses: r-lib/actions/setup-r-dependencies@v2 | |
| with: | |
| extra-packages: any::covr, local::. | |
| needs: coverage | |
| - name: Run coverage | |
| uses: nealrichardson/with-connect@dev | |
| env: | |
| CONNECTAPI_INTEGRATED: "true" | |
| with: | |
| # Runs on the default version in the with-connect action | |
| license: ${{ secrets.CONNECT_LICENSE_FILE }} | |
| # TODO: rewrite tests to use CONNECT_* env vars directly | |
| command: | | |
| Rscript -e ' | |
| Sys.setenv( | |
| TEST_1_SERVER=Sys.getenv("CONNECT_SERVER"), | |
| TEST_1_API_KEY=Sys.getenv("CONNECT_API_KEY") | |
| ) | |
| token <- "${{ secrets.CODECOV_TOKEN }}" | |
| covr::codecov( | |
| quiet = FALSE, | |
| clean = FALSE, | |
| install_path = file.path(normalizePath(Sys.getenv("RUNNER_TEMP"), winslash = "/"), "package"), | |
| token = if (token != "") token | |
| )' | |
| - name: Show testthat output | |
| if: always() | |
| run: | | |
| ## -------------------------------------------------------------------- | |
| find '${{ runner.temp }}/package' -name 'testthat.Rout*' -exec cat '{}' \; || true | |
| shell: bash | |
| - name: Upload test results | |
| if: failure() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: coverage-test-failures | |
| path: ${{ runner.temp }}/package |