diff options
| author | Chris Sobczak <chris@sobczak.family> | 2026-07-10 16:31:33 -0700 |
|---|---|---|
| committer | Chris Sobczak <chris@sobczak.family> | 2026-07-10 16:31:33 -0700 |
| commit | 0478b9c425d668d6ef0aa0e860f8e4eac8ee78a0 (patch) | |
| tree | ac94fee58104a11e2158cfaaf61238a9cd0f2c78 /tests | |
| parent | 60cfc1ca0d2445b019f79ed92ed760377702e349 (diff) | |
get going and create test for simulate_data
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/testthat.R | 12 | ||||
| -rw-r--r-- | tests/testthat/test-simulate_data.R | 4 |
2 files changed, 16 insertions, 0 deletions
diff --git a/tests/testthat.R b/tests/testthat.R new file mode 100644 index 0000000..7b29596 --- /dev/null +++ b/tests/testthat.R @@ -0,0 +1,12 @@ +# This file is part of the standard setup for testthat. +# It is recommended that you do not modify it. +# +# Where should you do additional test configuration? +# Learn more about the roles of various files in: +# * https://r-pkgs.org/testing-design.html#sec-tests-files-overview +# * https://testthat.r-lib.org/articles/special-files.html + +library(testthat) +library(RSC.analysis) + +test_check("RSC.analysis") diff --git a/tests/testthat/test-simulate_data.R b/tests/testthat/test-simulate_data.R new file mode 100644 index 0000000..9d0cba3 --- /dev/null +++ b/tests/testthat/test-simulate_data.R @@ -0,0 +1,4 @@ +test_that("Returns a true sparse correlation matrix", { + X_obj <- simulate_data(n = 10, p = 10, rho = 0) + expect_equal(X_obj$S, diag(nrow = 10)) +}) |
