exmpextr: Extract an example from a unit test file.

View source: R/testing.R

exmpextrR Documentation

Extract an example from a unit test file.

Description

Extract an example from a unit test file.

Usage

exmpextr(test, testPath = NULL, examplePath = NULL)

Arguments

test

File name of the test file, source.

testPath

Path to test files. Defaults to "inst/tests".

examplePath

Path under which the example is stored. Defaults to "inst/examples".

Details

From test, an example is extracted and written to a file of the same name, but with removed "test-". The file is saved under examplePath. The special tag #-! can be used to hide code in the test which is enabled again in the example.

Author(s)

Wolfgang Mader, Wolfgang.Mader@fdm.uni-freiburg.de


dkaschek/dMod documentation built on April 23, 2024, 5:18 p.m.