fix unittests.
authorKim Kulling <kim.kulling@googlemail.com>
Wed, 28 Jun 2017 18:11:13 +0000 (20:11 +0200)
committerKim Kulling <kim.kulling@googlemail.com>
Wed, 28 Jun 2017 18:11:13 +0000 (20:11 +0200)
code/CMakeLists.txt
test/unit/ut3DSImportExport.cpp
test/unit/utASEImportExport.cpp

index aa5dffc..8249746 100644 (file)
@@ -844,7 +844,7 @@ SET( assimp_src
 
 )
 ADD_DEFINITIONS( -DOPENDDLPARSER_BUILD )
-ADD_DEFINITIONS( -DASSIMP_BUILD_NO_3DS_IMPORTER)
+
 INCLUDE_DIRECTORIES(
     ${IRRXML_INCLUDE_DIR}
     ../contrib/openddlparser/include
index 07e6fc0..1e9bfe0 100644 (file)
@@ -53,7 +53,11 @@ public:
     virtual bool importerTest() {
         Assimp::Importer importer;
         const aiScene *scene = importer.ReadFile( ASSIMP_TEST_MODELS_DIR "/3DS/fels.3ds", 0 );
+#ifndef ASSIMP_BUILD_NO_3DS_IMPORTER
         return nullptr != scene;
+#else
+        return nullptr == scene;
+#endif // ASSIMP_BUILD_NO_3DS_IMPORTER
     }
 };
 
index baf9000..841aff5 100644 (file)
@@ -53,7 +53,11 @@ public:
     virtual bool importerTest() {
         Assimp::Importer importer;
         const aiScene *scene = importer.ReadFile( ASSIMP_TEST_MODELS_DIR "/ASE/ThreeCubesGreen.ASE", 0 );
+#ifndef ASSIMP_BUILD_NO_3DS_IMPORTER
         return nullptr != scene;
+#else 
+        return nullptr == scene;
+#endif // ASSIMP_BUILD_NO_3DS_IMPORTER
     }
 };