Browse Source

disable some of nearfield tests

Konstantin Ladutenko 2 years ago
parent
commit
e152a77726
4 changed files with 4 additions and 15 deletions
  1. 0 5
      CMakeLists.txt
  2. 0 2
      tests/test_bulk_sphere.cc
  3. 4 6
      tests/test_cases.hpp
  4. 0 2
      tests/test_near_field.cc

+ 0 - 5
CMakeLists.txt

@@ -55,11 +55,6 @@ if (Boost_FOUND)
         include_directories(${Boost_INCLUDE_DIRS})
     endif ()
 endif()
-OPTION(SKIP_LONG_TESTS "Skip some tests (usefull for multiprecision)" OFF)
-if (SKIP_LONG_TESTS) 
-    message("Skipping long tests for GTest...")
-    add_definitions(-DSKIP_LONG_TESTS)
-endif()
 
 #Find Python, NumPy and PyBind11
 find_package(Python COMPONENTS Interpreter Development)

+ 0 - 2
tests/test_bulk_sphere.cc

@@ -48,7 +48,6 @@ std::vector<std::tuple<double, std::complex<double>, double, double, char> >
         {0.055, {1.5, 1}, 0.10149104, 1.131687e-05, 'g'},
         {0.056, {1.5, 1}, 0.1033467, 1.216311e-05, 'h'},
         {1, {10, 10}, 2.532993, 2.049405, 'k'},
-#ifdef SKIP_LONG_TESTS
         {100, {1.33, 1e-5}, 2.101321, 2.096594, 'e'},
         {100, {1.5, 1}, 2.097502, 1.283697, 'i'},
         {1000, {0.75, 0}, 1.997908, 1.997908, 'd'},
@@ -56,7 +55,6 @@ std::vector<std::tuple<double, std::complex<double>, double, double, char> >
         {10000, {1.33, 1e-5}, 2.004089, 1.723857, 'f'},
         {10000, {1.5, 1}, 2.004368, 1.236574, 'j'},
         {10000, {10, 10}, 2.005914, 1.795393, 'm'},
-#endif
     };
 //******************************************************************************
 TEST(BulkSphere, DISABLED_HandlesInput) {

+ 4 - 6
tests/test_cases.hpp

@@ -17,16 +17,14 @@ std::vector<std::tuple<double, std::complex<double>, std::string> >
         {0.055, {1.5, 1}, "Hong Du testcase:g"},
         {0.056, {1.5, 1}, "Hong Du testcase:h"},
         {1, {10, 10}, "Hong Du testcase:k"},
-#ifdef SKIP_LONG_TESTS
         {100, {1.5, 1}, "Hong Du testcase:i"},
         {1000, {0.75, 0}, "Hong Du testcase:d"},
         // passes but takes too long
-        {10000, {1.33, 1e-5}, "Hong Du testcase:f"},
+        // {10000, {1.33, 1e-5}, "Hong Du testcase:f"},
         // fails in any precision, TODO fixme
-        {100, {10, 10}, "Hong Du testcase:l"},
-        {10000, {1.5, 1}, "Hong Du testcase:j"},
-        {10000, {10, 10}, "Hong Du testcase:m"},
-#endif
+        // {100, {10, 10}, "Hong Du testcase:l"},
+        // {10000, {1.5, 1}, "Hong Du testcase:j"},
+        // {10000, {10, 10}, "Hong Du testcase:m"},
     };
 
 #endif  // SCATTNLAY_TESTS_TEST_CASES_HPP_

+ 0 - 2
tests/test_near_field.cc

@@ -52,7 +52,6 @@ TEST(RunFieldCalculationCartesian, HandlesInput) {
   //  auto Eabs = nmie.GetFieldEabs();
   //  EXPECT_TRUE(std::isnan(static_cast<double>(Eabs[0])));
 }
-#ifdef SKIP_LONG_TESTS
 TEST(LargeBubbleSpectrum, DISABLED_HandlesInput) {
   // TEST(LargeBubbleSpectrum, HandlesInput) { // TODO fix fail...
   nmie::MultiLayerMie<nmie::FloatType> nmie;
@@ -85,7 +84,6 @@ TEST(LargeBubbleSpectrum, DISABLED_HandlesInput) {
                 abs(Qsca[1] - Qsca[2]));
   }
 }
-#endif
 
 // TEST(RunFieldCalculationPolar, DISABLED_HandlesInput) {
 TEST(RunFieldCalculationPolar, HandlesInput) {