Added generator tests and storage tests/integration_tests

This commit is contained in:
Timofey 2016-12-22 14:39:57 +03:00
parent d76fdc2e3c
commit 36265a91bd
7 changed files with 238 additions and 1 deletions

View file

@ -0,0 +1,21 @@
project(gflags)
include_directories(src)
set(
SRC
src/config.h
src/gflags.cc
src/gflags/gflags.h
src/gflags/gflags_completions.h
src/gflags_completions.cc
src/gflags_reporting.cc
src/windows/config.h
src/windows/gflags/gflags.h
src/windows/gflags/gflags_completions.h
src/windows/port.h
)
# if PLATFORM_WINDOWS: src += src/windows/port.cc
add_library(${PROJECT_NAME} ${SRC})

View file

@ -180,6 +180,7 @@ add_subdirectory(3party/liboauthcpp)
add_subdirectory(3party/pugixml)
add_subdirectory(3party/succinct)
add_subdirectory(3party/osrm)
add_subdirectory(3party/gflags)
add_subdirectory(base)
add_subdirectory(coding)
add_subdirectory(geometry)

View file

@ -91,3 +91,4 @@ set(SRC
add_library(${PROJECT_NAME} ${SRC})
omim_add_test_subdirectory(generator_tests_support)
omim_add_test_subdirectory(generator_tests)

View file

@ -0,0 +1,73 @@
project(generator_tests)
set(
SRC
altitude_test.cpp
check_mwms.cpp
coasts_test.cpp
feature_builder_test.cpp
feature_merger_test.cpp
metadata_parser_test.cpp
osm2meta_test.cpp
osm_id_test.cpp
osm_o5m_source_test.cpp
osm_type_test.cpp
restriction_collector_test.cpp
restriction_test.cpp
source_data.cpp
source_data.hpp
source_to_element_test.cpp
srtm_parser_test.cpp
tag_admixer_test.cpp
tesselator_test.cpp
triangles_tree_coding_test.cpp
types_helper.hpp
)
omim_add_test(${PROJECT_NAME} ${SRC})
omim_link_libraries(
${PROJECT_NAME}
generator_tests_support
platform_tests_support
generator
drape_frontend
routing
search
storage
indexer
drape
map
traffic
editor
oauthcpp
platform
geometry
coding
base
freetype
expat
fribidi
jansson
protobuf
osrm
stats_client
minizip
succinct
pugixml
tess2
gflags
opening_hours
${LIBZ}
${Qt5Core_LIBRARIES}
)
if (PLATFORM_MAC)
omim_link_libraries(
${PROJECT_NAME}
"-framework IOKit"
"-framework QuartzCore"
"-framework Cocoa"
"-framework SystemConfiguration"
)
endif()

View file

@ -35,4 +35,5 @@ set(
add_library(${PROJECT_NAME} ${SRC})
#add_subdirectory(storage_tests)
omim_add_test_subdirectory(storage_tests)
omim_add_test_subdirectory(storage_integration_tests)

View file

@ -0,0 +1,69 @@
project(storage_integration_tests)
include_directories(${OMIM_ROOT}/3party/glm)
add_definitions("-DOMIM_UNIT_TEST_WITH_QT_EVENT_LOOP")
set(
SRC
migrate_tests.cpp
storage_3levels_tests.cpp
storage_downloading_tests.cpp
storage_group_download_tests.cpp
storage_http_tests.cpp
storage_update_tests.cpp
test_defines.cpp
test_defines.hpp
)
omim_add_test(${PROJECT_NAME} ${SRC})
omim_link_libraries(
${PROJECT_NAME}
map
drape_frontend
routing
search
storage
tracking
traffic
indexer
drape
partners_api
platform_tests_support
platform
editor
opening_hours
geometry
coding
base
freetype
expat
fribidi
jansson
protobuf
osrm
stats_client
minizip
succinct
pugixml
oauthcpp
${Qt5Core_LIBRARIES}
${LIBZ}
)
if (PLATFORM_MAC)
omim_link_libraries(
${PROJECT_NAME}
${Qt5Widgets_LIBRARIES}
"-framework OpenGL"
)
endif()
if(PLATFORM_LINUX)
omim_link_libraries(
${PROJECT_NAME}
${Qt5Network_LIBRARIES}
${Qt5OpenGL_LIBRARIES}
GL
)
endif()

View file

@ -0,0 +1,71 @@
project(storage_tests)
add_definitions("-DOMIM_UNIT_TEST_WITH_QT_EVENT_LOOP")
set(
SRC
country_info_getter_test.cpp
country_name_getter_test.cpp
fake_map_files_downloader.cpp
fake_map_files_downloader.hpp
helpers.cpp
helpers.hpp
queued_country_tests.cpp
simple_tree_test.cpp
storage_tests.cpp
task_runner.cpp
task_runner.hpp
test_map_files_downloader.cpp
test_map_files_downloader.hpp
)
omim_add_test(${PROJECT_NAME} ${SRC})
omim_link_libraries(
${PROJECT_NAME}
drape_frontend
map
traffic
storage
drape
generator_tests_support
generator
search
routing
indexer
platform_tests_support
osrm
editor
oauthcpp
platform
opening_hours
geometry
coding
base
freetype
expat
fribidi
jansson
tess2
protobuf
stats_client
minizip
succinct
pugixml
${Qt5Core_LIBRARIES}
${LIBZ}
)
if (PLATFORM_MAC)
omim_link_libraries(
${PROJECT_NAME}
${Qt5Widgets_LIBRARIES}
)
endif()
if(PLATFORM_LINUX)
omim_link_libraries(
${PROJECT_NAME}
${Qt5Network_LIBRARIES}
)
endif()