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:
authorArsentiy Milchakov <milcars@mapswithme.com>2017-05-11 19:20:24 +0300
committerr.kuznetsov <r.kuznetsov@corp.mail.ru>2017-05-19 16:42:03 +0300
commit9cd7f4f8fa016367ec29aaf84fcf62cfbc9026c5 (patch)
tree03382400e89c281fa3ffdf731d1d79bc8b12998a /indexer/indexer_tests
parentd25221d52a9b87b83e97224f084e74fc4a6d0f6c (diff)
[editor] notes reformatting
Diffstat (limited to 'indexer/indexer_tests')
-rw-r--r--indexer/indexer_tests/osm_editor_test.cpp12
1 files changed, 10 insertions, 2 deletions
diff --git a/indexer/indexer_tests/osm_editor_test.cpp b/indexer/indexer_tests/osm_editor_test.cpp
index b0df3afaa9..32790b9d58 100644
--- a/indexer/indexer_tests/osm_editor_test.cpp
+++ b/indexer/indexer_tests/osm_editor_test.cpp
@@ -655,7 +655,10 @@ void EditorTest::HaveMapEditsOrNotesToUploadTest()
ForEachCafeAtPoint(m_index, m2::PointD(1.0, 1.0), [&editor](FeatureType & ft)
{
using NoteType = osm::Editor::NoteProblemType;
- editor.CreateNote({1.0, 1.0}, ft.GetID(), NoteType::PlaceDoesNotExist, "exploded");
+ feature::TypesHolder typesHolder;
+ string defaultName;
+ editor.CreateNote({1.0, 1.0}, ft.GetID(), typesHolder, defaultName, NoteType::PlaceDoesNotExist,
+ "exploded");
});
TEST(editor.HaveMapEditsOrNotesToUpload(), ());
@@ -828,13 +831,18 @@ void EditorTest::CreateNoteTest()
{
platform::tests_support::ScopedFile sf("test_notes.xml");
editor.m_notes = Notes::MakeNotes(sf.GetFullPath(), true);
- editor.CreateNote(pos, fId, noteType, "with comment");
+ feature::TypesHolder holder;
+ holder.Assign(classif().GetTypeByPath({"amenity", "restaurant"}));
+ string defaultName = "Test name";
+ editor.CreateNote(pos, fId, holder, defaultName, noteType, "with comment");
auto notes = editor.m_notes->GetNotes();
TEST_EQUAL(notes.size(), 1, ());
TEST(notes.front().m_point.EqualDxDy(pos, 1e-10), ());
TEST_NOT_EQUAL(notes.front().m_note.find("with comment"), string::npos, ());
TEST_NOT_EQUAL(notes.front().m_note.find("OSM data version"), string::npos, ());
+ TEST_NOT_EQUAL(notes.front().m_note.find("restaurant"), string::npos, ());
+ TEST_NOT_EQUAL(notes.front().m_note.find("Test name"), string::npos, ());
};
ForEachCafeAtPoint(m_index, m2::PointD(1.0, 1.0), [&editor, &createAndCheckNote](FeatureType & ft)