Skip to content

Commit

Permalink
skip file reads on CRAN to reduce checktime
Browse files Browse the repository at this point in the history
  • Loading branch information
Sebastian Kopf committed Oct 15, 2020
1 parent 58e8ec9 commit 4510776
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tests/testthat/test-continuous-flow.R
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ test_that("test that parameter checks are performed", {

test_that("test that dxf files can be read", {

# skip on CRAN to reduce checktime to below 10 minutes
skip_on_cran()

# check if tests are enabled
run_file_tests <- getOption("isoreader.run_file_tests")
if (!is.null(run_file_tests) && identical(run_file_tests, FALSE)) {
Expand Down
2 changes: 2 additions & 0 deletions tests/testthat/test-dual-inlet.R
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ test_that("test that nu file processor works properly", {

test_that("test that did files can be read", {

# skip on CRAN to reduce checktime to below 10 minutes
skip_on_cran()

# check if tests are enabled
run_file_tests <- getOption("isoreader.run_file_tests")
Expand Down
3 changes: 3 additions & 0 deletions tests/testthat/test-export.R
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
context("Export functions")

# skip on CRAN to reduce checktime to below 10 minutes
skip_on_cran()

di_example <- iso_read_dual_inlet(iso_get_reader_example("dual_inlet_example.did"))
cf_example <- iso_read_continuous_flow(iso_get_reader_example("continuous_flow_example.cf"))
cf_err_example <- suppressWarnings(iso_read_continuous_flow(system.file("errdata", "cf_without_data.dxf", package = "isoreader")))
Expand Down
9 changes: 9 additions & 0 deletions tests/testthat/test-isoread.R
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,9 @@ test_that("test that parameter checks are performed when reading file", {

test_that("test that cached file path hashes work okay", {

# skip on CRAN to reduce checktime to below 10 minutes
skip_on_cran()

data_folder <- "minimal_data" # data_folder <- file.path("tests", "testthat", "minimal_data") # for direct testing
origin_file <- get_isoreader_test_file("minimal_01.did", data_folder)

Expand Down Expand Up @@ -81,6 +84,9 @@ test_that("test that cached file path hashes work okay", {

test_that("test that version checking and re-reads are working properly", {

# skip on CRAN to reduce checktime to below 10 minutes
skip_on_cran()

# test folder
data_folder <- "minimal_data" # data_folder <- file.path("tests", "testthat", "minimal_data") # for direct testing
test_files <- c(
Expand Down Expand Up @@ -221,6 +227,9 @@ test_that("test that version checking and re-reads are working properly", {

test_that("test that file event expressions work", {

# skip on CRAN to reduce checktime to below 10 minutes
skip_on_cran()

data_folder <- file.path("minimal_data")
minimal_files <- c(
get_isoreader_test_file("minimal_01.did", local_folder = data_folder),
Expand Down
3 changes: 3 additions & 0 deletions tests/testthat/test-scan.R
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@ test_that("test that parameter checks are performed", {

test_that("test that scn files can be read", {

# skip on CRAN to reduce checktime to below 10 minutes
skip_on_cran()

# check if tests are enabled
run_file_tests <- getOption("isoreader.run_file_tests")
if (!is.null(run_file_tests) && identical(run_file_tests, FALSE)) {
Expand Down

0 comments on commit 4510776

Please sign in to comment.