Include tests in binary R package

☆樱花仙子☆ 提交于 2019-12-05 08:21:23

Ha! Got it. Found the information on the github page of testthat (it's at the very bottom). https://github.com/hadley/testthat

The advantage of this new structure is that the user has control over whether or not tests are installed using the --install-tests parameter to R CMD install, or INSTALL_opts = "--install-tests" argument to install.packages(). I'm not sure why you wouldn't want to install the tests, but now you have the option.

The command to build the binary package WITH the tests is

devtools::build(binary=TRUE,args=c("--preclean","--install-tests"))
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!