From 584ccd333d4e1da33e9ce7b0c87856aefd77e2da Mon Sep 17 00:00:00 2001 From: Christian Gruber Date: Wed, 8 Apr 2020 22:12:58 +0200 Subject: [PATCH] Add test-import-backend to CMakeLists.txt --- gnucash/import-export/test/CMakeLists.txt | 44 +++++++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/gnucash/import-export/test/CMakeLists.txt b/gnucash/import-export/test/CMakeLists.txt index 8d197e57c7..4e9d1efae2 100644 --- a/gnucash/import-export/test/CMakeLists.txt +++ b/gnucash/import-export/test/CMakeLists.txt @@ -41,3 +41,47 @@ gnc_add_test(test-import-account-matcher gtest-import-account-matcher.cpp set_dist_list(test_generic_import_DIST CMakeLists.txt test-link.c test-import-parse.c test-import-pending-matches.cpp gtest-import-account-matcher.cpp) + +set(gtest_import_backend_INCLUDE_DIRS + ${CMAKE_BINARY_DIR}/common # for config.h + ${CMAKE_SOURCE_DIR}/common + ${CMAKE_SOURCE_DIR}/gnucash/import-export + ${CMAKE_SOURCE_DIR}/libgnucash/app-utils + ${CMAKE_SOURCE_DIR}/libgnucash/core-utils + ${CMAKE_SOURCE_DIR}/libgnucash/engine + ${GTEST_INCLUDE_DIR} + ${GMOCK_INCLUDE_DIR} +) + +set(gtest_import_backend_LIBS + PkgConfig::GTK3 + ${Boost_LIBRARIES} + ${GMODULE_LDFLAGS} + ${GTHREAD_LDFLAGS} + ${ICU4C_I18N_LDFLAGS} + ${GTEST_LIB} + ${GMOCK_LIB} +) + +set(gtest_import_backend_SOURCES + gtest-import-backend.cpp + ${CMAKE_SOURCE_DIR}/gnucash/import-export/import-backend.c + ${CMAKE_SOURCE_DIR}/gnucash/import-export/import-settings.c + ${CMAKE_SOURCE_DIR}/gnucash/import-export/import-utilities.c + gmock-qofinstance.cpp + gmock-qofbook.cpp + gmock-Account.cpp + gmock-Transaction.cpp + gmock-Split.cpp + ${CMAKE_SOURCE_DIR}/libgnucash/engine/gnc-numeric.cpp + ${CMAKE_SOURCE_DIR}/libgnucash/engine/gnc-rational.cpp + ${CMAKE_SOURCE_DIR}/libgnucash/engine/gnc-int128.cpp + ${CMAKE_SOURCE_DIR}/libgnucash/engine/gnc-date.cpp + ${CMAKE_SOURCE_DIR}/libgnucash/engine/gnc-datetime.cpp + ${CMAKE_SOURCE_DIR}/libgnucash/engine/gnc-timezone.cpp + ${CMAKE_SOURCE_DIR}/libgnucash/core-utils/gnc-locale-utils.cpp +) + +gnc_add_test(test-import-backend "${gtest_import_backend_SOURCES}" + gtest_import_backend_INCLUDE_DIRS gtest_import_backend_LIBS) +