(v0.6.1.9053) prerelease fixes

This commit is contained in:
dr. M.S. (Matthijs) Berends committed 2019-06-02 19:23:19 +02:00
1 parent 8de0495008
commit bd73988f15
38 files changed
+337 -327

No files matched your search

+7 -5
View File
@@ -247,11 +247,13 @@ test_that("as.mo works", {
# summary
expect_equal(length(summary(septic_patients$mo)), 6)
# other
expect_equal(as.character(as.mo(c("xxx", "con", "na", "nan"), debug = TRUE)),
rep(NA_character_, 4))
expect_equal(as.character(as.mo(c("other", "none", "unknown"))),
# WHONET codes and NA/NaN
expect_equal(as.character(as.mo(c("xxx", "na", "nan"), debug = TRUE)),
rep(NA_character_, 3))
expect_equal(as.character(as.mo("con")), "UNKNOWN")
expect_equal(as.character(as.mo("xxx")), NA_character_)
expect_equal(as.character(as.mo(c("xxx", "con"))), c(NA_character_, "UNKNOWN"))
expect_equal(as.character(as.mo(c("other", "none", "unknown"))),
rep("UNKNOWN", 3))
expect_null(mo_failures())