diff --git a/DESCRIPTION b/DESCRIPTION index cb35d08..390309f 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -34,7 +34,8 @@ Suggests: testthat(>= 0.9), covr, withr, - mockery + mockery, + testthis LazyData: true LazyLoad: true VignetteBuilder: knitr diff --git a/cran-comments.md b/cran-comments.md new file mode 100644 index 0000000..59c0232 --- /dev/null +++ b/cran-comments.md @@ -0,0 +1,17 @@ +## Test environments + +* local Windows install, R-3.4.3 +* ubuntu trusty 14.04 (on travis-ci), testing on: + - R-release + - R-oldrel + - R-devel +* XCode (Mac OS) (on travis-ci) + +## R CMD check results + +There were no ERRORs or WARNINGs or NOTEs. + + +## Downstream dependencies + +`miniCRAN` has only one reverse dependency, `AzureML`, and all tests pass \ No newline at end of file diff --git a/tests/testthat/test-6-getCranDescription.R b/tests/testthat/test-6-getCranDescription.R index 3dd0bc2..530da6c 100644 --- a/tests/testthat/test-6-getCranDescription.R +++ b/tests/testthat/test-6-getCranDescription.R @@ -1,4 +1,4 @@ -if (interactive()) library(testthat) +if (interactive()) {library(testthat); library(testthis)} context("get CRAN description") test_that("can read CRAN description", { @@ -6,7 +6,7 @@ test_that("can read CRAN description", { skip_on_cran() mockery::stub(getCranDescription, what = "tools::CRAN_package_db", - function(...) readRDS("mock_data/pdb.rds") + function(...) testthis::read_testdata("/pdb.rds") ) p <- getCranDescription("miniCRAN", repos = c(CRAN = getOption("minicran.mran"))) expect_is(p, "data.frame") diff --git a/tests/testthat/mock_data/pdb.rds b/tests/testthat/testdata/pdb.rds similarity index 100% rename from tests/testthat/mock_data/pdb.rds rename to tests/testthat/testdata/pdb.rds