def test_multiple_arguments(self): self.verify( makemock.MockMethod("int", "DoThis", "(const char * str, string &)", "const"), "ON_CALL(*this, DoThis(_, _)).WillByDefault(Invoke([](const char * str, string & p1) " "{ return real->DoThis(str, p1); }));", )
def test_with_namespace(self): self.verify( makemock.MockMethod("int", "DoThis", "(const std::string &)", "const"), "ON_CALL(*this, DoThis(_)).WillByDefault(Invoke([](const std::string & p0) " "{ return real->DoThis(p0); }));", )
def test_without_arg_name(self): self.verify( makemock.MockMethod("int", "DoThis", "(int val)", "const"), "ON_CALL(*this, DoThis(_)).WillByDefault(Invoke([](int val) " "{ return real->DoThis(val); }));", )
def test_with_const_ref_arg(self): self.verify( makemock.MockMethod("int", "DoThis", "(const int &)", "const"), "ON_CALL(*this, DoThis(_)).WillByDefault(Invoke([](const int & p0) " "{ return real->DoThis(p0); }));", )
def test_simple_call(self): self.verify( makemock.MockMethod("int", "DoThis", "()", "const"), "ON_CALL(*this, DoThis()).WillByDefault(Invoke([]() " "{ return real->DoThis(); }));", )