From 951fe8a67dbd1ee5fc92db62cfd7f8905eb4503d Mon Sep 17 00:00:00 2001 From: dmatetelki Date: Mon, 24 Aug 2015 12:20:18 +0200 Subject: [PATCH] Catch requires test files to be compulation units. --- test/CMakeLists.txt | 12 +++++++++++- test/graph/{test_graph.hpp => test_graph.cpp} | 0 ...raph_algorithms.hpp => test_graph_algorithms.cpp} | 0 test/test_main.cpp | 3 --- 4 files changed, 11 insertions(+), 4 deletions(-) rename test/graph/{test_graph.hpp => test_graph.cpp} (100%) rename test/graph/{test_graph_algorithms.hpp => test_graph_algorithms.cpp} (100%) diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 9f43866..a762b1d 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -1,3 +1,13 @@ include_directories(../lib) -add_executable (test_bin test_main.cpp) +add_executable ( +test_bin + +graph/test_graph.cpp +graph/test_priority_queue.cpp +graph/test_quad_tree.cpp +graph/test_graph_algorithms.cpp + +test_main.cpp) + +target_link_libraries(test_bin gcov) diff --git a/test/graph/test_graph.hpp b/test/graph/test_graph.cpp similarity index 100% rename from test/graph/test_graph.hpp rename to test/graph/test_graph.cpp diff --git a/test/graph/test_graph_algorithms.hpp b/test/graph/test_graph_algorithms.cpp similarity index 100% rename from test/graph/test_graph_algorithms.hpp rename to test/graph/test_graph_algorithms.cpp diff --git a/test/test_main.cpp b/test/test_main.cpp index f465b9d..0c7c351 100644 --- a/test/test_main.cpp +++ b/test/test_main.cpp @@ -1,5 +1,2 @@ #define CATCH_CONFIG_MAIN #include "catch.hpp" - -#include "graph/test_graph.hpp" -#include "graph/test_graph_algorithms.hpp" \ No newline at end of file