mockery

Mocking Library for R

The two main functionalities of this package are creating mock objects (functions) and selectively intercepting calls to a given function that originate in some other function. It can be used with any testing framework available for R. Mock objects can be injected with either this package's own stub() function or a similar with_mock() facility present in the 'testthat' package.

Tests Vignettes

Available Snapshots

This version of mockery can be found in the following snapshots:

Dependencies

Imports/Depends/LinkingTo/Enhances (1)
  • testthat
  • Suggests (3)
  • knitr
  • R6
  • rmarkdown >= 1.0
  • Version History