From 3439f7bc7c7294e4241752ead8920859d8b72c80 Mon Sep 17 00:00:00 2001 From: cebarboza Date: Fri, 18 Oct 2024 10:34:12 +0200 Subject: [PATCH] deprecated tests --- tests/testthat/deprecated_tests/README.html | 415 ++++++++++++++++++ tests/testthat/deprecated_tests/README.md | 7 + .../test-MainFunctions.R | 0 .../{ => deprecated_tests}/test-runExplore.R | 13 - tests/testthat/test-HelperFunctions.R | 15 + 5 files changed, 437 insertions(+), 13 deletions(-) create mode 100644 tests/testthat/deprecated_tests/README.html create mode 100644 tests/testthat/deprecated_tests/README.md rename tests/testthat/{ => deprecated_tests}/test-MainFunctions.R (100%) rename tests/testthat/{ => deprecated_tests}/test-runExplore.R (92%) diff --git a/tests/testthat/deprecated_tests/README.html b/tests/testthat/deprecated_tests/README.html new file mode 100644 index 0000000..c4af97d --- /dev/null +++ b/tests/testthat/deprecated_tests/README.html @@ -0,0 +1,415 @@ + + + + + + + + + + + + + +README + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + + + + + + +
+

test-MainFunctions.R

+
    +
  • Initial testing Explore. No longer compatible with new results +format.
  • +
+
+
+

test-runExplore.R

+
    +
  • Testing function later used in current tests.
  • +
+
+ + + + +
+ + + + + + + + + + + + + + + diff --git a/tests/testthat/deprecated_tests/README.md b/tests/testthat/deprecated_tests/README.md new file mode 100644 index 0000000..542767b --- /dev/null +++ b/tests/testthat/deprecated_tests/README.md @@ -0,0 +1,7 @@ +## test-MainFunctions.R + +* Initial testing Explore. No longer compatible with new results format. + +## test-runExplore.R + +* Testing function later used in current tests. \ No newline at end of file diff --git a/tests/testthat/test-MainFunctions.R b/tests/testthat/deprecated_tests/test-MainFunctions.R similarity index 100% rename from tests/testthat/test-MainFunctions.R rename to tests/testthat/deprecated_tests/test-MainFunctions.R diff --git a/tests/testthat/test-runExplore.R b/tests/testthat/deprecated_tests/test-runExplore.R similarity index 92% rename from tests/testthat/test-runExplore.R rename to tests/testthat/deprecated_tests/test-runExplore.R index a5f55f4..6be3656 100644 --- a/tests/testthat/test-runExplore.R +++ b/tests/testthat/deprecated_tests/test-runExplore.R @@ -104,17 +104,4 @@ test_that("Test EndRulelength 5", { }) -test_that("getDataSetPath list cases", { - - dataset <- "iris" - data_path <- getDataSetPath(dataset = dataset) - expect_equal(data_path$class_feature, "'class'") - - dataset <- "binary_3" - data_path <- getDataSetPath(dataset = dataset) - expect_equal(data_path$class_feature, "'outcomeCount'") - - dataset <- "mix_4_ordered" - expect_error(getDataSetPath(dataset = dataset)) -}) diff --git a/tests/testthat/test-HelperFunctions.R b/tests/testthat/test-HelperFunctions.R index 3d27d8d..ace861f 100644 --- a/tests/testthat/test-HelperFunctions.R +++ b/tests/testthat/test-HelperFunctions.R @@ -11,3 +11,18 @@ test_that("Convert logical to 0/1", { train_data <- convert_logical(train_data) expect_true(all(sapply(train_data, function(col) all(col %in% c(0, 1))))) }) + +test_that("getDataSetPath list cases", { + + dataset <- "iris" + data_path <- getDataSetPath(dataset = dataset) + expect_equal(data_path$class_feature, "'class'") + + dataset <- "binary_3" + data_path <- getDataSetPath(dataset = dataset) + expect_equal(data_path$class_feature, "'outcomeCount'") + + dataset <- "mix_4_ordered" + expect_error(getDataSetPath(dataset = dataset)) + +}) \ No newline at end of file