# WARNING - Generated by {fusen} from dev/flat_scenario.Rmd: do not edit by hand # nolint: line_length_linter. library(tibble) test_that("update_frequency works", { scenario_example <- create_scenario( system.file("input_1culture_2pop.xlsx", package = "ambre") ) scenario_updated <- update_frequency(scenario_example) # check the value is updated expect_equal(object = scenario_updated$config[[1]]$exposure$value[[2]], expected = 60) # check the other values remain unchanged example_exposure_unchanged_values <- scenario_example$config[[1]]$exposure |> slice(-2) test_exposure_unchanged_values <- scenario_updated$config[[1]]$exposure |> slice(-2) expect_equal(object = test_exposure_unchanged_values, expected = example_exposure_unchanged_values) # check the type expect_true(is_tibble(scenario_updated$config[[1]]$exposure)) })