Kun Yi | 68c8114 | 2018-12-18 11:17:14 -0800 | [diff] [blame^] | 1 | #pragma once |
| 2 | |
| 3 | #include "binarystore.hpp" |
| 4 | |
| 5 | #include <gmock/gmock.h> |
| 6 | |
| 7 | namespace binstore |
| 8 | { |
| 9 | |
| 10 | class MockBinaryStore : public BinaryStoreInterface |
| 11 | { |
| 12 | public: |
| 13 | MOCK_CONST_METHOD0(getBaseBlobId, std::string()); |
| 14 | MOCK_CONST_METHOD1(canHandleBlob, bool(const std::string&)); |
| 15 | MOCK_CONST_METHOD0(getBlobIds, std::vector<std::string>()); |
| 16 | MOCK_METHOD1(openOrCreateBlob, bool(const std::string&)); |
| 17 | MOCK_METHOD2(read, std::vector<uint8_t>(uint32_t, uint32_t)); |
| 18 | MOCK_METHOD2(write, bool(uint32_t, const std::vector<uint8_t>&)); |
| 19 | MOCK_METHOD0(commit, bool()); |
| 20 | MOCK_METHOD0(close, bool()); |
| 21 | MOCK_METHOD0(stat, bool()); |
| 22 | }; |
| 23 | |
| 24 | } // namespace binstore |