forked from organicmaps/organicmaps
[new downloader] Adding tests on Storage::GetNodeAttrs() method.
This commit is contained in:
parent
e6b8ce19ab
commit
d99e6c7458
1 changed files with 10 additions and 0 deletions
|
@ -1202,18 +1202,28 @@ UNIT_TEST(StorageTest_GetNodeAttrsSingleMwm)
|
|||
TEST_EQUAL(nodeAttrs.m_mwmSize, 4689718, ());
|
||||
TEST_EQUAL(nodeAttrs.m_status, NodeStatus::NotDownloaded, ());
|
||||
TEST_EQUAL(nodeAttrs.m_error, NodeErrorCode::NoError, ());
|
||||
TEST_EQUAL(nodeAttrs.m_parentCountryId, "Countries", ());
|
||||
|
||||
storage.GetNodeAttrs("Algeria", nodeAttrs);
|
||||
TEST_EQUAL(nodeAttrs.m_mwmCounter, 2, ());
|
||||
TEST_EQUAL(nodeAttrs.m_mwmSize, 90878678, ());
|
||||
TEST_EQUAL(nodeAttrs.m_status, NodeStatus::NotDownloaded, ());
|
||||
TEST_EQUAL(nodeAttrs.m_error, NodeErrorCode::NoError, ());
|
||||
TEST_EQUAL(nodeAttrs.m_parentCountryId, "Countries", ());
|
||||
|
||||
storage.GetNodeAttrs("Algeria_Coast", nodeAttrs);
|
||||
TEST_EQUAL(nodeAttrs.m_mwmCounter, 1, ());
|
||||
TEST_EQUAL(nodeAttrs.m_mwmSize, 66701534, ());
|
||||
TEST_EQUAL(nodeAttrs.m_status, NodeStatus::NotDownloaded, ());
|
||||
TEST_EQUAL(nodeAttrs.m_error, NodeErrorCode::NoError, ());
|
||||
TEST_EQUAL(nodeAttrs.m_parentCountryId, "Algeria", ());
|
||||
|
||||
storage.GetNodeAttrs("South Korea_South", nodeAttrs);
|
||||
TEST_EQUAL(nodeAttrs.m_mwmCounter, 1, ());
|
||||
TEST_EQUAL(nodeAttrs.m_mwmSize, 48394664, ());
|
||||
TEST_EQUAL(nodeAttrs.m_status, NodeStatus::NotDownloaded, ());
|
||||
TEST_EQUAL(nodeAttrs.m_error, NodeErrorCode::NoError, ());
|
||||
TEST_EQUAL(nodeAttrs.m_parentCountryId, "Countries", ());
|
||||
}
|
||||
|
||||
UNIT_TEST(StorageTest_ParseStatus)
|
||||
|
|
Loading…
Add table
Reference in a new issue