diff --git a/test/Jamfile.v2 b/test/Jamfile.v2 index e8b1431ee..08b34069b 100644 --- a/test/Jamfile.v2 +++ b/test/Jamfile.v2 @@ -979,14 +979,26 @@ test-suite misc : : : : TEST1 [ check-target-builds ../config//has_float128 "GCC libquadmath and __float128 support" : -lquadmath ] [ requires cxx11_auto_declarations cxx11_lambdas cxx11_smart_ptr cxx11_unified_initialization_syntax sfinae_expr ] : tanh_sinh_quadrature_test_1 ] + [ run tanh_sinh_quadrature_test.cpp ../../test/build//boost_unit_test_framework + : : : TEST1A [ check-target-builds ../config//has_float128 "GCC libquadmath and __float128 support" : -lquadmath ] + [ requires cxx11_auto_declarations cxx11_lambdas cxx11_smart_ptr cxx11_unified_initialization_syntax sfinae_expr ] : + tanh_sinh_quadrature_test_1a ] [ run tanh_sinh_quadrature_test.cpp ../../test/build//boost_unit_test_framework : : : TEST2 [ check-target-builds ../config//has_float128 "GCC libquadmath and __float128 support" : -lquadmath ] [ requires cxx11_auto_declarations cxx11_lambdas cxx11_smart_ptr cxx11_unified_initialization_syntax sfinae_expr ] : tanh_sinh_quadrature_test_2 ] + [ run tanh_sinh_quadrature_test.cpp ../../test/build//boost_unit_test_framework + : : : TEST2A [ check-target-builds ../config//has_float128 "GCC libquadmath and __float128 support" : -lquadmath ] + [ requires cxx11_auto_declarations cxx11_lambdas cxx11_smart_ptr cxx11_unified_initialization_syntax sfinae_expr ] : + tanh_sinh_quadrature_test_2a ] [ run tanh_sinh_quadrature_test.cpp ../../test/build//boost_unit_test_framework : : : TEST3 [ check-target-builds ../config//has_float128 "GCC libquadmath and __float128 support" : -lquadmath ] [ requires cxx11_auto_declarations cxx11_lambdas cxx11_smart_ptr cxx11_unified_initialization_syntax sfinae_expr ] : tanh_sinh_quadrature_test_3 ] + [ run tanh_sinh_quadrature_test.cpp ../../test/build//boost_unit_test_framework + : : : TEST3A [ check-target-builds ../config//has_float128 "GCC libquadmath and __float128 support" : -lquadmath ] + [ requires cxx11_auto_declarations cxx11_lambdas cxx11_smart_ptr cxx11_unified_initialization_syntax sfinae_expr ] : + tanh_sinh_quadrature_test_3a ] [ run tanh_sinh_quadrature_test.cpp ../../test/build//boost_unit_test_framework : : : release TEST4 [ check-target-builds ../config//has_float128 "GCC libquadmath and __float128 support" : -lquadmath ] [ requires cxx11_auto_declarations cxx11_lambdas cxx11_smart_ptr cxx11_unified_initialization_syntax sfinae_expr ] : @@ -999,6 +1011,10 @@ test-suite misc : : : : TEST6 [ check-target-builds ../config//has_float128 "GCC libquadmath and __float128 support" : -lquadmath ] [ requires cxx11_auto_declarations cxx11_lambdas cxx11_smart_ptr cxx11_unified_initialization_syntax sfinae_expr ] : tanh_sinh_quadrature_test_6 ] + [ run tanh_sinh_quadrature_test.cpp ../../test/build//boost_unit_test_framework + : : : TEST6A [ check-target-builds ../config//has_float128 "GCC libquadmath and __float128 support" : -lquadmath ] + [ requires cxx11_auto_declarations cxx11_lambdas cxx11_smart_ptr cxx11_unified_initialization_syntax sfinae_expr ] : + tanh_sinh_quadrature_test_6a ] [ run tanh_sinh_quadrature_test.cpp ../../test/build//boost_unit_test_framework : : : release TEST7 [ check-target-builds ../config//has_float128 "GCC libquadmath and __float128 support" : -lquadmath ] [ requires cxx11_auto_declarations cxx11_lambdas cxx11_smart_ptr cxx11_unified_initialization_syntax sfinae_expr ] : diff --git a/test/sinh_sinh_quadrature_test.cpp b/test/sinh_sinh_quadrature_test.cpp index d13acdb57..ac7847305 100644 --- a/test/sinh_sinh_quadrature_test.cpp +++ b/test/sinh_sinh_quadrature_test.cpp @@ -158,8 +158,11 @@ void test_nr_examples() Q_expected = pi(); BOOST_CHECK_CLOSE_FRACTION(Q, Q_expected, tol); BOOST_CHECK_CLOSE_FRACTION(L1, Q_expected, tol); - +#if defined(BOOST_MSVC) && (BOOST_MSVC < 1900) + auto f2 = [](const Real& x) { return x > boost::math::tools::log_max_value() ? 0 : exp(-x*x); }; +#else auto f2 = [](const Real& x) { return exp(-x*x); }; +#endif Q = integrator.integrate(f2, integration_limit, &error, &L1); Q_expected = root_pi(); BOOST_CHECK_CLOSE_FRACTION(Q, Q_expected, tol); diff --git a/test/tanh_sinh_quadrature_test.cpp b/test/tanh_sinh_quadrature_test.cpp index 62a43fa1a..a5c0775c6 100644 --- a/test/tanh_sinh_quadrature_test.cpp +++ b/test/tanh_sinh_quadrature_test.cpp @@ -32,7 +32,8 @@ #pragma warning(disable:4127) // Conditional expression is constant #endif -#if !defined(TEST1) && !defined(TEST2) && !defined(TEST3) && !defined(TEST4) && !defined(TEST5) && !defined(TEST6) && !defined(TEST7) && !defined(TEST8) +#if !defined(TEST1) && !defined(TEST2) && !defined(TEST3) && !defined(TEST4) && !defined(TEST5) && !defined(TEST6) && !defined(TEST7) && !defined(TEST8)\ + && !defined(TEST1A) && !defined(TEST2A) && !defined(TEST3A) && !defined(TEST6A) # define TEST1 # define TEST2 # define TEST3 @@ -41,6 +42,10 @@ # define TEST6 # define TEST7 # define TEST8 +# define TEST1A +# define TEST2A +# define TEST3A +# define TEST6A #endif using std::expm1; @@ -806,13 +811,14 @@ BOOST_AUTO_TEST_CASE(tanh_sinh_quadrature_test) test_horrible(); test_integration_over_real_line(); test_nr_examples(); +#endif +#ifdef TEST1A test_early_termination(); test_crc(); test_2_arg(); #endif #ifdef TEST2 - test_right_limit_infinite(); test_left_limit_infinite(); test_linear(); @@ -824,10 +830,11 @@ BOOST_AUTO_TEST_CASE(tanh_sinh_quadrature_test) test_integration_over_real_line(); test_nr_examples(); test_early_termination(); - test_crc(); test_sf(); test_2_arg(); - +#endif +#ifdef TEST2A + test_crc(); #endif #ifdef TEST3 @@ -843,9 +850,11 @@ BOOST_AUTO_TEST_CASE(tanh_sinh_quadrature_test) test_integration_over_real_line(); test_nr_examples(); test_early_termination(); - test_crc(); test_sf(); test_2_arg(); +#endif +#ifdef TEST3A + test_crc(); #endif @@ -886,9 +895,11 @@ BOOST_AUTO_TEST_CASE(tanh_sinh_quadrature_test) test_integration_over_real_line(); test_nr_examples(); test_early_termination(); - test_crc(); test_sf(); test_2_arg(); +#endif +#ifdef TEST6A + test_crc(); #endif #ifdef TEST7