template <typename StringType>

class HasSubstrMatcher

Defined at line 978 of file ../../third_party/googletest/src/googlemock/include/gmock/gmock-matchers.h

Implements the polymorphic HasSubstr(substring) matcher, which

can be used as a Matcher

<T

> as long as T can be converted to a

string.

Public Methods

void HasSubstrMatcher<StringType> (const StringType & substring)

Defined at line 980 of file ../../third_party/googletest/src/googlemock/include/gmock/gmock-matchers.h

bool MatchAndExplain (const internal::StringView & s, MatchResultListener * listener)

Defined at line 984 of file ../../third_party/googletest/src/googlemock/include/gmock/gmock-matchers.h

template <typename CharType>
bool MatchAndExplain (CharType * s, MatchResultListener * listener)

Accepts pointer types, particularly:

const char*

char*

const wchar_t*

wchar_t*

Defined at line 999 of file ../../third_party/googletest/src/googlemock/include/gmock/gmock-matchers.h

template <typename MatcheeStringType>
bool MatchAndExplain (const MatcheeStringType & s, MatchResultListener * )

Matches anything that can convert to StringType.

This is a template, not just a plain function with const StringType

&

,

because StringView has some interfering non-explicit constructors.

Defined at line 1008 of file ../../third_party/googletest/src/googlemock/include/gmock/gmock-matchers.h

void DescribeTo (::std::ostream * os)

Describes what this matcher matches.

Defined at line 1014 of file ../../third_party/googletest/src/googlemock/include/gmock/gmock-matchers.h

void DescribeNegationTo (::std::ostream * os)

Defined at line 1019 of file ../../third_party/googletest/src/googlemock/include/gmock/gmock-matchers.h