114 #ifndef GMOCK_TEST_GMOCK_LINK_TEST_H_ 115 #define GMOCK_TEST_GMOCK_LINK_TEST_H_ 119 #if !GTEST_OS_WINDOWS_MOBILE 148 using testing::InvokeArgument;
168 using testing::SetArrayArgument;
180 #if !GTEST_OS_WINDOWS_MOBILE 184 #if GTEST_HAS_EXCEPTIONS 185 using testing::Throw;
236 int field()
const {
return field_; }
304 #if !GTEST_OS_WINDOWS_MOBILE 310 int saved_errno = errno;
316 #endif // !GTEST_OS_WINDOWS_MOBILE 406 #if GTEST_HAS_EXCEPTIONS 414 #endif // GTEST_HAS_EXCEPTIONS 422 # pragma warning(push) 423 # pragma warning(disable:4100) 428 ACTION(Return1) {
return 1; }
452 ACTION_P2(ReturnEqualsEitherOf, first, second) {
453 return arg0 == first || arg0 == second;
458 # pragma warning(pop) 466 .WillOnce(ReturnEqualsEitherOf(
"one",
"two"));
590 char arr[] = {
'a',
'b' };
669 #endif // GMOCK_TEST_GMOCK_LINK_TEST_H_ virtual void VoidFromIntRef(int &n)=0
PolymorphicMatcher< internal::TrulyMatcher< Predicate > > Truly(Predicate pred)
Definition: gmock-matchers.h:4116
PolymorphicMatcher< internal::StrEqualityMatcher< internal::string > > StrCaseNe(const internal::string &str)
Definition: gmock-matchers.h:3976
Mock()
Definition: gmock_link_test.h:207
virtual int & IntRefFromString(char *str)=0
virtual void VoidFromDouble(double n)=0
PolymorphicAction< internal::ReturnNullAction > ReturnNull()
Definition: gmock-actions.h:1066
PolymorphicMatcher< internal::EndsWithMatcher< internal::string > > EndsWith(const internal::string &suffix)
Definition: gmock-matchers.h:3998
virtual int IntFromString(char *str)=0
#define EXPECT_THROW(statement, expected_exception)
Definition: gtest.h:1843
virtual ~Interface()
Definition: gmock_link_test.h:193
internal::GtMatcher< Rhs > Gt(Rhs x)
Definition: gmock-matchers.h:3772
internal::ElementsAreArrayMatcher< typename ::std::iterator_traits< Iter >::value_type > ElementsAreArray(Iter first, Iter last)
Definition: gmock-matchers.h:3646
void VoidFromVoid()
Definition: gmock_link_test.h:226
PolymorphicAction< internal::AssignAction< T1, T2 > > Assign(T1 *ptr, T2 val)
Definition: gmock-actions.h:1147
PolymorphicMatcher< internal::StrEqualityMatcher< internal::string > > StrNe(const internal::string &str)
Definition: gmock-matchers.h:3962
PolymorphicMatcher< internal::MatchesRegexMatcher > ContainsRegex(const internal::RE *regex)
Definition: gmock-matchers.h:4016
virtual void VoidFromString(char *str)=0
internal::ResultOfMatcher< Callable > ResultOf(Callable callable, const ResultOfMatcher &matcher)
Definition: gmock-matchers.h:3939
static int StaticIntFromString(char *)
Definition: gmock_link_test.h:229
virtual void VoidFromFunc(void(*func)(char *str))=0
internal::GeMatcher< Rhs > Ge(Rhs x)
Definition: gmock-matchers.h:3766
internal::AnyOfResult2< M1, M2 >::type AnyOf(M1 m1, M2 m2)
Definition: gmock-generated-matchers.h:1085
#define ON_CALL(obj, call)
Definition: gmock-spec-builders.h:1841
#define ACTION(name)
Definition: gmock-generated-actions.h:1308
PolymorphicAction< internal::InvokeWithoutArgsAction< FunctionImpl > > InvokeWithoutArgs(FunctionImpl function_impl)
Definition: gmock-actions.h:1168
Definition: gmock_link_test.h:191
internal::FloatingEqMatcher< float > FloatEq(float rhs)
Definition: gmock-matchers.h:3843
internal::WithArgsAction< InnerAction, k1 > WithArgs(const InnerAction &action)
Definition: gmock-generated-actions.h:625
static bool StaticBoolFromString(const char *)
Definition: gmock_link_test.h:230
PolymorphicMatcher< internal::PropertyMatcher< Class, PropertyType > > Property(PropertyType(Class::*property)() const, const PropertyMatcher &matcher)
Definition: gmock-matchers.h:3913
PolymorphicMatcher< internal::StartsWithMatcher< internal::string > > StartsWith(const internal::string &prefix)
Definition: gmock-matchers.h:3991
internal::EqMatcher< T > Eq(T x)
Definition: gmock-matchers.h:3742
int field() const
Definition: gmock_link_test.h:236
internal::FloatingEqMatcher< float > NanSensitiveFloatEq(float rhs)
Definition: gmock-matchers.h:3849
PolymorphicMatcher< internal::MatchesRegexMatcher > MatchesRegex(const internal::RE *regex)
Definition: gmock-matchers.h:4005
PolymorphicAction< internal::SetErrnoAndReturnAction< T > > SetErrnoAndReturn(int errval, T result)
Definition: gmock-actions.h:1156
PolymorphicMatcher< internal::NotNullMatcher > NotNull()
Definition: gmock-matchers.h:3802
internal::WithArgsAction< InnerAction, k > WithArg(const InnerAction &action)
Definition: gmock-more-actions.h:146
internal::ReturnRefAction< R > ReturnRef(R &x)
Definition: gmock-actions.h:1077
PolymorphicMatcher< internal::StrEqualityMatcher< internal::string > > StrCaseEq(const internal::string &str)
Definition: gmock-matchers.h:3969
internal::ElementsAreMatcher< ::testing::tuple<> > ElementsAre()
Definition: gmock-generated-matchers.h:570
Definition: gmock_link_test.h:233
Definition: gmock_link_test.h:223
PolymorphicAction< internal::InvokeAction< FunctionImpl > > Invoke(FunctionImpl function_impl)
Definition: gmock-more-actions.h:114
std::mutex m
Definition: AlexaPresentationTest.cpp:91
internal::DoBothAction< Action1, Action2 > DoAll(Action1 a1, Action2 a2)
Definition: gmock-generated-actions.h:696
internal::LeMatcher< Rhs > Le(Rhs x)
Definition: gmock-matchers.h:3778
PolymorphicMatcher< internal::IsNullMatcher > IsNull()
Definition: gmock-matchers.h:3795
int field_
Definition: gmock_link_test.h:237
virtual void VoidFromVector(const std::vector< int > &v)=0
virtual char * StringFromString(char *str)=0
PolymorphicMatcher< internal::ContainerEqMatcher< GTEST_REMOVE_CONST_(Container)> > ContainerEq(const Container &rhs)
Definition: gmock-matchers.h:4150
internal::DoDefaultAction DoDefault()
Definition: gmock-actions.h:1099
internal::ReturnAction< R > Return(R value)
Definition: gmock-actions.h:1061
FieldHelper(int a_field)
Definition: gmock_link_test.h:235
#define EXPECT_CALL(obj, call)
Definition: gmock-spec-builders.h:1845
virtual void VoidFromFloat(float n)=0
static void StaticVoidFromString(char *)
Definition: gmock_link_test.h:227
Matcher< T > A()
Definition: gmock-matchers.h:3732
PolymorphicAction< internal::SetArgumentPointeeAction< N, T, internal::IsAProtocolMessage< T >::value > > SetArgPointee(const T &x)
Definition: gmock-actions.h:1109
static void StaticVoidFromVoid()
Definition: gmock_link_test.h:225
Matcher< Lhs > TypedEq(const Rhs &rhs)
Definition: gmock-matchers.h:3762
Matcher< T > MatcherCast(const M &matcher)
Definition: gmock-matchers.h:610
PolymorphicMatcher< internal::HasSubstrMatcher< internal::string > > HasSubstr(const internal::string &substring)
Definition: gmock-matchers.h:3984
#define GTEST_DISALLOW_COPY_AND_ASSIGN_(type)
Definition: gtest-port.h:874
const internal::AnythingMatcher _
Definition: gmock-matchers.h:3729
PolymorphicMatcher< internal::StrEqualityMatcher< internal::string > > StrEq(const internal::string &str)
Definition: gmock-matchers.h:3955
bool Matches(T x) const
Definition: gmock-matchers.h:261
#define EXPECT_TRUE(condition)
Definition: gtest.h:1859
#define MOCK_METHOD1(m,...)
Definition: gmock-generated-function-mockers.h:676
Definition: gmock-nice-strict_test.cc:41
def ret_value
Definition: android_test.py:113
internal::FloatingEqMatcher< double > DoubleEq(double rhs)
Definition: gmock-matchers.h:3815
Definition: gmock-matchers.h:319
#define ACTION_P(name, p0)
Definition: gmock-generated-actions.h:1353
internal::WithArgsAction< InnerAction > WithoutArgs(const InnerAction &action)
Definition: gmock-more-actions.h:135
internal::IgnoreResultAction< A > IgnoreResult(const A &an_action)
Definition: gmock-actions.h:1187
void VoidFromString(char *)
Definition: gmock_link_test.h:228
internal::PointeeMatcher< InnerMatcher > Pointee(const InnerMatcher &inner_matcher)
Definition: gmock-matchers.h:3872
PolymorphicMatcher< internal::FieldMatcher< Class, FieldType > > Field(FieldType Class::*field, const FieldMatcher &matcher)
Definition: gmock-matchers.h:3896
#define EXPECT_FALSE(condition)
Definition: gtest.h:1862
internal::NotMatcher< InnerMatcher > Not(InnerMatcher m)
Definition: gmock-matchers.h:4107
internal::LtMatcher< Rhs > Lt(Rhs x)
Definition: gmock-matchers.h:3784
internal::FloatingEqMatcher< double > NanSensitiveDoubleEq(double rhs)
Definition: gmock-matchers.h:3821
TEST(LinkTest, TestReturnVoid)
Definition: gmock_link_test.h:242
internal::RefMatcher< T & > Ref(T &x)
Definition: gmock-matchers.h:3809
#define ACTION_P2(name, p0, p1)
Definition: gmock-generated-actions.h:1403
internal::NeMatcher< Rhs > Ne(Rhs x)
Definition: gmock-matchers.h:3790
#define LinkTest
Definition: gmock_link2_test.cc:38
internal::AllOfResult2< M1, M2 >::type AllOf(M1 m1, M2 m2)
Definition: gmock-generated-matchers.h:1002