mirror of
https://github.com/cpm-cmake/CPM.cmake.git
synced 2025-11-21 01:47:28 -05:00
19 lines
357 B
C++
19 lines
357 B
C++
|
|
#include <HEM/TestingFramework.hpp>
|
||
|
|
|
||
|
|
using namespace fakeit;
|
||
|
|
|
||
|
|
class ITest {
|
||
|
|
public:
|
||
|
|
virtual int getInt() = 0;
|
||
|
|
};
|
||
|
|
|
||
|
|
TEST_CASE("Testing Framework Test") {
|
||
|
|
constexpr int someIntValue = 123456;
|
||
|
|
|
||
|
|
Mock<ITest> testMock;
|
||
|
|
When(Method(testMock, getInt)).Return(someIntValue);
|
||
|
|
|
||
|
|
int readValue = testMock.get().getInt();
|
||
|
|
|
||
|
|
REQUIRE(readValue == someIntValue);
|
||
|
|
}
|