forked from organicmaps/organicmaps
New unit test
Signed-off-by: Anton Makouski <anton.makouski@gmail.com>
This commit is contained in:
parent
ccaf90792e
commit
a67fef95c1
1 changed files with 43 additions and 0 deletions
|
@ -1504,6 +1504,49 @@ UNIT_CLASS_TEST(TestWithClassificator, OsmType_Internet)
|
|||
}
|
||||
}
|
||||
|
||||
// Significant military danger areas for DMZ like in Cyprus or Korea.
|
||||
UNIT_CLASS_TEST(TestWithClassificator, OsmType_MilitaryDanger)
|
||||
{
|
||||
{
|
||||
Tags const tags = {
|
||||
{"landuse", "military"},
|
||||
{"military", "danger_area"},
|
||||
{"wikipedia", "xxx"},
|
||||
};
|
||||
|
||||
auto const params = GetFeatureBuilderParams(tags);
|
||||
|
||||
TEST_EQUAL(params.m_types.size(), 1, (params));
|
||||
TEST(params.IsTypeExist(GetType({"landuse", "military", "danger_area"})), (params));
|
||||
}
|
||||
|
||||
{
|
||||
Tags const tags = {
|
||||
{"landuse", "military"},
|
||||
{"military", "cordon"},
|
||||
{"wikipedia", "xxx"},
|
||||
};
|
||||
|
||||
auto const params = GetFeatureBuilderParams(tags);
|
||||
|
||||
TEST_EQUAL(params.m_types.size(), 1, (params));
|
||||
TEST(params.IsTypeExist(GetType({"landuse", "military", "danger_area"})), (params));
|
||||
}
|
||||
|
||||
{
|
||||
Tags const tags = {
|
||||
{"landuse", "military"},
|
||||
{"military", "danger_area"},
|
||||
};
|
||||
|
||||
auto const params = GetFeatureBuilderParams(tags);
|
||||
|
||||
TEST_EQUAL(params.m_types.size(), 1, (params));
|
||||
// Skip danger_area type without additional wikipedia tags.
|
||||
TEST(params.IsTypeExist(GetType({"landuse", "military"})), (params));
|
||||
}
|
||||
}
|
||||
|
||||
UNIT_CLASS_TEST(TestWithClassificator, OsmType_SimpleTypesSmoke)
|
||||
{
|
||||
Tags const oneTypes = {
|
||||
|
|
Loading…
Add table
Reference in a new issue