[R-pkg-devel] Check package without suggests

Serguei Sokol @ergue|@@oko| @end|ng |rom gm@||@com
Tue Jul 18 16:58:37 CEST 2023


Is it possible that you have complicated the task unnecessarily?
Normally, you can just do

if (requireNamespace("<suggested_pkg>", quietly=TRUE)) {
  # do the tests involving <suggested_pkg>
}

Wasn't that enough?

Best,
Serguei.


Le 18/07/2023 à 16:37, John Harrold a écrit :
> Howdy Folks,
> 
> I recent had a package start failing because I wasn't checking properly in
> my tests to make sure my suggested packages were installed before running
> tests. I think this is something new running on CRAN where packages are
> tested with only the packages specified as Imports in the DESCRIPTION file
> are installed. It took me a bit of back and forth to get all of these
> issues worked out.  I was wondering if anyone has a good way to run R CMD
> check with only the imports installed?  A github action, or a
> specific platform on rhub?
> 
> Thank you,
> 
> John
> :wq
> 
> 	[[alternative HTML version deleted]]
> 
> ______________________________________________
> R-package-devel using r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-package-devel



More information about the R-package-devel mailing list