Extract an example from a unit test file.
exmpextr(test, testPath = NULL, examplePath = NULL)
File name of the test file, source.
Path to test files. Defaults to "inst/tests".
Path under which the example is stored. Defaults to "inst/examples".
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.