Mercurial > hg > orthanc
changeset 289:ffd98d2f0b91
merge
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Fri, 14 Dec 2012 11:22:29 +0100 |
parents | 40d3bf6cc8d9 (current diff) 9cd240cfd3a6 (diff) |
children | b3322636b06d |
files | CMakeLists.txt |
diffstat | 4 files changed, 12 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/CMakeLists.txt Fri Dec 14 11:22:04 2012 +0100 +++ b/CMakeLists.txt Fri Dec 14 11:22:29 2012 +0100 @@ -179,6 +179,7 @@ # Build the unit tests if required if (BUILD_UNIT_TESTS) + add_definitions(-DORTHANC_BUILD_UNIT_TESTS=1) include(${CMAKE_SOURCE_DIR}/Resources/CMake/GoogleTestConfiguration.cmake) add_executable(UnitTests ${GTEST_SOURCES}
--- a/Core/Compression/HierarchicalZipWriter.h Fri Dec 14 11:22:04 2012 +0100 +++ b/Core/Compression/HierarchicalZipWriter.h Fri Dec 14 11:22:29 2012 +0100 @@ -42,8 +42,10 @@ { class HierarchicalZipWriter { +#if ORTHANC_BUILD_UNIT_TESTS == 1 FRIEND_TEST(HierarchicalZipWriter, Index); FRIEND_TEST(HierarchicalZipWriter, Filenames); +#endif private: class Index
--- a/Core/Compression/ZipWriter.h Fri Dec 14 11:22:04 2012 +0100 +++ b/Core/Compression/ZipWriter.h Fri Dec 14 11:22:29 2012 +0100 @@ -35,7 +35,10 @@ #include <stdint.h> #include <string> #include <boost/shared_ptr.hpp> + +#if ORTHANC_BUILD_UNIT_TESTS == 1 #include <gtest/gtest_prod.h> +#endif namespace Orthanc {
--- a/Core/SQLite/Statement.h Fri Dec 14 11:22:04 2012 +0100 +++ b/Core/SQLite/Statement.h Fri Dec 14 11:22:29 2012 +0100 @@ -43,7 +43,10 @@ #include <vector> #include <stdint.h> #include <boost/noncopyable.hpp> + +#if ORTHANC_BUILD_UNIT_TESTS == 1 #include <gtest/gtest_prod.h> +#endif struct sqlite3_stmt; @@ -68,8 +71,11 @@ class Statement : public boost::noncopyable { friend class Connection; + +#if ORTHANC_BUILD_UNIT_TESTS == 1 FRIEND_TEST(SQLStatementTest, Run); FRIEND_TEST(SQLStatementTest, Reset); +#endif private: StatementReference reference_;