patternapply

Iteratively try patterns against a character vector.
git clone https://git.eamoncaddigan.net/patternapply.git
Log | Files | Refs | README | LICENSE

commit 5771eddbf0a67af7fc93e7a6da3e64ab0b18308a
parent 05ecf617127db02bd9d3ecfc886b7f7239a95956
Author: eamoncaddigan <eamon.caddigan@gmail.com>
Date:   Fri, 26 Feb 2016 21:38:13 -0500

Better expect()

Diffstat:
Mtests/testthat/test_patternapply.R | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/testthat/test_patternapply.R b/tests/testthat/test_patternapply.R @@ -10,7 +10,7 @@ attributes(patternapplyResultVector) <- NULL test_that("Simple call returned correct results", { expect_equal(patternapplyResultVector, as.list(c(letters[1:9], 10:26))) - expect_equal(class(patternapplyResult), "replacement_list") + expect_is(patternapplyResult, "replacement_list") expect_equal(attr(patternapplyResult, "col_names"), "match_1") expect_equal(attr(patternapplyResult, "match_index"), c(rep(2, 9), rep(1, 26-9)))