Movatterモバイル変換


[0]ホーム

URL:


R build status

roxytest

Inline tests withroxygen2usingtestthatortinytest.In addition, there are a few roclets that aim at catching commondocumentation issues during the development cycle.

See demo package using this atroxytestdemo.

Install

To build and install from Github run this command from withinR:

remotes::install_github("mikldk/roxytest",                         build_opts = c("--no-resave-data", "--no-manual"))

You can also install the package without vignettes if needed asfollows:

remotes::install_github("mikldk/roxytest")

Documentation

Please refer to thisREADME as well as the includedmanual pages as well as the vignette, all also available online athttps://mikldk.github.io/roxytest/.

Usage

There are a number of roclets included:

Please refer to the “Introduction”vignette for details on these.

To use the package in your own package you do not need to add anyadditional dependencies in your package’sDESCRIPTION file.Simply add the following lines to your package’sDESCRIPTION file (or any other of the roclets mentionedabove):

Roxygen: list(roclets = c("namespace", "rd", "roxytest::testthat_roclet"))

Notes

Document package keyboardshortcut

In RStudio,CTRL+SHIFT+D/CMD+SHIFT+D optiondoes not rundevtools::document() but onlydevtools::document(roclets=c('rd', 'collate', 'namespace'))(possibly with fewer depending on the project options, but notnone).

Instead, you can usedevtoolsdocument()addin (seee.g. Rstudiodocumentation), and override the keyboard shortcut.


[8]ページ先頭

©2009-2025 Movatter.jp