From 992b9f78a4a2c6b46e0775c42e547f9f94e5ed6e Mon Sep 17 00:00:00 2001 From: Victor Kotlyar <Victor.Kotlyar@cern.ch> Date: Fri, 21 Jun 2019 11:13:02 +0200 Subject: [PATCH] Add CTA_SCHEMA_VERSIONs to the common/Constant.hpp --- catalogue/CatalogueTest.cpp | 5 +++-- common/Constants.hpp | 2 ++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/catalogue/CatalogueTest.cpp b/catalogue/CatalogueTest.cpp index 259279e493..19f659c116 100644 --- a/catalogue/CatalogueTest.cpp +++ b/catalogue/CatalogueTest.cpp @@ -39,6 +39,7 @@ #include "common/exception/Exception.hpp" #include "common/exception/UserError.hpp" #include "common/make_unique.hpp" +#include "common/Constants.hpp" #include "rdbms/wrapper/ConnFactoryFactory.hpp" #include "rdbms/Conn.hpp" #include "rdbms/ConnPool.hpp" @@ -12242,8 +12243,8 @@ TEST_P(cta_catalogue_CatalogueTest, getSchemaVersion) { using namespace cta; const std::map<std::string,uint64_t> schemaVersion = { - {"SCHEMA_VERSION_MAJOR", 0}, - {"SCHEMA_VERSION_MINOR", 0} + {"SCHEMA_VERSION_MAJOR", CTA_SCHEMA_VERSION_MAJOR}, + {"SCHEMA_VERSION_MINOR", CTA_SCHEMA_VERSION_MINOR} }; const auto schemaDbVersion = m_catalogue->getSchemaVersion(); diff --git a/common/Constants.hpp b/common/Constants.hpp index 0ce76c46a0..3943b9697c 100644 --- a/common/Constants.hpp +++ b/common/Constants.hpp @@ -27,6 +27,8 @@ namespace cta { const int CA_MAXVIDLEN = 6; // maximum length for a VID +const int CTA_SCHEMA_VERSION_MAJOR = 0; +const int CTA_SCHEMA_VERSION_MINOR = 0; } // namespace cta -- GitLab