Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortatiana-yan <tatiana.kondakova@gmail.com>2018-10-15 18:18:16 +0300
committerVladimir Byko-Ianko <bykoianko@gmail.com>2018-10-16 15:03:27 +0300
commit61dad68a7314deebcf2dabd934b7eacfc3696bf7 (patch)
tree5653d47389903e0ff9db56722c062e581cb510c2 /indexer
parente5cc7611b02f38e0183aa14f7048934c69e12153 (diff)
[test] Fix classificator load in tests.
Diffstat (limited to 'indexer')
-rw-r--r--indexer/indexer_tests/classificator_tests.cpp26
1 files changed, 7 insertions, 19 deletions
diff --git a/indexer/indexer_tests/classificator_tests.cpp b/indexer/indexer_tests/classificator_tests.cpp
index 325b1e5aff..0a7e881744 100644
--- a/indexer/indexer_tests/classificator_tests.cpp
+++ b/indexer/indexer_tests/classificator_tests.cpp
@@ -1,30 +1,18 @@
#include "testing/testing.hpp"
#include "indexer/classificator.hpp"
-#include "indexer/classificator_loader.hpp"
+
+#include "generator/generator_tests_support/test_with_classificator.hpp"
#include <algorithm>
#include <cstdint>
#include <string>
#include <vector>
+using namespace generator::tests_support;
using namespace std;
-namespace
-{
-class ClassificatorTest
-{
-public:
- ClassificatorTest()
- {
- classificator::Load();
- }
-
- ~ClassificatorTest() = default;
-};
-} // namespace
-
-UNIT_CLASS_TEST(ClassificatorTest, Classificator_GetType)
+UNIT_CLASS_TEST(TestWithClassificator, Classificator_GetType)
{
Classificator const & c = classif();
@@ -43,7 +31,7 @@ UNIT_CLASS_TEST(ClassificatorTest, Classificator_GetType)
TEST(!c.IsTypeValid(0), ());
}
-UNIT_CLASS_TEST(ClassificatorTest, Classificator_CoastlineType)
+UNIT_CLASS_TEST(TestWithClassificator, Classificator_CoastlineType)
{
Classificator const & c = classif();
@@ -52,7 +40,7 @@ UNIT_CLASS_TEST(ClassificatorTest, Classificator_CoastlineType)
TEST_EQUAL(type, c.GetCoastType(), ());
}
-UNIT_CLASS_TEST(ClassificatorTest, Classificator_GetIndex)
+UNIT_CLASS_TEST(TestWithClassificator, Classificator_GetIndex)
{
Classificator const & c = classif();
@@ -62,7 +50,7 @@ UNIT_CLASS_TEST(ClassificatorTest, Classificator_GetIndex)
TEST_EQUAL(type, c.GetTypeForIndex(index), ());
}
-UNIT_CLASS_TEST(ClassificatorTest, Classificator_Subtree)
+UNIT_CLASS_TEST(TestWithClassificator, Classificator_Subtree)
{
Classificator const & c = classif();