inst/tinytest/special/test-aaa1.R

# create fake packages in temporary directory:
from.dir <- file.path(getwd(), "fakelibs")
to.dir <- tempdir() |> normalizePath()
tinycodet:::.create_fake_packages(from.dir, to.dir)

expect_true(file.exists(file.path(to.dir, "fake_lib1")))
expect_true(file.exists(file.path(to.dir, "fake_lib2")))
expect_true(file.exists(file.path(to.dir, "fake_lib3")))
expect_true(file.exists(file.path(to.dir, "newlib")))

print(getwd())
expect_true(dir.exists("foo1"))
expect_true(dir.exists("foo2"))

Try the tinycodet package in your browser

Any scripts or data that you put into this service are public.

tinycodet documentation built on Sept. 12, 2024, 7:03 a.m.