mirror of
https://github.com/msberends/AMR.git
synced 2024-12-26 20:46:12 +01:00
11 lines
389 B
R
11 lines
389 B
R
|
context("like.R")
|
||
|
|
||
|
test_that("`like` works", {
|
||
|
expect_true(suppressWarnings("test" %like% c("^t", "^s")))
|
||
|
expect_true("test" %like% "test")
|
||
|
expect_true("test" %like% "TEST")
|
||
|
expect_true(as.factor("test") %like% "TEST")
|
||
|
expect_identical(factor(c("Test case", "Something different", "Yet another thing")) %like% c("case", "diff", "yet"),
|
||
|
c(TRUE, TRUE, TRUE))
|
||
|
})
|