How do I mock the following code?
class ISomeClass
{
public:
virtual ~ISomeClass() {} = 0;
virtual const MyType & getType() const = 0;
virtual MyType & getType() = 0;
};
I have tried the following, but it doesn´t work. Can you please help me?
class MockSomeClass : public ISomeClass
{
public:
using MyTypeConstRefType = const MyType&;
using MyTypeRefType = MyType&;
public:
MOCK_METHOD0(getType, MyTypeConstRefType(void) const);
MOCK_METHOD0(getType, MyTypeRefType(void));
};
MOCK_CONST_METHOD
– Eulogistic