Calling a method when expected method on mock was invoked
问题 I have the following scenario: class InterfaceA; class InterfaceB; class InterfaceC; class InterfaceA { virtual void foo(InterfaceC&) = 0; }; class InterfaceB { virtual void bar() = 0; }; class InterfaceC { virtual void bla() = 0; }; // MOCKs class MockA : public InterfaceA { public: MOCK_METHOD0(foo, void(InterfaceC&)); }; class MockB : public InterfaceB { public: MOCK_METHOD0(bar, void()); }; class ImplC : public InterfaceC { public: ImplC(InterfaceA& a, Interface& b) : m_a(a), m_b(b) {}