We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 240561e + 36d76f1 commit 6606bc2Copy full SHA for 6606bc2
tests/testthat/test-csv.R
@@ -84,8 +84,12 @@ test_that("read_cmdstan_csv() fails if the file does not exist", {
84
test_that("read_cmdstan_csv() fails with empty csv file", {
85
file_path <- test_path("resources", "csv", "empty.csv")
86
file.create(file_path)
87
- expect_error(read_cmdstan_csv(file_path),
88
- "Supplied CSV file is corrupt!")
+ error_msg <- if (utils::packageVersion("data.table") >= "1.18.0") {
+ "External command failed"
89
+ } else {
90
+ "Supplied CSV file is corrupt"
91
+ }
92
+ expect_error(read_cmdstan_csv(file_path), error_msg, fixed = TRUE)
93
file.remove(file_path)
94
})
95
0 commit comments