Skip to content

Commit

Permalink
How about this?
Browse files Browse the repository at this point in the history
  • Loading branch information
chainsawriot committed Jun 2, 2024
1 parent 17319f6 commit 7102903
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions tests/testthat/test_compress.R
Original file line number Diff line number Diff line change
Expand Up @@ -106,20 +106,21 @@ test_that("tar export error for R < 4.0.3", {

test_that("Wild zip and tar ref $425", {
skip_if(getRversion() <= "4.0")
skip_on_os("windows")
##skip_on_os("windows")
withr::with_tempfile("test_files", fileext = c(".csv", ".zip"), code = {
filename <- test_files[1]
zip_file <- test_files[2]
write.csv(1, filename)
zip(zip_file, filename)
expect_error(rio::import(zip_file), NA)
})
for (tar_format in c(".tar", ".tar.gz", ".tar.bz2")) {
for (tar_format in c(".tar")) {
withr::with_tempfile("test_files", fileext = c(".csv", tar_format), code = {
filename <- test_files[1]
tar_file <- test_files[2]
write.csv(1, filename)
tar(tar_file, filename)
compress_out(tar_file, filename, type = "tar")
#tar(tar_file, filename, compression = "none")
expect_error(rio::import(tar_file), NA)
})
}
Expand Down

0 comments on commit 7102903

Please sign in to comment.