The goal of mockcpp is to package up a testthat integration of trompeloeil
Trompeloeil is...
A thread-safe header-only mocking framework for C++11/14 using the Boost Software License 1.0
usethis::use_testthat() # set up your package for testthat
testthat::use_catch() # set up your package to test C++ using catch and testthat
mockcpp
to your package:You should add it to your DESCRIPTION:
Remotes:
...
mrc-ide/mockcpp
Imports:
...
mockcpp
LinkingTo:
...
testthat,
mockcpp
You should add the following to your Makevars:
CXX_STD = CXX14
For basic examples, please refer to: vignettes/Examples.Rmd
or src/test-mocking.cpp
For more advanced examples please refer to the trompeloeil documentation
This R package is licenced under MIT but is mostly made of the Boost licensed trompeloeil library. (Full license at inst/LICENSE.bsl-1)
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.