Skip to content

Commit

Permalink
Added unit tests (#3)
Browse files Browse the repository at this point in the history
  • Loading branch information
wleoncio committed Feb 7, 2023
1 parent 3cfbe5b commit 5171a4f
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions tests/testthat/test-spatialMixture.R
Original file line number Diff line number Diff line change
Expand Up @@ -51,3 +51,11 @@ test_that("lakseKlitik() and subfunctions produce expected output", {
# TODO: ... and anythin left from findCliques.m
# TODO: test lakseKlitik()
})

test_that("testFastaData() produces same output as on MATLAB", {
msa <- system.file("ext", "seqs.fa", package = "rBAPS")
test_msa <- testFastaData(msa)
expect_equal(test_msa$ninds, 515)
expect_equal(dim(test_msa$data), c(515, 745))
expect_named(table(test_msa$data), c("-9", as.character(1:515)))
})

0 comments on commit 5171a4f

Please sign in to comment.