Skip to contents

Package overview

doctest doctest-package
Write testthat tests for your examples, using roxygen tags

Tags

doctest-tag @doctest
Start a doctest
doctestExample-tag @doctestExample
Add an example from a file
expect-tag @expect
Create an expectation
expectRaw-tag @expectRaw
Create an expectation as-is
omit-tag resume-tag @omit @resume
Exclude example code from a test
snap-tag @snap
Create a snapshot test
testRaw-tag @testRaw
Add a line of code to the test

Functions

dt_roclet()
Create the doctest roclet
test_doctests()
Test doctests in a package