Test File 5 test-fm_load_data.R

Summary

  • Number of test(s) : 1

  • Number of expectation(s) : 42

  • Number of successful expectation(s) : 30

  • Number of failed expectation(s) : 0

  • Number of errored expectation(s) : 0

  • Number of expectations with warning(s) : 0

  • Number of validated skip expectation(s) : 0

  • Number of skipped expectation(s) : 12

Details

Test Description Expectation Result Location Test_time
fm_load_data works Testing the inputs of fm_load_data are correct expect_error(object = fm_load_data(fitted_data = “notagoodinput”), regexp = “‘arg’ should be one of .biomass., .presabs.”) Success test-fm_load_data.R#22 2023-04-13 12:24:14
fm_load_data works expect_error(object = fm_load_data(time_step = “notagoodinput”), regexp = “‘arg’ should be one of .Month., .Quarter.”) Success test-fm_load_data.R#24 2023-04-13 12:24:14
fm_load_data works NA (was skipped) # Update expected outputs here 🔄 Skipped test-fm_load_data.R#70 NA (was skipped)
fm_load_data works NA (was skipped) expect_true( 🔄 Skipped test-fm_load_data.R#94 NA (was skipped)
fm_load_data works NA (was skipped) expect_true( 🔄 Skipped test-fm_load_data.R#103 NA (was skipped)
fm_load_data works Testing the result of fm_load_data is a list expect_type(object = fm_data_inputs, “list”) Success test-fm_load_data.R#116 2023-04-13 12:24:27
fm_load_data works Testing names of the list return by fm_load_data expect_named( object = fm_data_inputs, expected = c( “species”, “b_com_i”, “mesh”, “time.step_df”, “loc_x”, “y_com_i”, “y_sci_i”, “cov_x_com”, “cov_x_sci”, “c_com_x”, “t_com_i”, “t_sci_i”, “spde”, “Aix_ij_com”, “Aix_w_com”, “Aix_ij_sci”, “Aix_w_sci”, “cov_x_pred”, “Aix_ij_pred”, “Aix_w_pred”, “W”, “n_survey”, “MeshList_aniso” ) ) Success test-fm_load_data.R#119 2023-04-13 12:24:27
fm_load_data works NA (was skipped) expected = c( 🔄 Skipped test-fm_load_data.R#121 NA (was skipped)
fm_load_data works Testing types inside the list returned by fm_load_data expect_type(fm_data_inputs[[“species”]], “character”) Success test-fm_load_data.R#149 2023-04-13 12:24:27
fm_load_data works Testing types inside the list returned by fm_load_data expect_type(fm_data_inputs[[“b_com_i”]], “double”) Success test-fm_load_data.R#150 2023-04-13 12:24:27
fm_load_data works expect_s3_class(fm_data_inputs[[“mesh”]], “inla.mesh”) Success test-fm_load_data.R#151 2023-04-13 12:24:27
fm_load_data works expect_s3_class(fm_data_inputs[[“time.step_df”]], “data.frame”) Success test-fm_load_data.R#152 2023-04-13 12:24:27
fm_load_data works expect_s3_class(fm_data_inputs[[“loc_x”]], “data.frame”) Success test-fm_load_data.R#153 2023-04-13 12:24:27
fm_load_data works expect_type(fm_data_inputs[[“y_com_i”]], “double”) Success test-fm_load_data.R#154 2023-04-13 12:24:27
fm_load_data works expect_type(fm_data_inputs[[“y_sci_i”]], “double”) Success test-fm_load_data.R#155 2023-04-13 12:24:27
fm_load_data works expect_true(is.matrix(fm_data_inputs[[“cov_x_com”]])) Success test-fm_load_data.R#156 2023-04-13 12:24:27
fm_load_data works expect_true(is.matrix(fm_data_inputs[[“cov_x_sci”]])) Success test-fm_load_data.R#157 2023-04-13 12:24:27
fm_load_data works expect_true(is.array(fm_data_inputs[[“c_com_x”]])) Success test-fm_load_data.R#158 2023-04-13 12:24:27
fm_load_data works expect_type(fm_data_inputs[[“t_com_i”]], “integer”) Success test-fm_load_data.R#159 2023-04-13 12:24:27
fm_load_data works expect_type(fm_data_inputs[[“t_sci_i”]], “integer”) Success test-fm_load_data.R#160 2023-04-13 12:24:27
fm_load_data works expect_type(fm_data_inputs[[“spde”]], “list”) Success test-fm_load_data.R#161 2023-04-13 12:24:27
fm_load_data works expect_true(is.matrix(fm_data_inputs[[“Aix_ij_com”]])) Success test-fm_load_data.R#162 2023-04-13 12:24:27
fm_load_data works expect_type(fm_data_inputs[[“Aix_w_com”]], “double”) Success test-fm_load_data.R#163 2023-04-13 12:24:27
fm_load_data works expect_true(is.matrix(fm_data_inputs[[“Aix_ij_sci”]])) Success test-fm_load_data.R#164 2023-04-13 12:24:27
fm_load_data works expect_type(fm_data_inputs[[“Aix_w_sci”]], “double”) Success test-fm_load_data.R#165 2023-04-13 12:24:27
fm_load_data works expect_true(is.matrix(fm_data_inputs[[“cov_x_pred”]])) Success test-fm_load_data.R#166 2023-04-13 12:24:27
fm_load_data works expect_true(is.matrix(fm_data_inputs[[“Aix_ij_pred”]])) Success test-fm_load_data.R#167 2023-04-13 12:24:27
fm_load_data works expect_type(fm_data_inputs[[“Aix_w_pred”]], “double”) Success test-fm_load_data.R#168 2023-04-13 12:24:27
fm_load_data works expect_type(fm_data_inputs[[“W”]], “double”) Success test-fm_load_data.R#169 2023-04-13 12:24:27
fm_load_data works expect_type(fm_data_inputs[[“n_survey”]], “double”) Success test-fm_load_data.R#170 2023-04-13 12:24:28
fm_load_data works expect_type(fm_data_inputs[[“MeshList_aniso”]], “list”) Success test-fm_load_data.R#171 2023-04-13 12:24:28
fm_load_data works Testing that tmpdir of the mesh exists expect_true(dir.exists(mesh_dir)) Success test-fm_load_data.R#178 2023-04-13 12:24:28
fm_load_data works Testing that tmpdir of the mesh exists expect_true(dir.exists(mesh_aniso_dir)) Success test-fm_load_data.R#179 2023-04-13 12:24:28
fm_load_data works NA (was skipped) expected_outputs <- readr::read_rds( 🔄 Skipped test-fm_load_data.R#184 NA (was skipped)
fm_load_data works NA (was skipped) expected_outputs <- readr::read_rds( 🔄 Skipped test-fm_load_data.R#191 NA (was skipped)
fm_load_data works NA (was skipped) expected_outputs$mesh$meta$prefix <- 🔄 Skipped test-fm_load_data.R#197 NA (was skipped)
fm_load_data works NA (was skipped) expected_outputs$MeshList_aniso$anisotropic_spde$mesh$meta$prefix <- 🔄 Skipped test-fm_load_data.R#199 NA (was skipped)
fm_load_data works NA (was skipped) resorted_expected <- resort_all(expected_outputs) 🔄 Skipped test-fm_load_data.R#217 NA (was skipped)
fm_load_data works NA (was skipped) attr(resorted_expected$loc_x$long, which = “names”) <- NULL 🔄 Skipped test-fm_load_data.R#222 NA (was skipped)
fm_load_data works NA (was skipped) attr(resorted_expected$loc_x$lati, which = “names”) <- NULL 🔄 Skipped test-fm_load_data.R#223 NA (was skipped)
fm_load_data works Testing that the result of fm_load_data is stable expect_equal(object = resorted_result, expected = resorted_expected) Success test-fm_load_data.R#226 2023-04-13 12:24:28
fm_load_data works NA (was skipped) expected = resorted_expected) 🔄 Skipped test-fm_load_data.R#227 NA (was skipped)