Home | History | Annotate | Download | only in testing

Lines Matching refs:re

344   RE2 re("((\\w+):([0-9]+))");   // extracts host and port
349 CHECK(!re.Match(s, 0, s.size(), RE2::UNANCHORED,
354 CHECK(re.Match(s, 0, s.size(), RE2::UNANCHORED,
363 CHECK(RE2::PartialMatch("a chrisr:9000 here", re, &all, &host, &port));
378 RE2 re("([a-zA-Z0-9]|-)+(\\.([a-zA-Z0-9]|-)+)*(\\.)?", RE2::Quiet);
379 RE2::FullMatch(domain, re);
387 RE2 re(quoted, options);
388 EXPECT_TRUE_M(RE2::FullMatch(unquoted, re),
397 RE2 re(quoted, options);
398 EXPECT_FALSE_M(RE2::FullMatch(should_not_match, re),
489 RE2 re("(hello world)");
490 CHECK_EQ(re.NumberOfCapturingGroups(), 1);
491 const map<string, int>& m = re.NamedCapturingGroups();
496 RE2 re("(?P<A>expr(?P<B>expr)(?P<C>expr))((expr)(?P<D>expr))");
497 CHECK_EQ(re.NumberOfCapturingGroups(), 6);
498 const map<string, int>& m = re.NamedCapturingGroups();
974 const RE2 re(kPattern);
975 CHECK_EQ(kPattern, re.pattern());
980 RE2 re("foo");
981 CHECK(re.error().empty()); // Must have no error
982 CHECK(re.ok());
983 CHECK(re.error_code() == RE2::NoError);
1058 { RE2 re("a\\1", RE2::Quiet); CHECK(!re.ok()); }
1060 RE2 re("a[x", RE2::Quiet);
1061 CHECK(!re.ok());
1064 RE2 re("a[z-a]", RE2::Quiet);
1065 CHECK(!re.ok());
1068 RE2 re("a[[:foobar:]]", RE2::Quiet);
1069 CHECK(!re.ok());
1072 RE2 re("a(b", RE2::Quiet);
1073 CHECK(!re.ok());
1076 RE2 re("a\\", RE2::Quiet);
1077 CHECK(!re.ok());
1084 RE2 re("a\\", RE2::Quiet);
1085 CHECK(!re.ok());
1086 CHECK(!RE2::PartialMatch("a\\b", re));
1091 RE2 re("(((.{100}){100}){100}){100}", RE2::Quiet);
1092 CHECK(!re.ok());
1093 CHECK(!RE2::PartialMatch("aaa", re));
1098 RE2 re(".{512}x", RE2::Quiet);
1099 CHECK(re.ok());
1103 CHECK(RE2::PartialMatch(s, re));
1123 RE2 re(".{512}x", opt);
1124 CHECK(re.ok());
1128 CHECK(RE2::PartialMatch(s, re));
1140 RE2 re("((?:\\s|xx.*\n|x[*](?:\n|.)*?[*]x)*)");
1141 CHECK(RE2::FullMatch(comment, re));
1213 RE2 re(error_tests[i].regexp, RE2::Quiet);
1214 EXPECT_FALSE(re.ok());
1215 EXPECT_EQ(re.error_arg(), error_tests[i].error) << re.error();
1236 RE2 re(t.regexp, opt);
1238 EXPECT_FALSE(re.PartialMatch(t.text, re));
1241 EXPECT_TRUE(re.PartialMatch(t.text, re, &m));
1251 RE2 re("(r)(e)", opt);
1252 EXPECT_EQ(0, re.NumberOfCapturingGroups());
1262 RE2 re("(_________$)", opt);
1264 EXPECT_FALSE(re.Match(s, 0, s.size(), RE2::UNANCHORED, NULL, 0));
1337 RE2 re("(((((llx((-3)|(4)))(;(llx((-3)|(4))))*))))");
1340 EXPECT_TRUE(RE2::Consume(&piece, re, &x));
1345 RE2 re("(?i)\\W");
1346 EXPECT_FALSE(RE2::PartialMatch("x", re)); // always worked
1347 EXPECT_FALSE(RE2::PartialMatch("k", re)); // broke because of kelvin
1348 EXPECT_FALSE(RE2::PartialMatch("s", re)); // broke because of latin long s
1354 RE2 re("((abc)(?P<G2>)|((e+)(?P<G2>.*)(?P<G1>u+)))");
1355 EXPECT_TRUE(re.ok());
1356 const map<int, string>& have = re.CapturingGroupNames();