diff options
| author | Even Rouault <even.rouault@spatialys.com> | 2018-05-30 12:06:10 +0200 |
|---|---|---|
| committer | Even Rouault <even.rouault@spatialys.com> | 2018-05-30 12:06:10 +0200 |
| commit | 6fbfa8eead3dca8edd427bbf4abf496cc3366d14 (patch) | |
| tree | 63e040eaba7b95f4593c7acfef01733cdcdb78ea | |
| parent | a3c592894d01095776ed96593edb0550ec1a68fe (diff) | |
| download | PROJ-6fbfa8eead3dca8edd427bbf4abf496cc3366d14.tar.gz PROJ-6fbfa8eead3dca8edd427bbf4abf496cc3366d14.zip | |
Move catch.hpp header in test/; rename test/cpp as test/unit
| -rw-r--r-- | configure.ac | 2 | ||||
| -rw-r--r-- | test/CMakeLists.txt | 11 | ||||
| -rw-r--r-- | test/Makefile.am | 11 | ||||
| -rw-r--r-- | test/catch.hpp (renamed from test/cpp/catch.hpp) | 0 | ||||
| -rw-r--r-- | test/cpp/Makefile.am | 20 | ||||
| -rw-r--r-- | test/test_main.cpp (renamed from test/cpp/test_main.cpp) | 0 | ||||
| -rw-r--r-- | test/unit/CMakeLists.txt (renamed from test/cpp/CMakeLists.txt) | 10 | ||||
| -rw-r--r-- | test/unit/Makefile.am | 13 | ||||
| -rw-r--r-- | test/unit/basic_test.cpp (renamed from test/cpp/basic_test.cpp) | 0 |
9 files changed, 35 insertions, 32 deletions
diff --git a/configure.ac b/configure.ac index b09d3d87..68436081 100644 --- a/configure.ac +++ b/configure.ac @@ -263,7 +263,7 @@ AC_SUBST(MUTEX_SETTING,$MUTEX_SETTING) AC_SUBST(THREAD_LIB,$THREAD_LIB) AC_CONFIG_FILES([Makefile cmake/Makefile src/Makefile - test/Makefile test/gie/Makefile test/gigs/Makefile test/cpp/Makefile + test/Makefile test/gie/Makefile test/gigs/Makefile test/unit/Makefile man/Makefile man/man1/Makefile man/man3/Makefile nad/Makefile jniwrap/Makefile jniwrap/org.osgeo.proj/Makefile jniwrap/org.osgeo.proj/org/Makefile jniwrap/org.osgeo.proj/org/proj4/Makefile]) AC_CONFIG_FILES([nad/install], [chmod +x nad/install]) diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 6f98e747..cf71df41 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -43,4 +43,13 @@ proj_add_gie_test("GIGS-5201" "gigs/5201.gie") #proj_add_gie_test("GIGS-5207.2" "gigs/5207.2.gie") proj_add_gie_test("GIGS-5208" "gigs/5208.gie") -add_subdirectory(cpp) +SET(CATCH2_INCLUDE catch.hpp) + +SET(TEST_MAIN_SRC test_main.cpp) +set(TEST_MAIN_LIBRARIES test_main) +add_library( ${TEST_MAIN_LIBRARIES} + ${PROJ_LIBRARY_TYPE} + ${TEST_MAIN_SRC} + ${CATCH2_INCLUDE} ) + +add_subdirectory(unit) diff --git a/test/Makefile.am b/test/Makefile.am index 541668c7..6fb30c4f 100644 --- a/test/Makefile.am +++ b/test/Makefile.am @@ -1,3 +1,10 @@ -SUBDIRS = gie gigs cpp - EXTRA_DIST = CMakeLists.txt + +include_HEADERS = catch.hpp + +lib_LTLIBRARIES = libtestmain.la + +libtestmain_la_LDFLAGS = -no-undefined +libtestmain_la_SOURCES = test_main.cpp + +SUBDIRS = . gie gigs unit diff --git a/test/cpp/catch.hpp b/test/catch.hpp index ecd8907e..ecd8907e 100644 --- a/test/cpp/catch.hpp +++ b/test/catch.hpp diff --git a/test/cpp/Makefile.am b/test/cpp/Makefile.am deleted file mode 100644 index 1130bbce..00000000 --- a/test/cpp/Makefile.am +++ /dev/null @@ -1,20 +0,0 @@ -EXTRA_DIST = CMakeLists.txt - -AM_CPPFLAGS = -I$(top_srcdir)/src - -include_HEADERS = catch.hpp - -bin_PROGRAMS = basic_test - -lib_LTLIBRARIES = libtestmain.la - -libtestmain_la_LDFLAGS = -no-undefined -libtestmain_la_SOURCES = test_main.cpp - -basic_test_SOURCES = basic_test.cpp -basic_test_LDADD = ../../src/libproj.la libtestmain.la - -basic_test-check: basic_test - ./basic_test - -check-local: basic_test-check diff --git a/test/cpp/test_main.cpp b/test/test_main.cpp index 0c7c351f..0c7c351f 100644 --- a/test/cpp/test_main.cpp +++ b/test/test_main.cpp diff --git a/test/cpp/CMakeLists.txt b/test/unit/CMakeLists.txt index aa8b290b..64fbede0 100644 --- a/test/cpp/CMakeLists.txt +++ b/test/unit/CMakeLists.txt @@ -1,11 +1,5 @@ -SET(CATCH2_INCLUDE catch.hpp) - -SET(TEST_MAIN_SRC test_main.cpp) -set(TEST_MAIN_LIBRARIES test_main) -add_library( ${TEST_MAIN_LIBRARIES} - ${PROJ_LIBRARY_TYPE} - ${TEST_MAIN_SRC} - ${CATCH2_INCLUDE} ) +SET(CATCH2_INCLUDE ../catch.hpp) +include_directories(..) SET(BASIC_TEST_SRC basic_test.cpp) add_executable(basic_test ${BASIC_TEST_SRC} ${CATCH2_INCLUDE}) diff --git a/test/unit/Makefile.am b/test/unit/Makefile.am new file mode 100644 index 00000000..3476dd96 --- /dev/null +++ b/test/unit/Makefile.am @@ -0,0 +1,13 @@ +EXTRA_DIST = CMakeLists.txt + +AM_CPPFLAGS = -I$(top_srcdir)/src -I$(top_srcdir)/test + +bin_PROGRAMS = basic_test + +basic_test_SOURCES = basic_test.cpp +basic_test_LDADD = ../../src/libproj.la ../../test/libtestmain.la + +basic_test-check: basic_test + ./basic_test + +check-local: basic_test-check diff --git a/test/cpp/basic_test.cpp b/test/unit/basic_test.cpp index 5a153331..5a153331 100644 --- a/test/cpp/basic_test.cpp +++ b/test/unit/basic_test.cpp |
