Home | History | Annotate | Download | only in gmock

Lines Matching defs:Matcher

217 // Implements the Args() matcher.
227 typedef Matcher<const SelectedArgs&> MonomorphicInnerMatcher;
297 operator Matcher<ArgsTuple>() const {
316 operator Matcher<Container>() const {
327 const Matcher<const Element&> matcher =
329 return MakeMatcher(new ElementsAreMatcherImpl<Container>(&matcher, 1));
344 operator Matcher<Container>() const {
349 const Matcher<const Element&> matchers[] = {
371 operator Matcher<Container>() const {
376 const Matcher<const Element&> matchers[] = {
400 operator Matcher<Container>() const {
405 const Matcher<const Element&> matchers[] = {
431 operator Matcher<Container>() const {
436 const Matcher<const Element&> matchers[] = {
466 operator Matcher<Container>() const {
471 const Matcher
503 operator Matcher<Container>() const {
508 const Matcher<const Element&> matchers[] = {
542 operator Matcher<Container>() const {
547 const Matcher<const Element&> matchers[] = {
584 operator Matcher<Container>() const {
589 const Matcher<const Element&> matchers[] = {
628 operator Matcher<Container>() const {
633 const Matcher<const Element&> matchers[] = {
847 Args(const InnerMatcher& matcher) {
848 return internal::ArgsMatcher<InnerMatcher>(matcher);
853 Args(const InnerMatcher& matcher) {
854 return internal::ArgsMatcher<InnerMatcher, k1>(matcher);
859 Args(const InnerMatcher& matcher) {
860 return internal::ArgsMatcher<InnerMatcher, k1, k2>(matcher);
865 Args(const InnerMatcher& matcher) {
866 return internal::ArgsMatcher<InnerMatcher, k1, k2, k3>(matcher);
871 Args(const InnerMatcher& matcher) {
872 return internal::ArgsMatcher<InnerMatcher, k1, k2, k3, k4>(matcher);
877 Args(const InnerMatcher& matcher) {
878 return internal::ArgsMatcher<InnerMatcher, k1, k2, k3, k4, k5>(matcher);
883 Args(const InnerMatcher& matcher) {
884 return internal::ArgsMatcher<InnerMatcher, k1, k2, k3, k4, k5, k6>(matcher);
890 Args(const InnerMatcher& matcher) {
892 k7>(matcher);
898 Args(const InnerMatcher& matcher) {
900 k8>(matcher);
906 Args(const InnerMatcher& matcher) {
908 k9>(matcher);
915 Args(const InnerMatcher& matcher) {
917 k9, k10>(matcher);
923 // ElementsAre() can be either a value or a matcher. We support up to
1197 // The MATCHER* family of macros can be used in a namespace scope to
1205 // MATCHER(name, description_string) { statements; }
1207 // defines a matcher with the given name that executes the statements,
1212 // The description string documents what the matcher does, and is used
1214 // MATCHER() is usually defined in a header file shared by multiple
1217 // case we'll use the sequence of words in the matcher name as the
1222 // MATCHER(IsEven, "") { return (arg % 2) == 0; }
1241 // matcher name IsEven.
1247 // determined by the context in which you use the matcher and is
1249 // declaring it (nor can you). This allows the matcher to be
1259 // Sometimes you'll want to parameterize the matcher. For that you
1278 // Note that both the matcher description and its parameter are
1281 // In the matcher definition body, you can write 'foo_type' to
1292 // The last argument to MATCHER*() is a string-typed expression. The
1293 // expression can reference all of the matcher's parameters and a
1295 // false, the expression should evaluate to the matcher's description;
1297 // the matcher. For example,
1317 // contain the sequence of words in the matcher name followed by the
1331 // Types of Matcher Parameters
1349 // 'arg_type' as that's determined by the context in which the matcher
1354 // While you can instantiate a matcher template with reference types,
1358 // matcher you will see the value of the referenced object but not its
1364 // Sometimes the matcher description alone isn't enough to explain why
1391 // When defining a new matcher, you should also consider implementing
1393 // approaches require more work than the MATCHER* macros, but also
1395 // the matcher parameters, which may leads to better compiler error
1396 // messages when the matcher is used wrong. They also allow
1400 // MATCHER*() can only be used in a namespace scope. The reason is
1403 // Once that's done, we'll consider supporting using MATCHER*() inside
1409 // To learn more about using these macros, please search for 'MATCHER'
1412 #define MATCHER(name, description)\
1413 class name##Matcher {\
1441 operator ::testing::Matcher<arg_type>() const {\
1442 return ::testing::Matcher<arg_type>(\
1445 name##Matcher() {\
1448 GTEST_DISALLOW_ASSIGN_(name##Matcher);\
1450 inline name##Matcher name() {\
1451 return name##Matcher();\
1454 bool name##Matcher::gmock_Impl<arg_type>::MatchAndExplain(\
1490 operator ::testing::Matcher<arg_type>() const {\
1491 return ::testing::Matcher<arg_type>(\
1543 operator ::testing::Matcher<arg_type>() const {\
1544 return ::testing::Matcher<arg_type>(\
1602 operator ::testing::Matcher<arg_type>() const {\
1603 return ::testing::Matcher<arg_type>(\
1665 operator ::testing::Matcher<arg_type>() const {\
1666 return ::testing::Matcher<arg_type>(\
1736 operator ::testing::Matcher<arg_type>() const {\
1737 return ::testing::Matcher<arg_type>(\
1810 operator ::testing::Matcher<arg_type>() const {\
1811 return ::testing::Matcher<arg_type>(\
1889 operator ::testing::Matcher<arg_type>() const {\
1890 return ::testing::Matcher<arg_type>(\
1974 operator ::testing::Matcher<arg_type>() const {\
1975 return ::testing::Matcher<arg_type>(\
2065 operator ::testing::Matcher<arg_type>() const {\
2066 return ::testing::Matcher<arg_type>(\
2161 operator ::testing::Matcher<arg_type>() const {\
2162 return ::testing::Matcher<arg_type>(\