Commit 3a60152c authored by Dorchies David's avatar Dorchies David
Browse files

ci: add dontrun to examples running SIC

parent 7a1e65f6
No related merge requests found
Pipeline #33928 failed with stage
in 6 minutes and 3 seconds
This commit is part of merge request !6. Comments created here will be created in the context of that merge request.
Showing with 12 additions and 2 deletions
+12 -2
......@@ -7,8 +7,10 @@
#' @export
#'
#' @examples
#' \dontrun{
#' cfg <- cfg_tmp_project()
#' cfg$project$xml_path
#' }
#'
cfg_tmp_project <- function(xml_path = system.file("sic_project_test1.xml", package = "rsic2"), cfg = loadConfig(xml_path = xml_path)) {
cfg$project$path <- tempfile("sic_project", fileext = ".xml")
......
......@@ -9,9 +9,11 @@
#' @import magrittr
#'
#' @examples
#' \dontrun{
#' cfg <- cfg_tmp_project()
#' sic_run_fortran("fluvia", list(SCE = 1), cfg = cfg)
#' get_result(cfg, 1, filters = c("bf==4", "var=='Z'"))
#' }
get_result <- function(cfg,
scenario,
variant = 0,
......
......@@ -13,8 +13,9 @@
#' @examples
#' \dontrun{
#' # Run steady simulation for the scenario #1
#' cfg <- cfg_tmp_project()
#' params <- list(SCE=1)
#' sic_run_fortran("fluvia", params)
#' sic_run_fortran("fluvia", params, cfg = cfg)
#'}
sic_run_fortran <- function(prog, params = list(), cfg = loadConfig()) {
if (is.list(params)) params <- convert_sic_params(params, cfg)
......
......@@ -21,7 +21,9 @@ The updated configuration with the temporary project directory
Set a configuration with a temporary project directory
}
\examples{
\dontrun{
cfg <- cfg_tmp_project()
cfg$project$xml_path
}
}
......@@ -30,7 +30,9 @@ get_result(
Get a selection of variables from a simulation result
}
\examples{
\dontrun{
cfg <- cfg_tmp_project()
sic_run_fortran("fluvia", list(SCE = 1), cfg = cfg)
get_result(cfg, 1, filters = c("bf==4", "var=='Z'"))
}
}
......@@ -26,7 +26,8 @@ If argument \code{params} is a \link{list}, arguments are injected in the comman
\examples{
\dontrun{
# Run steady simulation for the scenario #1
cfg <- cfg_tmp_project()
params <- list(SCE=1)
sic_run_fortran("fluvia", params)
sic_run_fortran("fluvia", params, cfg = cfg)
}
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment