mardi 26 mai 2015

Where to put external files for testthat tests

Suppose I have test like this:

require(testthat)
context("toy test")
test_that("toy", {
            df = my.read.file("test.txt", header=TRUE)
            expect_true(myfunc(df) == 3.14)
})

and this test relies on a external file test.txt, where should I put this file then?

Aucun commentaire:

Enregistrer un commentaire