Skip to content
Snippets Groups Projects
Commit 710701e1 authored by Ruben Heinrich's avatar Ruben Heinrich
Browse files

Altered tests to fit new functions

parent 1aeb2b57
No related branches found
No related tags found
4 merge requests!57 vtkdiff,!47 parameter,!37 process borehole heat exchanger,!2Basic import and export functionality
test_that("generate_as_node_func correctly generates as_node function from XML element", {
simple_xml_file <- system.file("extdata", "simple_case_1.xml", package = "r2ogs6")
......@@ -13,6 +10,6 @@ test_that("generate_as_node_func correctly generates as_node function from XML e
#
# children
generate_as_node_func(simple_xml_file, "b")
generate_as_node_func(simple_xml_file, "b", show_result = FALSE)
})
test_that("new_r2ogs6_parameter basic validation is working", {
expect_error(r2ogs6_parameter("my_param", "my_type", "my_value"))
expect_error(r2ogs6_parameter("my_param", c(0, 0), c(0, 0)))
expect_error(r2ogs6_parameter(c(0, 0), "my_type", c(0, 0)))
......
test_that("read_in_points correctly reads point tibble from file", {
xml_doc <- validate_read_in_xml(system.file("extdata", "cube_1x1x1.gml", package = "r2ogs6"))
point_tibble <- read_in_points(xml_doc)
expect_equal(length(point_tibble), 4)
expect_equal(length(point_tibble[[1]]), 8)
expect_setequal(names(point_tibble), c("x", "y", "z", "name"))
})
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment