fileman_mock.h 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. #ifndef FILEMAN_MOCK_H
  2. #define FILEMAN_MOCK_H
  3. #include "../include/fileman.h"
  4. #include <gmock/gmock.h>
  5. class FileManMock : public FileMan {
  6. public:
  7. MOCK_METHOD(bool, isGetting, (), (override));
  8. MOCK_METHOD(bool, isPutting, (), (override));
  9. MOCK_METHOD(bool, isListing, (), (override));
  10. MOCK_METHOD(bool, isListingSimple, (), (override));
  11. MOCK_METHOD(bool, isListingExtended, (), (override));
  12. MOCK_METHOD(bool, openPut, (const std::string &path), (override));
  13. MOCK_METHOD(bool, openGet, (const std::string &path), (override));
  14. MOCK_METHOD(bool, openList, (bool extended), (override));
  15. MOCK_METHOD(void, closePut, (), (override));
  16. MOCK_METHOD(void, closeGet, (), (override));
  17. MOCK_METHOD(void, closeList, (), (override));
  18. MOCK_METHOD(std::string, getPutName, (), (override));
  19. MOCK_METHOD(std::string, getGetName, (), (override));
  20. MOCK_METHOD(void, cancelPut, (), (override));
  21. MOCK_METHOD(void, cancelGet, (), (override));
  22. MOCK_METHOD(void, cancelList, (), (override));
  23. MOCK_METHOD(std::vector<char>, readPut, (), (override));
  24. MOCK_METHOD(void, writeGet, (std::vector<char> data), (override));
  25. MOCK_METHOD(std::string, readBase64, (), (override));
  26. MOCK_METHOD(void, writeBase64, (std::string data), (override));
  27. MOCK_METHOD(void, putListData, (std::vector<Json::Value> names), (override));
  28. MOCK_METHOD(std::vector<Json::Value>, getListData, (), (override));
  29. MOCK_METHOD(int, getPutChunks, (), (override));
  30. MOCK_METHOD(int, getGetChunks, (), (override));
  31. MOCK_METHOD(int, getListChunks, (), (override));
  32. MOCK_METHOD(int, getPutRemainingChunks, (), (override));
  33. MOCK_METHOD(int, getGetRemainingChunks, (), (override));
  34. MOCK_METHOD(int, getListRemainingChunks, (), (override));
  35. MOCK_METHOD(int, getPutSize, (), (override));
  36. MOCK_METHOD(void, setGetChunks, (int chunks), (override));
  37. MOCK_METHOD(void, setListChunks, (int chunks), (override));
  38. MOCK_METHOD(std::string, pathToFilename, (std::string path), (override));
  39. MOCK_METHOD(std::string, getOpensslError, (), (override));
  40. MOCK_METHOD(bool, openKey, (const std::string &path), (override));
  41. MOCK_METHOD(bool, closeKey, (), (override));
  42. };
  43. #endif