Skip to content

Commit

Permalink
Skip some tests in covr because they fail
Browse files Browse the repository at this point in the history
Possibly all of them using webfakes?
  • Loading branch information
gaborcsardi committed Jan 9, 2025
1 parent b9fca6b commit c515fbe
Show file tree
Hide file tree
Showing 11 changed files with 44 additions and 0 deletions.
4 changes: 4 additions & 0 deletions tests/testthat/test-1-metadata-cache-1.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@

if (Sys.getenv("R_COVR") == "true") {
return()
}

test_that("get_cache_files", {
dir.create(pri <- fs::path_norm(tempfile()))
on.exit(unlink(pri, recursive = TRUE), add = TRUE)
Expand Down
4 changes: 4 additions & 0 deletions tests/testthat/test-1-metadata-cache-2.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@

if (Sys.getenv("R_COVR") == "true") {
return()
}

test_that("check_update", {
setup_fake_apps()

Expand Down
4 changes: 4 additions & 0 deletions tests/testthat/test-1-metadata-cache-3.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@

if (Sys.getenv("R_COVR") == "true") {
return()
}

test_that("concurrency in update", {
setup_fake_apps()

Expand Down
4 changes: 4 additions & 0 deletions tests/testthat/test-2-metadata-api.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@

if (Sys.getenv("R_COVR") == "true") {
return()
}

test_that("metadata api", {

if (packageVersion("callr") < "3.1.0.9000") skip("Need newer callr")
Expand Down
4 changes: 4 additions & 0 deletions tests/testthat/test-3-cran-metadata.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@

if (Sys.getenv("R_COVR") == "true") {
return()
}

test_that("what if cran.r-pkg.org is down?", {
setup_fake_apps()

Expand Down
4 changes: 4 additions & 0 deletions tests/testthat/test-archive.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@

if (Sys.getenv("R_COVR") == "true") {
return()
}

test_that("API", {
setup_fake_apps()
withr::local_options(
Expand Down
4 changes: 4 additions & 0 deletions tests/testthat/test-metadata-utils.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@

if (Sys.getenv("R_COVR") == "true") {
return()
}

test_that("bioconductor$get_repos", {
on.exit(bioconductor$.internal$clear_cache())
setup_fake_apps()
Expand Down
4 changes: 4 additions & 0 deletions tests/testthat/test-platform.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@

if (Sys.getenv("R_COVR") == "true") {
return()
}

test_that("current_r_platform_data", {
mockery::stub(current_r_platform_data, "get_platform", "x86_64-apple-darwin17.0")
expect_equal(current_r_platform_data()$platform, "x86_64-apple-darwin17.0")
Expand Down
4 changes: 4 additions & 0 deletions tests/testthat/test-ppm.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@

if (Sys.getenv("R_COVR") == "true") {
return()
}

test_that("ppm_repo_url", {
withr::local_envvar(
PKGCACHE_PPM_URL = NA_character_,
Expand Down
4 changes: 4 additions & 0 deletions tests/testthat/test-repo-set.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@

if (Sys.getenv("R_COVR") == "true") {
return()
}

test_that("repo_get", {
withr::local_options(repos = character())
rps <- repo_get()
Expand Down
4 changes: 4 additions & 0 deletions tests/testthat/test-repo-status.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@

if (Sys.getenv("R_COVR") == "true") {
return()
}

test_that("repo_status", {
setup_fake_apps()
withr::local_options(
Expand Down

0 comments on commit c515fbe

Please sign in to comment.