Skip to content

Commit e2f3773

Browse files
committed
fix live tests
1 parent dc07f4e commit e2f3773

2 files changed

Lines changed: 6 additions & 10 deletions

File tree

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

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -41,22 +41,18 @@ jobs:
4141
- name: Set up Pandoc
4242
uses: r-lib/actions/setup-pandoc@v2
4343

44-
- name: Install package dependencies
44+
- name: Install all package dependencies from DESCRIPTION
4545
uses: r-lib/actions/setup-r-dependencies@v2
4646
with:
47-
packages: |
48-
any::rJava
49-
any::devtools
50-
any::testthat
51-
any::withr
52-
any::cli
47+
# This installs Imports, Depends, LinkingTo, AND Suggests packages
48+
dependencies: "soft"
5349

5450
- name: Run live Java download and install tests
5551
# This is the key step:
5652
# 1. Set the environment variable to enable the test.
5753
# 2. Run ONLY the specific test file using devtools::test_file().
5854
env:
59-
RUN_JAVA_DOWNLOAD_TESTS: "true"
55+
RUN_JAVA_DOWNLOAD_TESTS: "TRUE"
6056
run: |
6157
devtools::test_file('tests/testthat/test-java_full-cycle-live.R')
6258
shell: Rscript {0}

tests/testthat/test-java_full-cycle-live.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ test_that("full download, install, check, and clear cycle works for all versions
44
testthat::skip_on_ci()
55
# Sys.setenv("RUN_JAVA_DOWNLOAD_TESTS" = "1")
66
skip_if_not(
7-
Sys.getenv("RUN_JAVA_DOWNLOAD_TESTS") == "1",
8-
"Skipping real download test. Set RUN_JAVA_DOWNLOAD_TESTS='1' to run."
7+
Sys.getenv("RUN_JAVA_DOWNLOAD_TESTS") == "TRUE",
8+
"Skipping real download test. Set RUN_JAVA_DOWNLOAD_TESTS='TRUE' to run."
99
)
1010

1111
# --- 1. Setup a Self-Cleaning Temporary Environment ---

0 commit comments

Comments
 (0)