Novartis / xgxr

R package for supporting exploratory graphics at http://opensource.nibr.com/xgx
Other
13 stars 7 forks source link

testthat issue with vdiffr #36

Closed iamstein closed 3 years ago

iamstein commented 4 years ago

Hi @mattfidler, the testthat function you created for us is causing an error when we run devtools::check(). It's having a problem with vdiffr I think. Do you think we should just move this to Rdev for now so it doesn't break the package? -- I found this when implementing the error checking code you pointed out :)

Describe the bug E Running ‘testthat.R’ (6.1s) Running the tests in ‘tests/testthat.R’ failed. Last 13 lines of output:

  1. vdiffr::expect_doppelganger
  2. base::getExportedValue(pkg, name)
  3. base::asNamespace(ns)
  4. base::getNamespace(ns)
  5. base::loadNamespace(name)
  6. base::withRestarts(stop(cond), retry_loadNamespace = function() NULL)
  7. base:::withOneRestart(expr, restarts[[1L]])
  8. base:::doWithOneRestart(return(expr), restart)

To Reproduce

devtools::check()

or

vdiffr::expect_doppelganger Error in loadNamespace(name) : there is no package called ‘vdiffr’

Expected behavior No errors!

Package versions (please complete the following information):

Additional context Add any other context about the problem here.

mattfidler commented 4 years ago

You simply need to install vdiffr on DaVinci; It should work. It may say there are differences between the plots because I think I checked against the latest ggplot2.

I suppose you could skip the tests if vdiffr isn't present.

iamstein commented 4 years ago

Ok, I removed it for now, just to move toward a place where devtools:check() runs without errors. Will look into adding back in later when we get back into testing.