diff options
Diffstat (limited to 'googlemock/include/gmock/gmock-matchers.h')
-rw-r--r-- | googlemock/include/gmock/gmock-matchers.h | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/googlemock/include/gmock/gmock-matchers.h b/googlemock/include/gmock/gmock-matchers.h index fcf8cf2..7075082 100644 --- a/googlemock/include/gmock/gmock-matchers.h +++ b/googlemock/include/gmock/gmock-matchers.h @@ -361,7 +361,7 @@ template <size_t N> class TuplePrefix { public: // TuplePrefix<N>::Matches(matcher_tuple, value_tuple) returns true - // iff the first N fields of matcher_tuple matches the first N + // if the first N fields of matcher_tuple matches the first N // fields of value_tuple, respectively. template <typename MatcherTuple, typename ValueTuple> static bool Matches(const MatcherTuple& matcher_tuple, @@ -420,7 +420,7 @@ class TuplePrefix<0> { ::std::ostream* /* os */) {} }; -// TupleMatches(matcher_tuple, value_tuple) returns true iff all +// TupleMatches(matcher_tuple, value_tuple) returns true if all // matchers in matcher_tuple match the corresponding fields in // value_tuple. It is a compiler error if matcher_tuple and // value_tuple have different number of fields or incompatible field @@ -2534,7 +2534,7 @@ class KeyMatcherImpl : public MatcherInterface<PairType> { testing::SafeMatcherCast<const KeyType&>(inner_matcher)) { } - // Returns true iff 'key_value.first' (the key) matches the inner matcher. + // Returns true if 'key_value.first' (the key) matches the inner matcher. bool MatchAndExplain(PairType key_value, MatchResultListener* listener) const override { StringMatchResultListener inner_listener; @@ -2616,7 +2616,7 @@ class PairMatcherImpl : public MatcherInterface<PairType> { second_matcher_.DescribeNegationTo(os); } - // Returns true iff 'a_pair.first' matches first_matcher and 'a_pair.second' + // Returns true if 'a_pair.first' matches first_matcher and 'a_pair.second' // matches second_matcher. bool MatchAndExplain(PairType a_pair, MatchResultListener* listener) const override { @@ -3152,7 +3152,7 @@ class ElementsAreArrayMatcher { // Given a 2-tuple matcher tm of type Tuple2Matcher and a value second // of type Second, BoundSecondMatcher<Tuple2Matcher, Second>(tm, -// second) is a polymorphic matcher that matches a value x iff tm +// second) is a polymorphic matcher that matches a value x if tm // matches tuple (x, second). Useful for implementing // UnorderedPointwise() in terms of UnorderedElementsAreArray(). // @@ -3217,7 +3217,7 @@ class BoundSecondMatcher { // Given a 2-tuple matcher tm and a value second, // MatcherBindSecond(tm, second) returns a matcher that matches a -// value x iff tm matches tuple (x, second). Useful for implementing +// value x if tm matches tuple (x, second). Useful for implementing // UnorderedPointwise() in terms of UnorderedElementsAreArray(). template <typename Tuple2Matcher, typename Second> BoundSecondMatcher<Tuple2Matcher, Second> MatcherBindSecond( @@ -3710,7 +3710,7 @@ WhenDynamicCastTo(const Matcher<To>& inner_matcher) { // Creates a matcher that matches an object whose given field matches // 'matcher'. For example, // Field(&Foo::number, Ge(5)) -// matches a Foo object x iff x.number >= 5. +// matches a Foo object x if x.number >= 5. template <typename Class, typename FieldType, typename FieldMatcher> inline PolymorphicMatcher< internal::FieldMatcher<Class, FieldType> > Field( @@ -3737,7 +3737,7 @@ inline PolymorphicMatcher<internal::FieldMatcher<Class, FieldType> > Field( // Creates a matcher that matches an object whose given property // matches 'matcher'. For example, // Property(&Foo::str, StartsWith("hi")) -// matches a Foo object x iff x.str() starts with "hi". +// matches a Foo object x if x.str() starts with "hi". template <typename Class, typename PropertyType, typename PropertyMatcher> inline PolymorphicMatcher<internal::PropertyMatcher< Class, PropertyType, PropertyType (Class::*)() const> > @@ -3792,11 +3792,11 @@ Property(const std::string& property_name, property_name, property, MatcherCast<const PropertyType&>(matcher))); } -// Creates a matcher that matches an object iff the result of applying +// Creates a matcher that matches an object if the result of applying // a callable to x matches 'matcher'. // For example, // ResultOf(f, StartsWith("hi")) -// matches a Foo object x iff f(x) starts with "hi". +// matches a Foo object x if f(x) starts with "hi". // `callable` parameter can be a function, function pointer, or a functor. It is // required to keep no state affecting the results of the calls on it and make // no assumptions about how many calls will be made. Any state it keeps must be @@ -4345,7 +4345,7 @@ inline internal::MatcherAsPredicate<M> Matches(M matcher) { return internal::MatcherAsPredicate<M>(matcher); } -// Returns true iff the value matches the matcher. +// Returns true if the value matches the matcher. template <typename T, typename M> inline bool Value(const T& value, M matcher) { return testing::Matches(matcher)(value); @@ -4551,7 +4551,7 @@ PolymorphicMatcher<internal::variant_matcher::VariantMatcher<T> > VariantWith( // These macros allow using matchers to check values in Google Test // tests. ASSERT_THAT(value, matcher) and EXPECT_THAT(value, matcher) -// succeed iff the value matches the matcher. If the assertion fails, +// succeed if the value matches the matcher. If the assertion fails, // the value and the description of the matcher will be printed. #define ASSERT_THAT(value, matcher) ASSERT_PRED_FORMAT1(\ ::testing::internal::MakePredicateFormatterFromMatcher(matcher), value) |