Skip to content

Commit 1cf306c

Browse files
committed
just use r cmd template for live tests with special env var
1 parent 33ecbc5 commit 1cf306c

File tree

1 file changed

+26
-23
lines changed

1 file changed

+26
-23
lines changed

.github/workflows/java-live-tests.yml

Lines changed: 26 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -14,40 +14,43 @@ on:
1414
# and 2:00 AM (CEST, UTC+2) during daylight saving time.
1515
- cron: '0 0 * * 6'
1616

17+
1718
jobs:
18-
run-live-tests:
19-
name: ${{ matrix.config.os }} (R ${{ matrix.config.r-version }})
19+
R-CMD-check:
2020
runs-on: ${{ matrix.config.os }}
2121

22+
name: ${{ matrix.config.os }} (${{ matrix.config.r }})
23+
2224
strategy:
2325
fail-fast: false
2426
matrix:
2527
config:
26-
- {os: windows-latest, r-version: 'release'}
27-
- {os: macos-latest, r-version: 'release'}
28-
- {os: ubuntu-latest, r-version: 'release'}
28+
- {os: macos-latest, r: 'release'}
29+
- {os: windows-latest, r: 'release'}
30+
- {os: ubuntu-latest, r: 'release'}
31+
32+
env:
33+
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
34+
R_KEEP_PKG_SOURCE: yes
35+
RUN_JAVA_DOWNLOAD_TESTS: "true"
2936

3037
steps:
31-
- name: Check out repository
32-
uses: actions/checkout@v4
38+
- uses: actions/checkout@v4
39+
40+
- uses: r-lib/actions/setup-pandoc@v2
3341

34-
- name: Set up R
35-
uses: r-lib/actions/setup-r@v2
42+
- uses: r-lib/actions/setup-r@v2
3643
with:
37-
r-version: ${{ matrix.config.r-version }}
44+
r-version: ${{ matrix.config.r }}
45+
http-user-agent: ${{ matrix.config.http-user-agent }}
3846
use-public-rspm: true
3947

40-
- name: Set up Pandoc
41-
uses: r-lib/actions/setup-pandoc@v2
42-
43-
- name: Install package dependencies
44-
uses: r-lib/actions/setup-r-dependencies@v2
48+
- uses: r-lib/actions/setup-r-dependencies@v2
49+
with:
50+
extra-packages: any::rcmdcheck
51+
needs: check
4552

46-
- name: Run live Java download and install tests
47-
env:
48-
# This environment variable enables the specific test to run
49-
RUN_JAVA_DOWNLOAD_TESTS: "true"
50-
run: |
51-
# Use testthat::test_file() directly to avoid the devtools deprecation warning
52-
testthat::test_file('tests/testthat/test-java_full-cycle-live.R')
53-
shell: Rscript {0}
53+
- uses: r-lib/actions/check-r-package@v2
54+
with:
55+
upload-snapshots: true
56+
build_args: 'c("--no-manual","--compact-vignettes=gs+qpdf")'

0 commit comments

Comments
 (0)