Integrate DataQuery

Change-Id: I439374afe485baf08a4d5a1a02fd70d908bec9e1
diff --git a/tests/datastoreaccess_mock.hpp b/tests/datastoreaccess_mock.hpp
new file mode 100644
index 0000000..289d919
--- /dev/null
+++ b/tests/datastoreaccess_mock.hpp
@@ -0,0 +1,40 @@
+/*
+ * Copyright (C) 2020 CESNET, https://photonics.cesnet.cz/
+ *
+ * Written by Václav Kubernát <kubernat@cesnet.cz>
+ *
+*/
+
+#include <map>
+#include "datastore_access.hpp"
+#include "trompeloeil_doctest.h"
+#include "utils.hpp"
+
+namespace trompeloeil {
+    template <>
+    inline void print(std::ostream& os, const leaf_data_& data)
+    {
+        os << leafDataToString(data);
+    }
+}
+
+class MockDatastoreAccess : public trompeloeil::mock_interface<DatastoreAccess> {
+    IMPLEMENT_MOCK1(getItems);
+    IMPLEMENT_MOCK2(setLeaf);
+    IMPLEMENT_MOCK1(createPresenceContainer);
+    IMPLEMENT_MOCK1(deletePresenceContainer);
+    IMPLEMENT_MOCK1(createListInstance);
+    IMPLEMENT_MOCK1(deleteListInstance);
+    IMPLEMENT_MOCK2(executeRpc);
+
+    // Can't use IMPLEMENT_MOCK for private methods - IMPLEMENT_MOCK needs full visibility of the method
+    MAKE_MOCK1(listInstances, std::vector<ListInstance>(const std::string&), override);
+
+
+    IMPLEMENT_MOCK0(schema);
+
+    IMPLEMENT_MOCK0(commitChanges);
+    IMPLEMENT_MOCK0(discardChanges);
+};
+
+