diff --git a/R/inflate.R b/R/inflate.R index c8fc9715..800776bc 100644 --- a/R/inflate.R +++ b/R/inflate.R @@ -183,10 +183,10 @@ inflate <- function(pkg = ".", flat_file, } # Create NAMESPACE - namespace_file <- file.path(pkg, "NAMESPACE") - if (!file.exists(namespace_file)) { - roxygen2::roxygenise(pkg) - } + # namespace_file <- file.path(pkg, "NAMESPACE") + # if (!file.exists(namespace_file)) { + # roxygen2::roxygenise(pkg) + # } parsed_flat_file <- parse_rmd(flat_file) parsed_tbl <- as_tibble(parsed_flat_file) diff --git a/dev/flat_check_n_covr.Rmd b/dev/flat_check_n_covr.Rmd new file mode 100644 index 00000000..13e53360 --- /dev/null +++ b/dev/flat_check_n_covr.Rmd @@ -0,0 +1,49 @@ +--- +title: "flat_check_n_covr.Rmd empty" +output: html_document +editor_options: + chunk_output_type: console +--- + +```{r development, include=FALSE} +library(testthat) +``` + +```{r development-load} +# Load already included functions if relevant +pkgload::load_all(export_all = FALSE) +``` + +# My function + +```{r function-check_n_covr} +#' check_n_covr Title +#' +#' @return 1 +#' @export +#' +#' @examples +check_n_covr <- function() { + res <- devtools::check(args = c("--no-tests")) + print(res) + covr::package_coverage(type = "tests", quiet = TRUE) +} +``` + +```{r examples-check_n_covr} +check_n_covr() +``` + +```{r tests-check_n_covr} +test_that("check_n_covr works", { + +}) +``` + + +```{r development-inflate, eval=FALSE} +# Run but keep eval=FALSE to avoid infinite loop +# Execute in the console directly +fusen::inflate(flat_file = "dev/flat_check_n_covr.Rmd", vignette_name = "Go further") +``` +