diff options
Diffstat (limited to 'pcrecpp_unittest.cc')
-rw-r--r-- | pcrecpp_unittest.cc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/pcrecpp_unittest.cc b/pcrecpp_unittest.cc index 858728c..bfe26e5 100644 --- a/pcrecpp_unittest.cc +++ b/pcrecpp_unittest.cc @@ -806,8 +806,11 @@ int main(int argc, char** argv) { /***** FullMatch with no args *****/ CHECK(RE("h.*o").FullMatch("hello")); - CHECK(!RE("h.*o").FullMatch("othello")); - CHECK(!RE("h.*o").FullMatch("hello!")); + CHECK(!RE("h.*o").FullMatch("othello")); // Must be anchored at front + CHECK(!RE("h.*o").FullMatch("hello!")); // Must be anchored at end + CHECK(RE("a*").FullMatch("aaaa")); // Fullmatch with normal op + CHECK(RE("a*?").FullMatch("aaaa")); // Fullmatch with nongreedy op + CHECK(RE("a*?\\z").FullMatch("aaaa")); // Two unusual ops /***** FullMatch with args *****/ |