Description Usage Arguments Details Examples
This function corresponds to an intentionally masks devtools::test()
from the devtools
package.
This version is polymorphic depending on the number of arguments given.
1 2 3 4 5 6 7 8 9 10 |
... |
polymorphic arguments |
pkg |
The package to test. |
filter |
An optional filter to restrict the files to extract from and run tests for. |
file |
for |
When no arguments are provided all tests are extracted and run from
the package corresponding to the active working directory.
In other words test()
is equivalent to test(pkg='.', filter=NULL)
If arguments are provided they may be named. If any argument is named all must be named, if not found the two key parameters will be taken to be
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | ## Not run:
# Extract and run all tests for the package in the
# current working directory.
test()
# One argument form
# extract and test class files for the
# package in the current working directory.
test("^Class-")
# Two argument form
# Extract files matching "Class" in the filename
# for the package located at "inst/textExtractionTest"
test("inst/testExtractionTest", "Class")
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.