diff --git a/minimax/main.cpp b/minimax/main.cpp index 8d8ab324a..a12657ed8 100644 --- a/minimax/main.cpp +++ b/minimax/main.cpp @@ -20,7 +20,7 @@ using boost::math::ntl::pow; #include #include #include -#include // for test_main +#include // for test_main extern boost::math::ntl::RR f(const boost::math::ntl::RR& x, int variant); extern void show_extra( @@ -497,7 +497,7 @@ void graph_poly(const char*, const char*) } } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { std::string line; real_parser const rr_p; @@ -604,5 +604,4 @@ int test_main(int, char* []) std::cout << std::endl; } } - return 0; } diff --git a/test/Jamfile.v2 b/test/Jamfile.v2 index bd0d9e8e8..937792e47 100644 --- a/test/Jamfile.v2 +++ b/test/Jamfile.v2 @@ -66,551 +66,551 @@ else explicit ntl ; -cpp-pch pch : pch.hpp : ../../test/build//boost_test_exec_monitor ; -cpp-pch pch_light : pch_light.hpp : ../../test/build//boost_test_exec_monitor ; +cpp-pch pch : pch.hpp : ../../test/build//boost_unit_test_framework ; +cpp-pch pch_light : pch_light.hpp : ../../test/build//boost_unit_test_framework ; #lib test_instances : float_test_instances.cpp double_test_instances.cpp ldouble_test_instances.cpp real_concept_test_instances.cpp pch # : static ; -run hypot_test.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run pow_test.cpp ../../test/build//boost_test_exec_monitor ; -run log1p_expm1_test.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run powm1_sqrtp1m1_test.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; +run hypot_test.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run pow_test.cpp ../../test/build//boost_unit_test_framework ; +run log1p_expm1_test.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run powm1_sqrtp1m1_test.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; run special_functions_test.cpp ../../test/build//boost_unit_test_framework ; -run test_airy.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_bernoulli.cpp ../../test/build//boost_test_exec_monitor ; -run test_constants.cpp ../../test/build//boost_test_exec_monitor ; +run test_airy.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_bernoulli.cpp ../../test/build//boost_unit_test_framework ; +run test_constants.cpp ../../test/build//boost_unit_test_framework ; run test_print_info_on_type.cpp ; run test_constant_generate.cpp ntl : : : [ check-target-builds ../config//has_ntl_rr : : no ] : test_constant_generate_ntl ; -run test_bessel_j.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_bessel_y.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_bessel_i.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_bessel_k.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_beta.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_beta_dist.cpp ../../test/build//boost_test_exec_monitor ; -run test_binomial.cpp ../../test/build//boost_test_exec_monitor +run test_bessel_j.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_bessel_y.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_bessel_i.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_bessel_k.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_beta.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_beta_dist.cpp ../../test/build//boost_unit_test_framework ; +run test_binomial.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_FLOAT - intel:off + TEST_FLOAT + intel:off : test_binomial_float ; -run test_binomial.cpp ../../test/build//boost_test_exec_monitor +run test_binomial.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_DOUBLE - intel:off + TEST_DOUBLE + intel:off : test_binomial_double ; -run test_binomial.cpp ../../test/build//boost_test_exec_monitor +run test_binomial.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_LDOUBLE - intel:off + TEST_LDOUBLE + intel:off : test_binomial_long_double ; -run test_binomial.cpp ../../test/build//boost_test_exec_monitor +run test_binomial.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_ROUNDING=0 - intel:off + TEST_REAL_CONCEPT + TEST_ROUNDING=0 + intel:off : test_binomial_real_concept0 ; -run test_binomial.cpp ../../test/build//boost_test_exec_monitor +run test_binomial.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_ROUNDING=1 - intel:off + TEST_REAL_CONCEPT + TEST_ROUNDING=1 + intel:off : test_binomial_real_concept1 ; -run test_binomial.cpp ../../test/build//boost_test_exec_monitor +run test_binomial.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_ROUNDING=2 - intel:off + TEST_REAL_CONCEPT + TEST_ROUNDING=2 + intel:off : test_binomial_real_concept2 ; -run test_binomial.cpp ../../test/build//boost_test_exec_monitor +run test_binomial.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_ROUNDING=3 - intel:off + TEST_REAL_CONCEPT + TEST_ROUNDING=3 + intel:off : test_binomial_real_concept3 ; -run test_binomial.cpp ../../test/build//boost_test_exec_monitor +run test_binomial.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_ROUNDING=4 - intel:off + TEST_REAL_CONCEPT + TEST_ROUNDING=4 + intel:off : test_binomial_real_concept4 ; -run test_binomial.cpp ../../test/build//boost_test_exec_monitor +run test_binomial.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_ROUNDING=5 - intel:off + TEST_REAL_CONCEPT + TEST_ROUNDING=5 + intel:off : test_binomial_real_concept5 ; -run test_binomial.cpp ../../test/build//boost_test_exec_monitor +run test_binomial.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_ROUNDING=6 - intel:off + TEST_REAL_CONCEPT + TEST_ROUNDING=6 + intel:off : test_binomial_real_concept6 ; -run test_binomial_coeff.cpp pch ../../test/build//boost_test_exec_monitor ; -run test_carlson.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_cauchy.cpp ../../test/build//boost_test_exec_monitor ; -run test_cbrt.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_chi_squared.cpp ../../test/build//boost_test_exec_monitor ; -run test_classify.cpp pch ../../test/build//boost_test_exec_monitor ; -run test_digamma.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_dist_overloads.cpp ../../test/build//boost_test_exec_monitor ; -run test_ellint_1.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_ellint_2.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_ellint_3.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_erf.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_error_handling.cpp ../../test/build//boost_test_exec_monitor ; -run test_expint.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_exponential_dist.cpp ../../test/build//boost_test_exec_monitor ; -run test_extreme_value.cpp ../../test/build//boost_test_exec_monitor ; -run test_factorials.cpp pch ../../test/build//boost_test_exec_monitor ; -run test_find_location.cpp pch ../../test/build//boost_test_exec_monitor ; -run test_find_scale.cpp pch ../../test/build//boost_test_exec_monitor ; -run test_fisher_f.cpp ../../test/build//boost_test_exec_monitor ; -run test_gamma.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_gamma_dist.cpp pch ../../test/build//boost_test_exec_monitor ; -run test_geometric.cpp ../../test/build//boost_test_exec_monitor ; -run test_hankel.cpp ../../test/build//boost_test_exec_monitor ; -run test_hermite.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_hypergeometric_dist.cpp ../../test/build//boost_test_exec_monitor +run test_binomial_coeff.cpp pch ../../test/build//boost_unit_test_framework ; +run test_carlson.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_cauchy.cpp ../../test/build//boost_unit_test_framework ; +run test_cbrt.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_chi_squared.cpp ../../test/build//boost_unit_test_framework ; +run test_classify.cpp pch ../../test/build//boost_unit_test_framework ; +run test_digamma.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_dist_overloads.cpp ../../test/build//boost_unit_test_framework ; +run test_ellint_1.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_ellint_2.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_ellint_3.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_erf.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_error_handling.cpp ../../test/build//boost_unit_test_framework ; +run test_expint.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_exponential_dist.cpp ../../test/build//boost_unit_test_framework ; +run test_extreme_value.cpp ../../test/build//boost_unit_test_framework ; +run test_factorials.cpp pch ../../test/build//boost_unit_test_framework ; +run test_find_location.cpp pch ../../test/build//boost_unit_test_framework ; +run test_find_scale.cpp pch ../../test/build//boost_unit_test_framework ; +run test_fisher_f.cpp ../../test/build//boost_unit_test_framework ; +run test_gamma.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_gamma_dist.cpp pch ../../test/build//boost_unit_test_framework ; +run test_geometric.cpp ../../test/build//boost_unit_test_framework ; +run test_hankel.cpp ../../test/build//boost_unit_test_framework ; +run test_hermite.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_hypergeometric_dist.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_QUANT=0 - intel:off + TEST_QUANT=0 + intel:off : test_hypergeometric_dist0 ; -run test_hypergeometric_dist.cpp ../../test/build//boost_test_exec_monitor +run test_hypergeometric_dist.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_QUANT=1 - intel:off + TEST_QUANT=1 + intel:off : test_hypergeometric_dist1 ; -run test_hypergeometric_dist.cpp ../../test/build//boost_test_exec_monitor +run test_hypergeometric_dist.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_QUANT=2 - intel:off + TEST_QUANT=2 + intel:off : test_hypergeometric_dist2 ; -run test_hypergeometric_dist.cpp ../../test/build//boost_test_exec_monitor +run test_hypergeometric_dist.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_QUANT=3 - intel:off + TEST_QUANT=3 + intel:off : test_hypergeometric_dist3 ; -run test_hypergeometric_dist.cpp ../../test/build//boost_test_exec_monitor +run test_hypergeometric_dist.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_QUANT=4 - intel:off + TEST_QUANT=4 + intel:off : test_hypergeometric_dist4 ; -run test_hypergeometric_dist.cpp ../../test/build//boost_test_exec_monitor +run test_hypergeometric_dist.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_QUANT=5 - intel:off + TEST_QUANT=5 + intel:off : test_hypergeometric_dist5 ; -run test_ibeta.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_FLOAT - intel:off + TEST_FLOAT + intel:off : test_ibeta_float ; -run test_ibeta.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_DOUBLE - intel:off + TEST_DOUBLE + intel:off : test_ibeta_double ; -run test_ibeta.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_LDOUBLE - intel:off + TEST_LDOUBLE + intel:off : test_ibeta_long_double ; -run test_ibeta.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_DATA=1 - intel:off + TEST_REAL_CONCEPT + TEST_DATA=1 + intel:off : test_ibeta_real_concept1 ; -run test_ibeta.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_DATA=2 - intel:off + TEST_REAL_CONCEPT + TEST_DATA=2 + intel:off : test_ibeta_real_concept2 ; -run test_ibeta.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_DATA=3 - intel:off + TEST_REAL_CONCEPT + TEST_DATA=3 + intel:off : test_ibeta_real_concept3 ; -run test_ibeta.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_DATA=4 - intel:off + TEST_REAL_CONCEPT + TEST_DATA=4 + intel:off : test_ibeta_real_concept4 ; -run test_ibeta_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_FLOAT - intel:off + TEST_FLOAT + intel:off : test_ibeta_inv_float ; -run test_ibeta_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_DOUBLE - intel:off + TEST_DOUBLE + intel:off : test_ibeta_inv_double ; -run test_ibeta_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_LDOUBLE - intel:off + TEST_LDOUBLE + intel:off : test_ibeta_inv_long_double ; -run test_ibeta_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_DATA=1 - intel:off + TEST_REAL_CONCEPT + TEST_DATA=1 + intel:off : test_ibeta_inv_real_concept1 ; -run test_ibeta_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_DATA=2 - intel:off + TEST_REAL_CONCEPT + TEST_DATA=2 + intel:off : test_ibeta_inv_real_concept2 ; -run test_ibeta_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_DATA=3 - intel:off + TEST_REAL_CONCEPT + TEST_DATA=3 + intel:off : test_ibeta_inv_real_concept3 ; -run test_ibeta_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_DATA=4 - intel:off + TEST_REAL_CONCEPT + TEST_DATA=4 + intel:off : test_ibeta_inv_real_concept4 ; -run test_ibeta_inv_ab.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta_inv_ab.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_FLOAT - intel:off + TEST_FLOAT + intel:off : test_ibeta_inv_ab_float ; -run test_ibeta_inv_ab.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta_inv_ab.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_DOUBLE - intel:off + TEST_DOUBLE + intel:off : test_ibeta_inv_ab_double ; -run test_ibeta_inv_ab.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta_inv_ab.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_LDOUBLE - intel:off + TEST_LDOUBLE + intel:off : test_ibeta_inv_ab_long_double ; -run test_ibeta_inv_ab.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta_inv_ab.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_DATA=1 - intel:off + TEST_REAL_CONCEPT + TEST_DATA=1 + intel:off : test_ibeta_inv_ab_real_concept1 ; -run test_ibeta_inv_ab.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta_inv_ab.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_DATA=2 - intel:off + TEST_REAL_CONCEPT + TEST_DATA=2 + intel:off : test_ibeta_inv_ab_real_concept2 ; -run test_ibeta_inv_ab.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_ibeta_inv_ab.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_DATA=3 - intel:off + TEST_REAL_CONCEPT + TEST_DATA=3 + intel:off : test_ibeta_inv_ab_real_concept3 ; -run test_igamma.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_igamma_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_igamma.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_igamma_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_FLOAT - intel:off + TEST_FLOAT + intel:off : test_igamma_inv_float ; -run test_igamma_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_igamma_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_DOUBLE - intel:off + TEST_DOUBLE + intel:off : test_igamma_inv_double ; -run test_igamma_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_igamma_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_LDOUBLE - intel:off + TEST_LDOUBLE + intel:off : test_igamma_inv_long_double ; -run test_igamma_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_igamma_inv.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - intel:off + TEST_REAL_CONCEPT + intel:off : test_igamma_inv_real_concept ; -run test_igamma_inva.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_igamma_inva.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_FLOAT - intel:off + TEST_FLOAT + intel:off : test_igamma_inva_float ; -run test_igamma_inva.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_igamma_inva.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_DOUBLE - intel:off + TEST_DOUBLE + intel:off : test_igamma_inva_double ; -run test_igamma_inva.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_igamma_inva.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_LDOUBLE - intel:off + TEST_LDOUBLE + intel:off : test_igamma_inva_long_double ; -run test_igamma_inva.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor +run test_igamma_inva.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - intel:off + TEST_REAL_CONCEPT + intel:off : test_igamma_inva_real_concept ; run test_instantiate1.cpp test_instantiate2.cpp ; -run test_inverse_chi_squared_distribution.cpp ../../test/build//boost_test_exec_monitor ; -run test_inverse_gamma_distribution.cpp ../../test/build//boost_test_exec_monitor ; +run test_inverse_chi_squared_distribution.cpp ../../test/build//boost_unit_test_framework ; +run test_inverse_gamma_distribution.cpp ../../test/build//boost_unit_test_framework ; -run test_inverse_gaussian.cpp ../../test/build//boost_test_exec_monitor ; +run test_inverse_gaussian.cpp ../../test/build//boost_unit_test_framework ; -run test_jacobi.cpp pch_light ../../test/build//boost_test_exec_monitor ; +run test_jacobi.cpp pch_light ../../test/build//boost_unit_test_framework ; run test_laplace.cpp ../../test/build//boost_unit_test_framework ; -run test_inv_hyp.cpp pch ../../test/build//boost_test_exec_monitor ; -run test_laguerre.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_legendre.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_logistic_dist.cpp ../../test/build//boost_test_exec_monitor ; -run test_lognormal.cpp ../../test/build//boost_test_exec_monitor ; -run test_minima.cpp pch ../../test/build//boost_test_exec_monitor ; -run test_negative_binomial.cpp ../../test/build//boost_test_exec_monitor +run test_inv_hyp.cpp pch ../../test/build//boost_unit_test_framework ; +run test_laguerre.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_legendre.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_logistic_dist.cpp ../../test/build//boost_unit_test_framework ; +run test_lognormal.cpp ../../test/build//boost_unit_test_framework ; +run test_minima.cpp pch ../../test/build//boost_unit_test_framework ; +run test_negative_binomial.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_FLOAT - intel:off + TEST_FLOAT + intel:off : test_negative_binomial_float ; -run test_negative_binomial.cpp ../../test/build//boost_test_exec_monitor +run test_negative_binomial.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_DOUBLE - intel:off + TEST_DOUBLE + intel:off : test_negative_binomial_double ; -run test_negative_binomial.cpp ../../test/build//boost_test_exec_monitor +run test_negative_binomial.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_LDOUBLE - intel:off + TEST_LDOUBLE + intel:off : test_negative_binomial_long_double ; -run test_negative_binomial.cpp ../../test/build//boost_test_exec_monitor +run test_negative_binomial.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - intel:off + TEST_REAL_CONCEPT + intel:off : test_negative_binomial_real_concept ; -run test_next.cpp pch pch ../../test/build//boost_test_exec_monitor ; -run test_nc_chi_squared.cpp pch ../../test/build//boost_test_exec_monitor +run test_next.cpp pch pch ../../test/build//boost_unit_test_framework ; +run test_nc_chi_squared.cpp pch ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_FLOAT - intel:off + TEST_FLOAT + intel:off : test_nc_chi_squared_float ; -run test_nc_chi_squared.cpp pch ../../test/build//boost_test_exec_monitor +run test_nc_chi_squared.cpp pch ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_DOUBLE - intel:off + TEST_DOUBLE + intel:off : test_nc_chi_squared_double ; -run test_nc_chi_squared.cpp pch ../../test/build//boost_test_exec_monitor +run test_nc_chi_squared.cpp pch ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_LDOUBLE - intel:off + TEST_LDOUBLE + intel:off : test_nc_chi_squared_long_double ; -run test_nc_chi_squared.cpp pch ../../test/build//boost_test_exec_monitor +run test_nc_chi_squared.cpp pch ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - intel:off + TEST_REAL_CONCEPT + intel:off : test_nc_chi_squared_real_concept ; -run test_nc_beta.cpp ../../test/build//boost_test_exec_monitor +run test_nc_beta.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_FLOAT - intel:off + TEST_FLOAT + intel:off : test_nc_beta_float ; -run test_nc_beta.cpp ../../test/build//boost_test_exec_monitor +run test_nc_beta.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_DOUBLE - intel:off + TEST_DOUBLE + intel:off : test_nc_beta_double ; -run test_nc_beta.cpp ../../test/build//boost_test_exec_monitor +run test_nc_beta.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_LDOUBLE - intel:off + TEST_LDOUBLE + intel:off : test_nc_beta_long_double ; -run test_nc_beta.cpp ../../test/build//boost_test_exec_monitor +run test_nc_beta.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_DATA=1 - intel:off + TEST_REAL_CONCEPT + TEST_DATA=1 + intel:off : test_nc_beta_real_concept1 ; -run test_nc_beta.cpp ../../test/build//boost_test_exec_monitor +run test_nc_beta.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - TEST_DATA=2 - intel:off + TEST_REAL_CONCEPT + TEST_DATA=2 + intel:off : test_nc_beta_real_concept2 ; -run test_nc_f.cpp pch ../../test/build//boost_test_exec_monitor ; -run test_nc_t.cpp pch ../../test/build//boost_test_exec_monitor +run test_nc_f.cpp pch ../../test/build//boost_unit_test_framework ; +run test_nc_t.cpp pch ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_FLOAT - intel:off + TEST_FLOAT + intel:off : test_nc_t_float ; -run test_nc_t.cpp pch ../../test/build//boost_test_exec_monitor +run test_nc_t.cpp pch ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_DOUBLE - intel:off + TEST_DOUBLE + intel:off : test_nc_t_double ; -run test_nc_t.cpp pch ../../test/build//boost_test_exec_monitor +run test_nc_t.cpp pch ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_LDOUBLE - intel:off + TEST_LDOUBLE + intel:off : test_nc_t_long_double ; -run test_nc_t.cpp pch ../../test/build//boost_test_exec_monitor +run test_nc_t.cpp pch ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - intel:off + TEST_REAL_CONCEPT + intel:off : test_nc_t_real_concept ; -run test_normal.cpp pch ../../test/build//boost_test_exec_monitor ; -run test_owens_t.cpp ../../test/build//boost_test_exec_monitor ; -run test_pareto.cpp ../../test/build//boost_test_exec_monitor ; -run test_poisson.cpp ../../test/build//boost_test_exec_monitor +run test_normal.cpp pch ../../test/build//boost_unit_test_framework ; +run test_owens_t.cpp ../../test/build//boost_unit_test_framework ; +run test_pareto.cpp ../../test/build//boost_unit_test_framework ; +run test_poisson.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_FLOAT - intel:off + TEST_FLOAT + intel:off : test_poisson_float ; -run test_poisson.cpp ../../test/build//boost_test_exec_monitor +run test_poisson.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_DOUBLE - intel:off + TEST_DOUBLE + intel:off : test_poisson_double ; -run test_poisson.cpp ../../test/build//boost_test_exec_monitor +run test_poisson.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_LDOUBLE - intel:off + TEST_LDOUBLE + intel:off : test_poisson_long_double ; -run test_poisson.cpp ../../test/build//boost_test_exec_monitor +run test_poisson.cpp ../../test/build//boost_unit_test_framework : # command line : # input files : # requirements - TEST_REAL_CONCEPT - intel:off + TEST_REAL_CONCEPT + intel:off : test_poisson_real_concept ; -run test_rayleigh.cpp ../../test/build//boost_test_exec_monitor ; +run test_rayleigh.cpp ../../test/build//boost_unit_test_framework ; -run test_rationals.cpp ../../test/build//boost_test_exec_monitor +run test_rationals.cpp ../../test/build//boost_unit_test_framework test_rational_instances/test_rational_double1.cpp test_rational_instances/test_rational_double2.cpp test_rational_instances/test_rational_double3.cpp @@ -632,43 +632,43 @@ test_rational_instances/test_rational_real_concept4.cpp test_rational_instances/test_rational_real_concept5.cpp ; -run test_real_concept.cpp ../../test/build//boost_test_exec_monitor ; -run test_remez.cpp pch ../../test/build//boost_test_exec_monitor ; -run test_roots.cpp pch ../../test/build//boost_test_exec_monitor ; -run test_round.cpp pch ../../test/build//boost_test_exec_monitor ; -run test_spherical_harmonic.cpp test_instances//test_instances pch_light ../../test/build//boost_test_exec_monitor ; -run test_students_t.cpp ../../test/build//boost_test_exec_monitor ; -run test_sign.cpp ../../test/build//boost_test_exec_monitor ; -run test_skew_normal.cpp ../../test/build//boost_test_exec_monitor ; -run test_tgamma_ratio.cpp pch ../../test/build//boost_test_exec_monitor ; -run test_toms748_solve.cpp pch ../../test/build//boost_test_exec_monitor ; -run test_triangular.cpp pch ../../test/build//boost_test_exec_monitor ; -run test_uniform.cpp pch ../../test/build//boost_test_exec_monitor ; -run test_weibull.cpp ../../test/build//boost_test_exec_monitor ; -run test_zeta.cpp test_instances//test_instances ../../test/build//boost_test_exec_monitor pch_light ; +run test_real_concept.cpp ../../test/build//boost_unit_test_framework ; +run test_remez.cpp pch ../../test/build//boost_unit_test_framework ; +run test_roots.cpp pch ../../test/build//boost_unit_test_framework ; +run test_round.cpp pch ../../test/build//boost_unit_test_framework ; +run test_spherical_harmonic.cpp test_instances//test_instances pch_light ../../test/build//boost_unit_test_framework ; +run test_students_t.cpp ../../test/build//boost_unit_test_framework ; +run test_sign.cpp ../../test/build//boost_unit_test_framework ; +run test_skew_normal.cpp ../../test/build//boost_unit_test_framework ; +run test_tgamma_ratio.cpp pch ../../test/build//boost_unit_test_framework ; +run test_toms748_solve.cpp pch ../../test/build//boost_unit_test_framework ; +run test_triangular.cpp pch ../../test/build//boost_unit_test_framework ; +run test_uniform.cpp pch ../../test/build//boost_unit_test_framework ; +run test_weibull.cpp ../../test/build//boost_unit_test_framework ; +run test_zeta.cpp test_instances//test_instances ../../test/build//boost_unit_test_framework pch_light ; -run test_policy.cpp ../../test/build//boost_test_exec_monitor ; -run test_policy_2.cpp ../../test/build//boost_test_exec_monitor ; -run test_policy_3.cpp ../../test/build//boost_test_exec_monitor ; -run test_policy_4.cpp ../../test/build//boost_test_exec_monitor ; -run test_policy_5.cpp ../../test/build//boost_test_exec_monitor ; -run test_policy_6.cpp ../../test/build//boost_test_exec_monitor ; -run test_policy_7.cpp ../../test/build//boost_test_exec_monitor ; -run test_policy_8.cpp ../../test/build//boost_test_exec_monitor ; -run test_policy_sf.cpp ../../test/build//boost_test_exec_monitor ; +run test_policy.cpp ../../test/build//boost_unit_test_framework ; +run test_policy_2.cpp ../../test/build//boost_unit_test_framework ; +run test_policy_3.cpp ../../test/build//boost_unit_test_framework ; +run test_policy_4.cpp ../../test/build//boost_unit_test_framework ; +run test_policy_5.cpp ../../test/build//boost_unit_test_framework ; +run test_policy_6.cpp ../../test/build//boost_unit_test_framework ; +run test_policy_7.cpp ../../test/build//boost_unit_test_framework ; +run test_policy_8.cpp ../../test/build//boost_unit_test_framework ; +run test_policy_sf.cpp ../../test/build//boost_unit_test_framework ; run test_tr1.cpp ../build//boost_math_tr1 ../build//boost_math_tr1f ../build//boost_math_c99 ../build//boost_math_c99f - ../../test/build//boost_test_exec_monitor + ../../test/build//boost_unit_test_framework ; run test_tr1.cpp ../build//boost_math_tr1l ../build//boost_math_c99l - ../../test/build//boost_test_exec_monitor + ../../test/build//boost_unit_test_framework : : : TEST_LD=1 [ check-target-builds ../config//has_long_double_support : : no ] @@ -681,7 +681,7 @@ run test_tr1.c ../build//boost_math_tr1f ../build//boost_math_c99 ../build//boost_math_c99f - ../../test/build//boost_test_exec_monitor + ../../test/build//boost_unit_test_framework : : : #requirements : test_tr1_c @@ -690,7 +690,7 @@ run test_tr1.c run test_tr1.c ../build//boost_math_tr1l ../build//boost_math_c99l - ../../test/build//boost_test_exec_monitor + ../../test/build//boost_unit_test_framework : : : TEST_LD=1 [ check-target-builds ../config//has_long_double_support : : no ] @@ -698,7 +698,7 @@ run test_tr1.c test_tr1_c_long_double ; -run test_long_double_support.cpp ../../test/build//boost_test_exec_monitor +run test_long_double_support.cpp ../../test/build//boost_unit_test_framework : : : [ check-target-builds ../config//has_long_double_support : : no ] ; run compile_test/compl_abs_incl_test.cpp compile_test/main.cpp ; @@ -815,13 +815,13 @@ run ../quaternion/quaternion_mult_incl_test.cpp ../../test/build//boost_unit_test_framework ; -run test_legacy_nonfinite.cpp ../../test/build//boost_test_exec_monitor ; -run test_basic_nonfinite.cpp ../../test/build//boost_test_exec_monitor ; -run test_lexical_cast.cpp ../../test/build//boost_test_exec_monitor ; -run test_nonfinite_trap.cpp ../../test/build//boost_test_exec_monitor ; -run test_signed_zero.cpp ../../test/build//boost_test_exec_monitor ; +run test_legacy_nonfinite.cpp ../../test/build//boost_unit_test_framework ; +run test_basic_nonfinite.cpp ../../test/build//boost_unit_test_framework ; +run test_lexical_cast.cpp ../../test/build//boost_unit_test_framework ; +run test_nonfinite_trap.cpp ../../test/build//boost_unit_test_framework ; +run test_signed_zero.cpp ../../test/build//boost_unit_test_framework ; -run complex_test.cpp ../../test/build//boost_test_exec_monitor ; +run complex_test.cpp ../../test/build//boost_unit_test_framework ; compile multiprc_concept_check_1.cpp : off ; compile multiprc_concept_check_2.cpp : off ; diff --git a/test/acosh_test.hpp b/test/acosh_test.hpp index c415a3f3a..906025c3e 100644 --- a/test/acosh_test.hpp +++ b/test/acosh_test.hpp @@ -10,7 +10,7 @@ #include #include - +#define BOOST_TEST_MAiN #include diff --git a/test/asinh_test.hpp b/test/asinh_test.hpp index 6977de16b..98aa55576 100644 --- a/test/asinh_test.hpp +++ b/test/asinh_test.hpp @@ -10,7 +10,7 @@ #include #include - +#define BOOST_TEST_MAiN #include diff --git a/test/atanh_test.hpp b/test/atanh_test.hpp index f8aef3ed7..77e973af0 100644 --- a/test/atanh_test.hpp +++ b/test/atanh_test.hpp @@ -10,7 +10,7 @@ #include //#include - +#define BOOST_TEST_MAiN #include diff --git a/test/complex_test.cpp b/test/complex_test.cpp index c73ab2ca6..6d4cfe97e 100644 --- a/test/complex_test.cpp +++ b/test/complex_test.cpp @@ -3,8 +3,8 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -#include -#include +#define BOOST_TEST_MAIN +#include #include #include #include @@ -896,7 +896,7 @@ void test_boundaries() } -int test_main(int, char*[]) +BOOST_AUTO_TEST_CASE( test_main ) { std::cout << "Running complex trig sanity checks for type float." << std::endl; test_inverse_trig(float(0)); @@ -915,7 +915,6 @@ int test_main(int, char*[]) std::cout << "Running complex trig boundary and accuracy tests." << std::endl; test_boundaries(); - return 0; } diff --git a/test/hypot_test.cpp b/test/hypot_test.cpp index 3498a449a..5575cdd6e 100644 --- a/test/hypot_test.cpp +++ b/test/hypot_test.cpp @@ -6,7 +6,8 @@ #include #define BOOST_MATH_OVERFLOW_ERROR_POLICY ignore_error -#include +#define BOOST_TEST_MAIN +#include #include #include @@ -121,10 +122,9 @@ void test_spots() } } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; test_boundaries(); test_spots(); - return 0; } diff --git a/test/log1p_expm1_test.cpp b/test/log1p_expm1_test.cpp index 015758368..c3b1e97c9 100644 --- a/test/log1p_expm1_test.cpp +++ b/test/log1p_expm1_test.cpp @@ -12,7 +12,8 @@ #define BOOST_MATH_OVERFLOW_ERROR_POLICY ignore_error #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include "log1p_expm1_test.hpp" @@ -66,7 +67,7 @@ void expected_results() } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); BOOST_MATH_CONTROL_FP; @@ -88,6 +89,5 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; } diff --git a/test/pch.hpp b/test/pch.hpp index c7b9b7ad1..694f6829c 100644 --- a/test/pch.hpp +++ b/test/pch.hpp @@ -6,8 +6,6 @@ #ifdef BOOST_BUILD_PCH_ENABLED #define BOOST_MATH_OVERFLOW_ERROR_POLICY ignore_error -#include -#include #include #include #include diff --git a/test/pch_light.hpp b/test/pch_light.hpp index 16b253522..22856abb9 100644 --- a/test/pch_light.hpp +++ b/test/pch_light.hpp @@ -6,8 +6,6 @@ #ifdef BOOST_BUILD_PCH_ENABLED #define BOOST_MATH_OVERFLOW_ERROR_POLICY ignore_error -#include -#include #include #include #include diff --git a/test/pow_test.cpp b/test/pow_test.cpp index 29fb4fffa..38274401b 100644 --- a/test/pow_test.cpp +++ b/test/pow_test.cpp @@ -11,7 +11,8 @@ #include #include -#include +#define BOOST_TEST_MAIN +#include #include #include @@ -141,7 +142,7 @@ void test_error_policy() == 456.78); } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { using namespace std; @@ -195,8 +196,6 @@ int test_main(int, char* []) test_return_types(); test_error_policy(); - - return 0; } /* diff --git a/test/powm1_sqrtp1m1_test.cpp b/test/powm1_sqrtp1m1_test.cpp index cdbb9f8f6..fa01f3585 100644 --- a/test/powm1_sqrtp1m1_test.cpp +++ b/test/powm1_sqrtp1m1_test.cpp @@ -6,7 +6,8 @@ #include #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include @@ -55,7 +56,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); BOOST_MATH_CONTROL_FP; @@ -72,7 +73,6 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; } diff --git a/test/sinc_test.hpp b/test/sinc_test.hpp index a8998b9d5..4d1caa0c8 100644 --- a/test/sinc_test.hpp +++ b/test/sinc_test.hpp @@ -14,7 +14,7 @@ #include - +#define BOOST_TEST_MAIN #include diff --git a/test/sinhc_test.hpp b/test/sinhc_test.hpp index 129f3e859..b50bd2e67 100644 --- a/test/sinhc_test.hpp +++ b/test/sinhc_test.hpp @@ -14,7 +14,7 @@ #include - +#define BOOST_TEST_MAIN #include diff --git a/test/test_airy.cpp b/test/test_airy.cpp index 4376365de..fbc60971b 100644 --- a/test/test_airy.cpp +++ b/test/test_airy.cpp @@ -6,7 +6,8 @@ #include #define BOOST_MATH_OVERFLOW_ERROR_POLICY ignore_error -#include +#define BOOST_TEST_MAIN +#include #include #include #include @@ -57,7 +58,7 @@ void test_airy(T, const char* name) } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { #ifdef TEST_GSL gsl_set_error_handler_off(); @@ -77,7 +78,6 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; } diff --git a/test/test_bernoulli.cpp b/test/test_bernoulli.cpp index 4795d7dde..dc143e5d2 100644 --- a/test/test_bernoulli.cpp +++ b/test/test_bernoulli.cpp @@ -26,7 +26,8 @@ using ::boost::math::concepts::real_concept; #include // for bernoulli_distribution using boost::math::bernoulli_distribution; -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include // for BOOST_CHECK_CLOSE_FRACTION, BOOST_CHECK_EQUAL... #include @@ -260,7 +261,7 @@ void test_spots(RealType) } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; // Check that can generate bernoulli distribution using both convenience methods: @@ -295,8 +296,7 @@ int test_main(int, char* []) test_spots(boost::math::concepts::real_concept(0.)); // Test real concept. #endif - return 0; -} // int test_main(int, char* []) +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_bessel_airy_zeros.cpp b/test/test_bessel_airy_zeros.cpp index 5a2202dfc..64f10ab2e 100644 --- a/test/test_bessel_airy_zeros.cpp +++ b/test/test_bessel_airy_zeros.cpp @@ -18,7 +18,8 @@ #include #include // for real_concept -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include @@ -59,12 +60,12 @@ treated differently than the remaining ones. So I would be most interested in various regions of order, each one tested with about 20 zeros should suffice: -• Order 219/100: This checks a region just below a critical cutoff -• Order 221/100: This checks a region just above a critical cutoff -• Order 0: Something always tends to go wrong at zero. -• Order 1/1000: A small order -• Order 71/19: Merely an intermediate order. -• Order 7001/19: A medium-large order, small enough to retain moderate efficiency of calculation. +• Order 219/100: This checks a region just below a critical cutoff +• Order 221/100: This checks a region just above a critical cutoff +• Order 0: Something always tends to go wrong at zero. +• Order 1/1000: A small order +• Order 71/19: Merely an intermediate order. +• Order 7001/19: A medium-large order, small enough to retain moderate efficiency of calculation. If we would like, we could add a few selected high zeros such as the 1000th zero for a few modest orders such as 71/19, etc. diff --git a/test/test_bessel_i.cpp b/test/test_bessel_i.cpp index f338955f8..53acf07b3 100644 --- a/test/test_bessel_i.cpp +++ b/test/test_bessel_i.cpp @@ -110,7 +110,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { #ifdef TEST_GSL gsl_set_error_handler_off(); @@ -133,7 +133,6 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; } diff --git a/test/test_bessel_i.hpp b/test/test_bessel_i.hpp index a53c49865..573208dd6 100644 --- a/test/test_bessel_i.hpp +++ b/test/test_bessel_i.hpp @@ -5,7 +5,8 @@ #define BOOST_MATH_OVERFLOW_ERROR_POLICY ignore_error #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_bessel_j.cpp b/test/test_bessel_j.cpp index 3d5612d0b..79b63df9f 100644 --- a/test/test_bessel_j.cpp +++ b/test/test_bessel_j.cpp @@ -281,7 +281,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { #ifdef TEST_GSL gsl_set_error_handler_off(); @@ -302,7 +302,6 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; } diff --git a/test/test_bessel_j.hpp b/test/test_bessel_j.hpp index adddec4ae..43a578d36 100644 --- a/test/test_bessel_j.hpp +++ b/test/test_bessel_j.hpp @@ -5,7 +5,8 @@ #define BOOST_MATH_OVERFLOW_ERROR_POLICY ignore_error #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_bessel_k.cpp b/test/test_bessel_k.cpp index 572aa2355..79f3cec7a 100644 --- a/test/test_bessel_k.cpp +++ b/test/test_bessel_k.cpp @@ -101,7 +101,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { #ifdef TEST_GSL gsl_set_error_handler_off(); @@ -124,7 +124,6 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; } diff --git a/test/test_bessel_k.hpp b/test/test_bessel_k.hpp index 10d8850a4..c3ece8d0d 100644 --- a/test/test_bessel_k.hpp +++ b/test/test_bessel_k.hpp @@ -5,7 +5,8 @@ #define BOOST_MATH_OVERFLOW_ERROR_POLICY ignore_error #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_bessel_y.cpp b/test/test_bessel_y.cpp index 7d0bf41f1..ca8cea13c 100644 --- a/test/test_bessel_y.cpp +++ b/test/test_bessel_y.cpp @@ -239,7 +239,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { #ifdef TEST_GSL gsl_set_error_handler_off(); @@ -262,7 +262,6 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; } diff --git a/test/test_bessel_y.hpp b/test/test_bessel_y.hpp index 049e8b2c9..d27e54302 100644 --- a/test/test_bessel_y.hpp +++ b/test/test_bessel_y.hpp @@ -5,7 +5,8 @@ #define BOOST_MATH_OVERFLOW_ERROR_POLICY ignore_error #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_beta.cpp b/test/test_beta.cpp index 88bd4adb1..c2b09fc28 100644 --- a/test/test_beta.cpp +++ b/test/test_beta.cpp @@ -100,7 +100,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); BOOST_MATH_CONTROL_FP; @@ -133,7 +133,6 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; } diff --git a/test/test_beta.hpp b/test/test_beta.hpp index 54042b0f3..bdb70410e 100644 --- a/test/test_beta.hpp +++ b/test/test_beta.hpp @@ -11,7 +11,8 @@ #endif #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_beta_dist.cpp b/test/test_beta_dist.cpp index dc3e2d1e0..09007332f 100644 --- a/test/test_beta_dist.cpp +++ b/test/test_beta_dist.cpp @@ -39,7 +39,8 @@ using ::boost::math::concepts::real_concept; using boost::math::beta_distribution; using boost::math::beta; -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include // for BOOST_CHECK_CLOSE_FRACTION #include "test_out_of_range.hpp" @@ -523,7 +524,7 @@ void test_spots(RealType) } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; // Check that can generate beta distribution using one convenience methods: @@ -615,8 +616,7 @@ int test_main(int, char* []) test_spots(boost::math::concepts::real_concept(0.)); // Test real concept. #endif #endif - return 0; -} // int test_main(int, char* []) +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_binomial.cpp b/test/test_binomial.cpp index 7451a2c34..45021f3cd 100644 --- a/test/test_binomial.cpp +++ b/test/test_binomial.cpp @@ -33,7 +33,8 @@ using ::boost::math::concepts::real_concept; #include // for binomial_distribution using boost::math::binomial_distribution; -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include // for BOOST_CHECK_CLOSE #include "table_type.hpp" @@ -717,7 +718,7 @@ void test_spots(RealType T) } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; // Check that can generate binomial distribution using one convenience methods: @@ -751,8 +752,7 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_binomial_coeff.cpp b/test/test_binomial_coeff.cpp index 9aa28ee1c..622e3406c 100644 --- a/test/test_binomial_coeff.cpp +++ b/test/test_binomial_coeff.cpp @@ -111,7 +111,7 @@ void test_spots(T, const char* name) BOOST_CHECK_CLOSE(boost::math::binomial_coefficient(300, 275), static_cast(1.953265141442868389822364184842211512000000e36L), tolerance); } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); BOOST_MATH_CONTROL_FP; @@ -136,7 +136,6 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; } diff --git a/test/test_binomial_coeff.hpp b/test/test_binomial_coeff.hpp index c829944f2..033c38591 100644 --- a/test/test_binomial_coeff.hpp +++ b/test/test_binomial_coeff.hpp @@ -5,7 +5,8 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_carlson.cpp b/test/test_carlson.cpp index be162df8a..1cf840883 100644 --- a/test/test_carlson.cpp +++ b/test/test_carlson.cpp @@ -112,7 +112,7 @@ void expected_results() } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); BOOST_MATH_CONTROL_FP; @@ -132,8 +132,6 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - - return 0; } /* diff --git a/test/test_carlson.hpp b/test/test_carlson.hpp index ac8986891..e7515215e 100644 --- a/test/test_carlson.hpp +++ b/test/test_carlson.hpp @@ -5,7 +5,8 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_cauchy.cpp b/test/test_cauchy.cpp index ab96d4fd2..610c85a39 100644 --- a/test/test_cauchy.cpp +++ b/test/test_cauchy.cpp @@ -25,7 +25,8 @@ #include "test_out_of_range.hpp" -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include @@ -695,7 +696,7 @@ void test_spots(RealType T) } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; // Check that can generate cauchy distribution using the two convenience methods: @@ -721,8 +722,7 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) +} // BOOST_AUTO_TEST_CASE( test_main ) /* Output: diff --git a/test/test_cbrt.cpp b/test/test_cbrt.cpp index bc32e3798..8fc8150b6 100644 --- a/test/test_cbrt.cpp +++ b/test/test_cbrt.cpp @@ -73,7 +73,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); BOOST_MATH_CONTROL_FP; @@ -85,6 +85,5 @@ int test_main(int, char* []) test_cbrt(boost::math::concepts::real_concept(0.1), "real_concept"); #endif #endif - return 0; } diff --git a/test/test_cbrt.hpp b/test/test_cbrt.hpp index 91978afd3..2c824e792 100644 --- a/test/test_cbrt.hpp +++ b/test/test_cbrt.hpp @@ -5,7 +5,8 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_chi_squared.cpp b/test/test_chi_squared.cpp index 29d696244..936bfe563 100644 --- a/test/test_chi_squared.cpp +++ b/test/test_chi_squared.cpp @@ -23,7 +23,8 @@ using ::boost::math::concepts::real_concept; using boost::math::chi_squared_distribution; using boost::math::chi_squared; -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include // for BOOST_CHECK_CLOSE #include "test_out_of_range.hpp" @@ -534,7 +535,7 @@ void test_spots(RealType T) } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; // Check that can generate chi_squared distribution using the two convenience methods: @@ -552,8 +553,7 @@ int test_main(int, char* []) test_spots(boost::math::concepts::real_concept(0.)); // Test real concept. #endif #endif - return 0; -} // int test_main(int, char* []) +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_classify.cpp b/test/test_classify.cpp index 2b72bd3c7..46d33b865 100644 --- a/test/test_classify.cpp +++ b/test/test_classify.cpp @@ -11,7 +11,8 @@ #include #include #include -#include +#define BOOST_TEST_MAIN +#include #ifdef _MSC_VER #pragma warning(disable: 4127 4146) // conditional expression is constant @@ -250,7 +251,7 @@ void test_classify(T t, const char* type) #endif } -int test_main(int, char* [] ) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; // start by printing some information: @@ -279,7 +280,6 @@ int test_main(int, char* [] ) // We should test with integer types as well: test_classify(int(0), "int"); test_classify(unsigned(0), "unsigned"); - return 0; } /* diff --git a/test/test_constants.cpp b/test/test_constants.cpp index 678a46d41..1dae1309e 100644 --- a/test/test_constants.cpp +++ b/test/test_constants.cpp @@ -20,7 +20,8 @@ #endif #include // for real_concept -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include @@ -751,7 +752,7 @@ void test_real_concept_policy(const Policy&) } // template void test_spots(boost::math::concepts::real_concept) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Basic sanity-check spot values. @@ -780,8 +781,7 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_digamma.cpp b/test/test_digamma.cpp index f5b0447e8..7926e7031 100644 --- a/test/test_digamma.cpp +++ b/test/test_digamma.cpp @@ -89,7 +89,7 @@ void test_spots(T, const char* t) BOOST_CHECK_CLOSE(::boost::math::digamma(static_cast(-1.5)), static_cast(0.70315664064524318722569033366791109947350706200623L), tolerance); } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; test_spots(0.0F, "float"); @@ -114,7 +114,6 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; } diff --git a/test/test_digamma.hpp b/test/test_digamma.hpp index 40e794abb..dd7a2bc41 100644 --- a/test/test_digamma.hpp +++ b/test/test_digamma.hpp @@ -5,7 +5,8 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_dist_overloads.cpp b/test/test_dist_overloads.cpp index e75d7f0ef..b2b3d596d 100644 --- a/test/test_dist_overloads.cpp +++ b/test/test_dist_overloads.cpp @@ -12,7 +12,8 @@ #include using boost::math::normal_distribution; -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include @@ -65,7 +66,7 @@ void test_spots(RealType) } } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Basic sanity-check spot values. // (Parameter value, arbitrarily zero, only communicates the floating point type). @@ -83,8 +84,7 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_ellint_1.cpp b/test/test_ellint_1.cpp index 3b78d39d0..79e088d3d 100644 --- a/test/test_ellint_1.cpp +++ b/test/test_ellint_1.cpp @@ -79,7 +79,7 @@ void expected_results() } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); BOOST_MATH_CONTROL_FP; @@ -98,5 +98,4 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; } diff --git a/test/test_ellint_1.hpp b/test/test_ellint_1.hpp index 3d83d01be..14744b23d 100644 --- a/test/test_ellint_1.hpp +++ b/test/test_ellint_1.hpp @@ -10,7 +10,8 @@ #endif #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_ellint_2.cpp b/test/test_ellint_2.cpp index 3af1af51d..817dbf0e1 100644 --- a/test/test_ellint_2.cpp +++ b/test/test_ellint_2.cpp @@ -79,7 +79,7 @@ void expected_results() } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); BOOST_MATH_CONTROL_FP; @@ -99,5 +99,4 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; } diff --git a/test/test_ellint_2.hpp b/test/test_ellint_2.hpp index f692d4281..b104f9743 100644 --- a/test/test_ellint_2.hpp +++ b/test/test_ellint_2.hpp @@ -10,7 +10,8 @@ #endif #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_ellint_3.cpp b/test/test_ellint_3.cpp index 144a4142e..892a3f938 100644 --- a/test/test_ellint_3.cpp +++ b/test/test_ellint_3.cpp @@ -92,7 +92,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); BOOST_MATH_CONTROL_FP; @@ -110,5 +110,4 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; } diff --git a/test/test_ellint_3.hpp b/test/test_ellint_3.hpp index 9a1a5d73e..ed981448c 100644 --- a/test/test_ellint_3.hpp +++ b/test/test_ellint_3.hpp @@ -10,7 +10,8 @@ #endif #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_erf.cpp b/test/test_erf.cpp index b206ee69b..b9b428fe5 100644 --- a/test/test_erf.cpp +++ b/test/test_erf.cpp @@ -122,7 +122,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; test_spots(0.0F, "float"); @@ -151,7 +151,6 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; } /* diff --git a/test/test_erf.hpp b/test/test_erf.hpp index b639ed5c9..f166bdd1a 100644 --- a/test/test_erf.hpp +++ b/test/test_erf.hpp @@ -5,7 +5,8 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_error_handling.cpp b/test/test_error_handling.cpp index 89db25538..ae42c3887 100644 --- a/test/test_error_handling.cpp +++ b/test/test_error_handling.cpp @@ -64,7 +64,8 @@ T user_indeterminate_result_error(const char* , const char* , const T& ) #include #include #include -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include // for errno // // Define some policies: @@ -176,7 +177,7 @@ void test_error(T) BOOST_CHECK_EQUAL(errno, EDOM); } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Test error handling. // (Parameter value, arbitrarily zero, only communicates the floating point type FPT). @@ -184,8 +185,7 @@ int test_main(int, char* []) test_error(0.0); // Test double. test_error(0.0L); // Test long double. test_error(boost::math::concepts::real_concept(0.0L)); // Test concepts. - return 0; -} // int test_main(int, char* []) +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_expint.cpp b/test/test_expint.cpp index 79d39aa93..218017201 100644 --- a/test/test_expint.cpp +++ b/test/test_expint.cpp @@ -121,7 +121,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); BOOST_MATH_CONTROL_FP; @@ -155,7 +155,6 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; } diff --git a/test/test_expint.hpp b/test/test_expint.hpp index 81fb6a6b0..6f8e4bd1e 100644 --- a/test/test_expint.hpp +++ b/test/test_expint.hpp @@ -6,7 +6,8 @@ #include #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_exponential_dist.cpp b/test/test_exponential_dist.cpp index 8e03b2256..9fa255a59 100644 --- a/test/test_exponential_dist.cpp +++ b/test/test_exponential_dist.cpp @@ -12,7 +12,8 @@ #include using boost::math::exponential_distribution; -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include "test_out_of_range.hpp" @@ -263,7 +264,7 @@ void test_spots(RealType T) } } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Check that can generate exponential distribution using the two convenience methods: boost::math::exponential mycexp1(1.); // Using typedef @@ -285,8 +286,7 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_extreme_value.cpp b/test/test_extreme_value.cpp index 647bfc822..cb50b503e 100644 --- a/test/test_extreme_value.cpp +++ b/test/test_extreme_value.cpp @@ -11,7 +11,8 @@ #include using boost::math::extreme_value_distribution; -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include "test_out_of_range.hpp" @@ -193,7 +194,7 @@ void test_spots(RealType) } } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Check that can generate extreme_value distribution using the two convenience methods: @@ -216,8 +217,8 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_factorials.cpp b/test/test_factorials.cpp index 3a5d63312..e30a1b663 100644 --- a/test/test_factorials.cpp +++ b/test/test_factorials.cpp @@ -14,7 +14,8 @@ #define BOOST_MATH_OVERFLOW_ERROR_POLICY ignore_error #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include @@ -286,7 +287,7 @@ void test_spots(T) } } // template void test_spots(T) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; test_spots(0.0F); @@ -321,7 +322,7 @@ int test_main(int, char* []) - return 0; + } /* diff --git a/test/test_find_location.cpp b/test/test_find_location.cpp index 3453c35d5..18cb3e30d 100644 --- a/test/test_find_location.cpp +++ b/test/test_find_location.cpp @@ -29,7 +29,8 @@ #include using boost::math::policies::policy; -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include // for BOOST_CHECK_CLOSE_FRACTION, BOOST_CHECK_EQUAL... #include @@ -136,7 +137,7 @@ void test_spots(RealType) } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Basic sanity-check spot values. @@ -154,8 +155,8 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_find_scale.cpp b/test/test_find_scale.cpp index 678e2c053..b71eedf36 100644 --- a/test/test_find_scale.cpp +++ b/test/test_find_scale.cpp @@ -29,7 +29,8 @@ #include using boost::math::policies::policy; -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include // for BOOST_CHECK_CLOSE_FRACTION, BOOST_CHECK_EQUAL... #include @@ -170,7 +171,7 @@ void test_spots(RealType) } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Basic sanity-check spot values. @@ -188,8 +189,8 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_fisher_f.cpp b/test/test_fisher_f.cpp index a664e7d05..e74ebfdf3 100644 --- a/test/test_fisher_f.cpp +++ b/test/test_fisher_f.cpp @@ -14,7 +14,8 @@ using ::boost::math::concepts::real_concept; #include // for fisher_f_distribution using boost::math::fisher_f_distribution; -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include // for BOOST_CHECK_CLOSE #include "test_out_of_range.hpp" @@ -502,7 +503,7 @@ void test_spots(RealType) check_out_of_range >(2, 3); } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Check that can generate fisher distribution using the two convenience methods: @@ -521,8 +522,8 @@ int test_main(int, char* []) test_spots(boost::math::concepts::real_concept(0.)); // Test real concept. #endif #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_gamma.cpp b/test/test_gamma.cpp index 3d9b5dde9..7d9943110 100644 --- a/test/test_gamma.cpp +++ b/test/test_gamma.cpp @@ -302,7 +302,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); BOOST_MATH_CONTROL_FP; @@ -333,7 +333,7 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; + } diff --git a/test/test_gamma.hpp b/test/test_gamma.hpp index d17f800b7..6dea1150b 100644 --- a/test/test_gamma.hpp +++ b/test/test_gamma.hpp @@ -8,7 +8,8 @@ #include #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_gamma_dist.cpp b/test/test_gamma_dist.cpp index c213e64c5..b0adf7d76 100644 --- a/test/test_gamma_dist.cpp +++ b/test/test_gamma_dist.cpp @@ -18,7 +18,8 @@ #include // include directory libs/math/src/tr1/ is needed. #include // for real_concept -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include @@ -223,7 +224,7 @@ void test_spots(RealType) } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Basic sanity-check spot values. // (Parameter value, arbitrarily zero, only communicates the floating point type). @@ -241,8 +242,8 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_geometric.cpp b/test/test_geometric.cpp index 611752212..e908eb7cd 100644 --- a/test/test_geometric.cpp +++ b/test/test_geometric.cpp @@ -35,7 +35,8 @@ using boost::math::geometric; // using typedef for geometric_distribution // for some comparisons. -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include // for BOOST_CHECK_CLOSE_FRACTION #include "test_out_of_range.hpp" @@ -748,7 +749,7 @@ if(std::numeric_limits::is_specialized) return; } // template void test_spots(RealType) // Any floating-point type RealType. -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Check that can generate geometric distribution using the two convenience methods: using namespace boost::math; @@ -790,8 +791,8 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_hankel.cpp b/test/test_hankel.cpp index 4c9fe75b6..05e176698 100644 --- a/test/test_hankel.cpp +++ b/test/test_hankel.cpp @@ -6,7 +6,8 @@ #include #define BOOST_MATH_OVERFLOW_ERROR_POLICY ignore_error -#include +#define BOOST_TEST_MAIN +#include #include #include #include @@ -119,7 +120,7 @@ typedef boost::math::policies::policy< template std::complex boost::math::cyl_hankel_1(double, double, const pol3&); -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { #ifdef TEST_GSL gsl_set_error_handler_off(); @@ -138,7 +139,7 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; + } diff --git a/test/test_hermite.cpp b/test/test_hermite.cpp index e111704be..edf6726f9 100644 --- a/test/test_hermite.cpp +++ b/test/test_hermite.cpp @@ -77,7 +77,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; @@ -109,7 +109,7 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; + } diff --git a/test/test_hermite.hpp b/test/test_hermite.hpp index bb1fdba2e..4046b8ef3 100644 --- a/test/test_hermite.hpp +++ b/test/test_hermite.hpp @@ -12,7 +12,8 @@ #endif #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_hypergeometric_dist.cpp b/test/test_hypergeometric_dist.cpp index 6484f69e2..3f478119c 100644 --- a/test/test_hypergeometric_dist.cpp +++ b/test/test_hypergeometric_dist.cpp @@ -11,7 +11,8 @@ #include // for real_concept #include -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include #include @@ -478,7 +479,7 @@ void test_spots(RealType /*T*/, const char* type_name) } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); // Basic sanity-check spot values. @@ -497,6 +498,6 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) diff --git a/test/test_ibeta.cpp b/test/test_ibeta.cpp index 166b5a5a5..758094416 100644 --- a/test/test_ibeta.cpp +++ b/test/test_ibeta.cpp @@ -278,7 +278,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); BOOST_MATH_CONTROL_FP; @@ -323,7 +323,7 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; + } diff --git a/test/test_ibeta.hpp b/test/test_ibeta.hpp index c363b0ee8..2bc196ed4 100644 --- a/test/test_ibeta.hpp +++ b/test/test_ibeta.hpp @@ -5,7 +5,8 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_ibeta_inv.cpp b/test/test_ibeta_inv.cpp index 949583201..e1b808d57 100644 --- a/test/test_ibeta_inv.cpp +++ b/test/test_ibeta_inv.cpp @@ -171,7 +171,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; expected_results(); @@ -214,7 +214,7 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; + } diff --git a/test/test_ibeta_inv.hpp b/test/test_ibeta_inv.hpp index 70807b8e6..fdd013d57 100644 --- a/test/test_ibeta_inv.hpp +++ b/test/test_ibeta_inv.hpp @@ -5,7 +5,8 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_ibeta_inv_ab.cpp b/test/test_ibeta_inv_ab.cpp index 1cab840e6..105c9f478 100644 --- a/test/test_ibeta_inv_ab.cpp +++ b/test/test_ibeta_inv_ab.cpp @@ -98,7 +98,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); #ifdef TEST_GSL @@ -126,6 +126,6 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; + } diff --git a/test/test_ibeta_inv_ab.hpp b/test/test_ibeta_inv_ab.hpp index 0c4aa5fb9..e99e39403 100644 --- a/test/test_ibeta_inv_ab.hpp +++ b/test/test_ibeta_inv_ab.hpp @@ -7,7 +7,8 @@ #define BOOST_MATH_OVERFLOW_ERROR_POLICY ignore_error #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_igamma.cpp b/test/test_igamma.cpp index 70030cef0..72c95bbf0 100644 --- a/test/test_igamma.cpp +++ b/test/test_igamma.cpp @@ -323,7 +323,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); BOOST_MATH_CONTROL_FP; @@ -356,7 +356,7 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; + } diff --git a/test/test_igamma.hpp b/test/test_igamma.hpp index 433e1de25..9a36d6d5b 100644 --- a/test/test_igamma.hpp +++ b/test/test_igamma.hpp @@ -8,7 +8,8 @@ #include #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_igamma_inv.cpp b/test/test_igamma_inv.cpp index 4284adcdc..541e3303d 100644 --- a/test/test_igamma_inv.cpp +++ b/test/test_igamma_inv.cpp @@ -174,7 +174,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); BOOST_MATH_CONTROL_FP; @@ -223,7 +223,7 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; + } diff --git a/test/test_igamma_inv.hpp b/test/test_igamma_inv.hpp index 78e336074..cbf1a5fba 100644 --- a/test/test_igamma_inv.hpp +++ b/test/test_igamma_inv.hpp @@ -6,7 +6,8 @@ #include #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_igamma_inva.cpp b/test/test_igamma_inva.cpp index df327ee1b..89100dcbf 100644 --- a/test/test_igamma_inva.cpp +++ b/test/test_igamma_inva.cpp @@ -101,7 +101,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); BOOST_MATH_CONTROL_FP; @@ -131,7 +131,7 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; + } diff --git a/test/test_igamma_inva.hpp b/test/test_igamma_inva.hpp index 59edf09b7..edd53385b 100644 --- a/test/test_igamma_inva.hpp +++ b/test/test_igamma_inva.hpp @@ -8,7 +8,8 @@ #include #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_inv_hyp.cpp b/test/test_inv_hyp.cpp index 765a4828c..fd3c2335e 100644 --- a/test/test_inv_hyp.cpp +++ b/test/test_inv_hyp.cpp @@ -9,7 +9,8 @@ #include #include #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include @@ -250,7 +251,7 @@ void test_spots(T, const char* t) BOOST_CHECK_CLOSE(::boost::math::atanh(static_cast(-0.5)), static_cast(-0.549306144334054845697622618461262852323745278911374725867347L), tolerance); } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); BOOST_MATH_CONTROL_FP; @@ -282,7 +283,7 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; + } diff --git a/test/test_inverse_chi_squared.cpp b/test/test_inverse_chi_squared.cpp index 0c67414c9..0474fb457 100644 --- a/test/test_inverse_chi_squared.cpp +++ b/test/test_inverse_chi_squared.cpp @@ -20,7 +20,8 @@ using ::boost::math::concepts::real_concept; //#include -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include // for BOOST_CHECK_CLOSE_FRACTION #include // for inverse_chisquared_distribution @@ -305,7 +306,7 @@ void test_spots(RealType) } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; @@ -497,8 +498,8 @@ int test_main(int, char* []) #endif /* */ - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_inverse_chi_squared_distribution.cpp b/test/test_inverse_chi_squared_distribution.cpp index cb3a20c6a..0e31dda08 100644 --- a/test/test_inverse_chi_squared_distribution.cpp +++ b/test/test_inverse_chi_squared_distribution.cpp @@ -18,7 +18,8 @@ using ::boost::math::concepts::real_concept; //#include -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include // for BOOST_CHECK_CLOSE_FRACTION #include "test_out_of_range.hpp" @@ -304,7 +305,7 @@ void test_spots(RealType) } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; @@ -496,8 +497,8 @@ int test_main(int, char* []) #endif /* */ - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_inverse_gamma_distribution.cpp b/test/test_inverse_gamma_distribution.cpp index c0cbb8a4c..67e0c0354 100644 --- a/test/test_inverse_gamma_distribution.cpp +++ b/test/test_inverse_gamma_distribution.cpp @@ -18,7 +18,8 @@ using ::boost::math::concepts::real_concept; //#include -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include // for BOOST_CHECK_CLOSE_FRACTION #include "test_out_of_range.hpp" @@ -327,7 +328,7 @@ void test_spots(RealType) check_out_of_range >(1, 1); } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; @@ -412,8 +413,8 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_inverse_gaussian.cpp b/test/test_inverse_gaussian.cpp index 9ae4f485d..1aef96687 100644 --- a/test/test_inverse_gaussian.cpp +++ b/test/test_inverse_gaussian.cpp @@ -17,7 +17,8 @@ //#include // include directory libs/math/src/tr1/ is needed. #include // for real_concept -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include @@ -161,7 +162,7 @@ void test_spots(RealType) static_cast(10), tolerance); } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { using boost::math::inverse_gaussian; using boost::math::inverse_gaussian_distribution; @@ -334,8 +335,8 @@ int test_main(int, char* []) "to pass." << std::cout; #endif /* */ - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_jacobi.cpp b/test/test_jacobi.cpp index 31339bc66..a76e371c8 100644 --- a/test/test_jacobi.cpp +++ b/test/test_jacobi.cpp @@ -112,7 +112,7 @@ void expected_results() } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); BOOST_MATH_CONTROL_FP; @@ -131,5 +131,5 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; + } diff --git a/test/test_jacobi.hpp b/test/test_jacobi.hpp index 08567f539..d8c05e589 100644 --- a/test/test_jacobi.hpp +++ b/test/test_jacobi.hpp @@ -10,7 +10,8 @@ #endif #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_laguerre.cpp b/test/test_laguerre.cpp index e5838f962..d66ab52e9 100644 --- a/test/test_laguerre.cpp +++ b/test/test_laguerre.cpp @@ -136,7 +136,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; @@ -166,7 +166,7 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; + } diff --git a/test/test_laguerre.hpp b/test/test_laguerre.hpp index 7f8dcacff..48a91d3be 100644 --- a/test/test_laguerre.hpp +++ b/test/test_laguerre.hpp @@ -5,7 +5,8 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_legendre.cpp b/test/test_legendre.cpp index 5b9d3da5b..4558945dc 100644 --- a/test/test_legendre.cpp +++ b/test/test_legendre.cpp @@ -178,7 +178,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; test_spots(0.0F, "float"); @@ -203,7 +203,7 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; + } diff --git a/test/test_legendre.hpp b/test/test_legendre.hpp index 3f5a2fd06..3831a6e96 100644 --- a/test/test_legendre.hpp +++ b/test/test_legendre.hpp @@ -9,7 +9,8 @@ #endif #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_logistic_dist.cpp b/test/test_logistic_dist.cpp index 6132eed88..f61684d22 100644 --- a/test/test_logistic_dist.cpp +++ b/test/test_logistic_dist.cpp @@ -11,7 +11,8 @@ #include using boost::math::logistic_distribution; -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include "test_out_of_range.hpp" @@ -315,7 +316,7 @@ void test_spots(RealType T) } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Check that can generate logistic distribution using the two convenience methods: boost::math::logistic mycexp1(1.); // Using typedef @@ -337,6 +338,6 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) diff --git a/test/test_lognormal.cpp b/test/test_lognormal.cpp index 72616cbba..22260ee2e 100644 --- a/test/test_lognormal.cpp +++ b/test/test_lognormal.cpp @@ -9,7 +9,8 @@ // test_lognormal.cpp #include // for real_concept -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include @@ -260,7 +261,7 @@ void test_spots(RealType) } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Check that can generate lognormal distribution using the two convenience methods: @@ -290,8 +291,8 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* Running 1 test case... diff --git a/test/test_long_double_support.cpp b/test/test_long_double_support.cpp index 8209ca631..1bec16ced 100644 --- a/test/test_long_double_support.cpp +++ b/test/test_long_double_support.cpp @@ -9,7 +9,8 @@ #include #include -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include #include @@ -204,7 +205,7 @@ void test_spots() } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); std::cout << "Running tests with BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS " @@ -218,6 +219,6 @@ int test_main(int, char* []) // (Parameter value, arbitrarily zero, only communicates the floating point type). test_spots(); // Test long double. - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) diff --git a/test/test_minima.cpp b/test/test_minima.cpp index f7cc2a5e9..68761a4f4 100644 --- a/test/test_minima.cpp +++ b/test/test_minima.cpp @@ -8,7 +8,8 @@ #include #include -#include +#define BOOST_TEST_MAIN +#include #include #include @@ -48,14 +49,14 @@ void test_minima(T, const char* /* name */) BOOST_CHECK_CLOSE(m.first, T(1.461632), T(0.1)); } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { test_minima(0.1f, "float"); test_minima(0.1, "double"); #ifndef BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS test_minima(0.1L, "long double"); #endif - return 0; + } diff --git a/test/test_nc_beta.cpp b/test/test_nc_beta.cpp index 9986758a6..e03542c0b 100644 --- a/test/test_nc_beta.cpp +++ b/test/test_nc_beta.cpp @@ -26,7 +26,8 @@ #include // for real_concept #include // for chi_squared_distribution #include // for poisson_distribution -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include #include #include // for BOOST_CHECK_CLOSE @@ -427,7 +428,7 @@ void test_accuracy(T, const char* type_name) #endif } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; // Basic sanity-check spot values. @@ -466,6 +467,6 @@ int test_main(int, char* []) #endif #endif #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) diff --git a/test/test_nc_chi_squared.cpp b/test/test_nc_chi_squared.cpp index cccddbb78..c61f443d4 100644 --- a/test/test_nc_chi_squared.cpp +++ b/test/test_nc_chi_squared.cpp @@ -23,7 +23,8 @@ #include // for real_concept #include // for chi_squared_distribution #include // for chi_squared_distribution -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include #include #include // for BOOST_CHECK_CLOSE @@ -518,7 +519,7 @@ void test_accuracy(T, const char* type_name) quantile_sanity_check(nccs_big, type_name, "Non Central Chi Squared, large parameters"); } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; // Basic sanity-check spot values. @@ -557,7 +558,7 @@ int test_main(int, char* []) #endif #endif #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) diff --git a/test/test_nc_f.cpp b/test/test_nc_f.cpp index ccb18012d..5116e03fd 100644 --- a/test/test_nc_f.cpp +++ b/test/test_nc_f.cpp @@ -22,7 +22,8 @@ #include // for real_concept #include // for chi_squared_distribution -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include #include #include // for BOOST_CHECK_CLOSE @@ -294,7 +295,7 @@ void test_spots(RealType) BOOST_CHECK_THROW(quantile(boost::math::non_central_f_distribution(1, 1, 1), 2), std::domain_error); } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; // Basic sanity-check spot values. @@ -309,6 +310,6 @@ int test_main(int, char* []) #endif #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) diff --git a/test/test_nc_t.cpp b/test/test_nc_t.cpp index 6515e7a8e..9ce0d6af6 100644 --- a/test/test_nc_t.cpp +++ b/test/test_nc_t.cpp @@ -25,7 +25,8 @@ #include // for chi_squared_distribution. #include // for normal distribution (for comparison). -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include #include #include // for BOOST_CHECK_CLOSE @@ -798,7 +799,7 @@ void test_ignore_policy(RealType) } // template void test_ignore_policy(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; // Basic sanity-check spot values. @@ -843,8 +844,8 @@ int test_main(int, char* []) test_big_df(0.F); // float test_big_df(0.); // double - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_negative_binomial.cpp b/test/test_negative_binomial.cpp index 536b38f5d..fadf3b4b7 100644 --- a/test/test_negative_binomial.cpp +++ b/test/test_negative_binomial.cpp @@ -35,7 +35,8 @@ using boost::math::negative_binomial_distribution; #include using boost::math::lgamma; // log gamma -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include // for BOOST_CHECK_CLOSE #include "table_type.hpp" #include "test_out_of_range.hpp" @@ -798,7 +799,7 @@ if(std::numeric_limits::is_specialized) return; } // template void test_spots(RealType) // Any floating-point type RealType. -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Check that can generate negative_binomial distribution using the two convenience methods: using namespace boost::math; @@ -839,8 +840,8 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_next.cpp b/test/test_next.cpp index ea24d2d0b..9d2e66243 100644 --- a/test/test_next.cpp +++ b/test/test_next.cpp @@ -6,7 +6,8 @@ #include #include -#include +#define BOOST_TEST_MAIN +#include #include #include @@ -148,7 +149,7 @@ void test_values(const T& val, const char* name) } } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { test_values(1.0f, "float"); test_values(1.0, "double"); @@ -181,7 +182,7 @@ int test_main(int, char* []) test_values(1.0f, "float"); test_values(1.0, "double"); #endif - return 0; + } diff --git a/test/test_normal.cpp b/test/test_normal.cpp index 9b1cc454e..f4443feff 100644 --- a/test/test_normal.cpp +++ b/test/test_normal.cpp @@ -24,7 +24,8 @@ #endif #include // for real_concept -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include @@ -292,7 +293,7 @@ void test_spots(RealType) BOOST_CHECK_THROW(quantile(normal_distribution(0, 1), 2), std::domain_error); } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Check that can generate normal distribution using the two convenience methods: boost::math::normal myf1(1., 2); // Using typedef @@ -320,8 +321,8 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_owens_t.cpp b/test/test_owens_t.cpp index 074375c2c..c7707e2d7 100644 --- a/test/test_owens_t.cpp +++ b/test/test_owens_t.cpp @@ -33,7 +33,8 @@ using ::boost::math::concepts::real_concept; using boost::math::owens_t; #include -#include +#define BOOST_TEST_MAIN +#include #include #include @@ -267,7 +268,7 @@ void test_owens_t(T, const char* name) } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; @@ -308,8 +309,8 @@ int test_main(int, char* []) test_owens_t(boost::multiprecision::cpp_dec_float_50(0), "cpp_dec_float_50"); // Test real concept. test_owens_t(boost::multiprecision::cpp_dec_float_100(0), "cpp_dec_float_100"); // Test real concept. #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_pareto.cpp b/test/test_pareto.cpp index 2528e7a28..0c0486e1a 100644 --- a/test/test_pareto.cpp +++ b/test/test_pareto.cpp @@ -24,7 +24,8 @@ #endif #include // for real_concept -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include @@ -247,7 +248,7 @@ void test_spots(RealType) BOOST_CHECK_THROW(quantile(pareto_distribution(1, 1), 2), std::domain_error); } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Check that can generate pareto distribution using the two convenience methods: boost::math::pareto myp1(1., 1); // Using typedef @@ -328,8 +329,8 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_poisson.cpp b/test/test_poisson.cpp index 63446831f..74133f233 100644 --- a/test/test_poisson.cpp +++ b/test/test_poisson.cpp @@ -23,7 +23,8 @@ # pragma warning(disable: 4127) // conditional expression is constant. #endif -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include // for real_concept @@ -491,7 +492,7 @@ void test_spots(RealType) // -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Check that can construct normal distribution using the two convenience methods: using namespace boost::math; @@ -607,8 +608,8 @@ int test_main(int, char* []) #endif #endif #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_policy.cpp b/test/test_policy.cpp index c8dc4ca40..05ac4b778 100644 --- a/test/test_policy.cpp +++ b/test/test_policy.cpp @@ -8,7 +8,8 @@ #include #include -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include template @@ -23,7 +24,7 @@ bool check_same(const P1&, const P2&) } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { using namespace boost::math::policies; using namespace boost; @@ -169,8 +170,8 @@ int test_main(int, char* []) BOOST_CHECK((is_same >::promote_double_type, policy<>::promote_double_type>::value)); BOOST_CHECK((is_same >::discrete_quantile_type, discrete_quantile >::value)); - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) diff --git a/test/test_policy_2.cpp b/test/test_policy_2.cpp index b3055a692..b86bad456 100644 --- a/test/test_policy_2.cpp +++ b/test/test_policy_2.cpp @@ -1,4 +1,4 @@ - +#define BOOST_TEST_MAIN // Copyright John Maddock 2007. // Use, modification and distribution are subject to the @@ -8,7 +8,7 @@ #include #include -#include // for test_main +#include // for test_main #include template @@ -23,7 +23,7 @@ bool check_same(const P1&, const P2&) } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { using namespace boost::math::policies; using namespace boost; @@ -40,8 +40,8 @@ int test_main(int, char* []) BOOST_CHECK((is_same, overflow_error >::promote_double_type, policy<>::promote_double_type>::value)); BOOST_CHECK((is_same, overflow_error >::discrete_quantile_type, policy<>::discrete_quantile_type>::value)); - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) diff --git a/test/test_policy_3.cpp b/test/test_policy_3.cpp index e6d3bf39a..4d9061a37 100644 --- a/test/test_policy_3.cpp +++ b/test/test_policy_3.cpp @@ -8,7 +8,8 @@ #include #include -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include template @@ -23,7 +24,7 @@ bool check_same(const P1&, const P2&) } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { using namespace boost::math::policies; using namespace boost; @@ -40,8 +41,8 @@ int test_main(int, char* []) BOOST_CHECK((is_same, domain_error >::promote_double_type, policy<>::promote_double_type>::value)); BOOST_CHECK((is_same, domain_error >::discrete_quantile_type, policy<>::discrete_quantile_type>::value)); - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) diff --git a/test/test_policy_4.cpp b/test/test_policy_4.cpp index 9189ac2bf..270756d95 100644 --- a/test/test_policy_4.cpp +++ b/test/test_policy_4.cpp @@ -1,4 +1,4 @@ - +#define BOOST_TEST_MAIN // Copyright John Maddock 2007. // Use, modification and distribution are subject to the @@ -8,7 +8,7 @@ #include #include -#include // for test_main +#include // for test_main #include template @@ -23,7 +23,7 @@ bool check_same(const P1&, const P2&) } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { using namespace boost::math::policies; using namespace boost; @@ -40,8 +40,8 @@ int test_main(int, char* []) BOOST_CHECK((is_same, promote_float, discrete_quantile, denorm_error, domain_error >::promote_double_type, policy<>::promote_double_type>::value)); BOOST_CHECK((is_same, promote_float, discrete_quantile, denorm_error, domain_error >::discrete_quantile_type, discrete_quantile >::value)); - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) diff --git a/test/test_policy_5.cpp b/test/test_policy_5.cpp index efc328464..ed3ee17e0 100644 --- a/test/test_policy_5.cpp +++ b/test/test_policy_5.cpp @@ -8,7 +8,8 @@ #include #include -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include template @@ -23,7 +24,7 @@ bool check_same(const P1&, const P2&) } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { using namespace boost::math::policies; using namespace boost; @@ -40,8 +41,8 @@ int test_main(int, char* []) BOOST_CHECK((is_same, promote_float, discrete_quantile, denorm_error, domain_error > >::type::promote_double_type, policy<>::promote_double_type>::value)); BOOST_CHECK((is_same, promote_float, discrete_quantile, denorm_error, domain_error > >::type::discrete_quantile_type, discrete_quantile >::value)); - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) diff --git a/test/test_policy_6.cpp b/test/test_policy_6.cpp index 2d0dd79a6..a5531d6b4 100644 --- a/test/test_policy_6.cpp +++ b/test/test_policy_6.cpp @@ -1,4 +1,4 @@ - +#define BOOST_TEST_MAIN // Copyright John Maddock 2007. // Use, modification and distribution are subject to the @@ -8,7 +8,7 @@ #include #include -#include // for test_main +#include // for test_main #include template @@ -23,7 +23,7 @@ bool check_same(const P1&, const P2&) } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { using namespace boost::math::policies; using namespace boost; @@ -40,8 +40,8 @@ int test_main(int, char* []) BOOST_CHECK((is_same, digits2<20>, promote_float, discrete_quantile, denorm_error, domain_error >::type::promote_double_type, policy<>::promote_double_type>::value)); BOOST_CHECK((is_same, digits2<20>, promote_float, discrete_quantile, denorm_error, domain_error >::type::discrete_quantile_type, discrete_quantile >::value)); - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) diff --git a/test/test_policy_7.cpp b/test/test_policy_7.cpp index cdbc8385d..99792ceae 100644 --- a/test/test_policy_7.cpp +++ b/test/test_policy_7.cpp @@ -8,7 +8,8 @@ #include #include -#include // for test_main +#define BOOST_TEST_MAIN +#include // for test_main #include template @@ -23,7 +24,7 @@ bool check_same(const P1&, const P2&) } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { using namespace boost::math::policies; using namespace boost; @@ -36,8 +37,8 @@ int test_main(int, char* []) BOOST_CHECK(check_same(make_policy(pole_error()), normalise > >::type())); BOOST_CHECK(check_same(make_policy(indeterminate_result_error()), normalise > >::type())); - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) diff --git a/test/test_policy_8.cpp b/test/test_policy_8.cpp index 2bc3994e0..96d5e4e3a 100644 --- a/test/test_policy_8.cpp +++ b/test/test_policy_8.cpp @@ -1,4 +1,4 @@ - +#define BOOST_TEST_MAIN // Copyright John Maddock 2007. // Use, modification and distribution are subject to the @@ -8,7 +8,7 @@ #include #include -#include // for test_main +#include // for test_main #include template @@ -23,7 +23,7 @@ bool check_same(const P1&, const P2&) } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { using namespace boost::math::policies; using namespace boost; @@ -43,8 +43,8 @@ int test_main(int, char* []) BOOST_CHECK(check_same(make_policy(domain_error(), pole_error(), overflow_error(), underflow_error(), denorm_error(), evaluation_error(), indeterminate_result_error(), digits2<10>(), promote_float(), promote_double(), discrete_quantile()), policy, pole_error, overflow_error, underflow_error, denorm_error, evaluation_error, indeterminate_result_error, digits2<10>, promote_float, promote_double, discrete_quantile >())); #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) diff --git a/test/test_policy_sf.cpp b/test/test_policy_sf.cpp index a54d9b0af..fdd922cbe 100644 --- a/test/test_policy_sf.cpp +++ b/test/test_policy_sf.cpp @@ -3,7 +3,8 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -#include +#define BOOST_TEST_MAIN +#include #include #include @@ -37,7 +38,7 @@ namespace test{ #undef isfinite #undef isnan -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { int i; TEST_POLICY_SF(tgamma(3.0)); @@ -130,7 +131,7 @@ int test_main(int, char* []) TEST_POLICY_SF(sph_bessel(3, 5)); TEST_POLICY_SF(sph_neumann(3, 5.0)); TEST_POLICY_SF(sph_neumann(3, 5)); - return 0; + } diff --git a/test/test_rational_instances/test_rational.hpp b/test/test_rational_instances/test_rational.hpp index cbca3c621..b3f14ca6e 100644 --- a/test/test_rational_instances/test_rational.hpp +++ b/test/test_rational_instances/test_rational.hpp @@ -8,7 +8,7 @@ #define BOOST_MATH_TEST_RATIONAL_HPP #include -#include +#include #include #include #include diff --git a/test/test_rationals.cpp b/test/test_rationals.cpp index 8a4a4ac59..83298eb97 100644 --- a/test/test_rationals.cpp +++ b/test/test_rationals.cpp @@ -4,7 +4,8 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include @@ -26,7 +27,7 @@ void test_spots(T t, const char* n) do_test_spots(t, T(0)); } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { test_spots(0.0F, "float"); test_spots(0.0, "double"); @@ -41,7 +42,7 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; + } diff --git a/test/test_rayleigh.cpp b/test/test_rayleigh.cpp index e2b9352c0..1d4067e18 100644 --- a/test/test_rayleigh.cpp +++ b/test/test_rayleigh.cpp @@ -16,7 +16,8 @@ #include using boost::math::rayleigh_distribution; -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include "test_out_of_range.hpp" @@ -213,7 +214,7 @@ void test_spots(RealType T) } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Check that can generate rayleigh distribution using the two convenience methods: boost::math::rayleigh ray1(1.); // Using typedef @@ -308,8 +309,8 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_real_concept.cpp b/test/test_real_concept.cpp index 6e1a964cd..dae2f9431 100644 --- a/test/test_real_concept.cpp +++ b/test/test_real_concept.cpp @@ -7,14 +7,15 @@ #include // for real_concept #include -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include #include -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { #ifndef BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS @@ -567,6 +568,6 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) diff --git a/test/test_remez.cpp b/test/test_remez.cpp index e80dfb899..b1ed55eb0 100644 --- a/test/test_remez.cpp +++ b/test/test_remez.cpp @@ -14,7 +14,8 @@ #endif #include -#include +#define BOOST_TEST_MAIN +#include #include #include @@ -174,11 +175,11 @@ void test_rational() std::cout << "~~~~~~~~~~~~~~~~~~~~~~~~~" << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { test_polynomial(); test_rational(); - return 0; + } diff --git a/test/test_roots.cpp b/test/test_roots.cpp index 656a30f26..244133096 100644 --- a/test/test_roots.cpp +++ b/test/test_roots.cpp @@ -5,7 +5,8 @@ #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include @@ -314,10 +315,10 @@ void test_beta(T, const char* /* name */) test_inverses(ibeta_large_data); } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { test_beta(0.1, "double"); - return 0; + } diff --git a/test/test_round.cpp b/test/test_round.cpp index 31ca653a1..4864a7530 100644 --- a/test/test_round.cpp +++ b/test/test_round.cpp @@ -6,7 +6,8 @@ #include #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include @@ -297,7 +298,7 @@ void test_round(T, const char* name ) #endif } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { test_round(0.1F, "float"); test_round(0.1, "double"); @@ -310,7 +311,7 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; + } diff --git a/test/test_sign.cpp b/test/test_sign.cpp index 2d4430c54..09b47258b 100644 --- a/test/test_sign.cpp +++ b/test/test_sign.cpp @@ -1,4 +1,4 @@ -// Copyright John Maddock 2008 +#define BOOST_TEST_MAIN// Copyright John Maddock 2008 // (C) Copyright Paul A. Bristow 2011 (added tests for changesign) // Use, modification and distribution are subject to the // Boost Software License, Version 1.0. @@ -8,7 +8,8 @@ #include // for real_concept #include -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include #include @@ -138,7 +139,7 @@ void test_spots(RealType /*T*/, const char* /*type_name*/) } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Basic sanity-check spot values. // (Parameter value, arbitrarily zero, only communicates the floating point type). @@ -156,6 +157,6 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) diff --git a/test/test_skew_normal.cpp b/test/test_skew_normal.cpp index d243f2eb9..6410c5d9a 100644 --- a/test/test_skew_normal.cpp +++ b/test/test_skew_normal.cpp @@ -17,7 +17,8 @@ //#include // include directory libs/math/src/tr1/ is needed. #include // for real_concept -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include @@ -447,7 +448,7 @@ void test_spots(RealType) } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { @@ -496,8 +497,8 @@ int test_main(int, char* []) "to pass." << std::cout; #endif /* */ - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_spherical_harmonic.cpp b/test/test_spherical_harmonic.cpp index b25229fcf..9ee2b4331 100644 --- a/test/test_spherical_harmonic.cpp +++ b/test/test_spherical_harmonic.cpp @@ -6,7 +6,8 @@ #include #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include @@ -285,7 +286,7 @@ void test_spots(T, const char* t) BOOST_CHECK_CLOSE_FRACTION(::boost::math::spherical_harmonic_i(53, 42, static_cast(-8.75), static_cast(-2.25)), static_cast(0.0002099802242493057018193798824353982612756L), tolerance); } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; test_spots(0.0F, "float"); @@ -310,7 +311,7 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; + } diff --git a/test/test_students_t.cpp b/test/test_students_t.cpp index b7235c905..5f31cefc6 100644 --- a/test/test_students_t.cpp +++ b/test/test_students_t.cpp @@ -18,7 +18,8 @@ # pragma warning (disable :4127) // conditional expression is constant. #endif -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include // for real_concept @@ -690,7 +691,7 @@ void test_spots(RealType) } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Check that can construct students_t distribution using the two convenience methods: using namespace boost::math; @@ -715,8 +716,8 @@ int test_main(int, char* []) #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_tgamma_ratio.cpp b/test/test_tgamma_ratio.cpp index b8b4519a3..209bb9fdb 100644 --- a/test/test_tgamma_ratio.cpp +++ b/test/test_tgamma_ratio.cpp @@ -117,7 +117,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { BOOST_MATH_CONTROL_FP; expected_results(); @@ -139,7 +139,7 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; + } diff --git a/test/test_tgamma_ratio.hpp b/test/test_tgamma_ratio.hpp index c4b94b0ab..48403f143 100644 --- a/test/test_tgamma_ratio.hpp +++ b/test/test_tgamma_ratio.hpp @@ -7,7 +7,8 @@ #define BOOST_MATH_OVERFLOW_ERROR_POLICY ignore_error #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/test/test_toms748_solve.cpp b/test/test_toms748_solve.cpp index 5dc249d15..3d8c2030b 100644 --- a/test/test_toms748_solve.cpp +++ b/test/test_toms748_solve.cpp @@ -5,7 +5,8 @@ #include -#include +#define BOOST_TEST_MAIN +#include #include #include @@ -161,7 +162,7 @@ void run_test(T a, T b, int id, T p1, T p2) toms748tester::reset(); } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { std::cout << std::setprecision(18); run_test(3.14/2, 3.14, 1); @@ -266,7 +267,5 @@ int test_main(int, char* []) toms748tester::reset(); BOOST_CHECK(c < 20); } - - return 0; } diff --git a/test/test_tr1.cpp b/test/test_tr1.cpp index 801f92d88..a945dc12d 100644 --- a/test/test_tr1.cpp +++ b/test/test_tr1.cpp @@ -3,7 +3,8 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -#include +#define BOOST_TEST_MAIN +#include #include #include #include // ldexpf @@ -1609,7 +1610,7 @@ void test_values(long double, const char* name) #endif } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { #ifndef TEST_LD test_values(1.0f, "float"); @@ -1619,6 +1620,6 @@ int test_main(int, char* []) test_values(1.0L, "long double"); #endif #endif - return 0; + } diff --git a/test/test_triangular.cpp b/test/test_triangular.cpp index 6f3def21b..927a8547b 100644 --- a/test/test_triangular.cpp +++ b/test/test_triangular.cpp @@ -16,7 +16,8 @@ #endif #include // for real_concept -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include @@ -528,7 +529,7 @@ void test_spots(RealType) check_out_of_range >(-1, 0, 1); } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // double toleps = std::numeric_limits::epsilon(); // 5 eps as a fraction. double tol5eps = std::numeric_limits::epsilon() * 5; // 5 eps as a fraction. @@ -680,8 +681,8 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_uniform.cpp b/test/test_uniform.cpp index b5bf004dd..d58fd51d0 100644 --- a/test/test_uniform.cpp +++ b/test/test_uniform.cpp @@ -16,7 +16,8 @@ #endif #include // for real_concept -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include @@ -371,7 +372,7 @@ void test_spots(RealType) check_out_of_range >(1, 5); } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Check that can construct uniform distribution using the two convenience methods: using namespace boost::math; @@ -429,8 +430,8 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_weibull.cpp b/test/test_weibull.cpp index caa3c4837..d8bac2ba4 100644 --- a/test/test_weibull.cpp +++ b/test/test_weibull.cpp @@ -14,7 +14,8 @@ #include // for real_concept -#include // Boost.Test +#define BOOST_TEST_MAIN +#include // Boost.Test #include #include @@ -346,7 +347,7 @@ void test_spots(RealType) check_out_of_range >(1, 1); } // template void test_spots(RealType) -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { // Check that can construct weibull distribution using the two convenience methods: @@ -370,8 +371,8 @@ int test_main(int, char* []) "to pass." << std::cout; #endif - return 0; -} // int test_main(int, char* []) + +} // BOOST_AUTO_TEST_CASE( test_main ) /* diff --git a/test/test_zeta.cpp b/test/test_zeta.cpp index 952db88b3..bd8713d4f 100644 --- a/test/test_zeta.cpp +++ b/test/test_zeta.cpp @@ -81,7 +81,7 @@ void expected_results() << BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl; } -int test_main(int, char* []) +BOOST_AUTO_TEST_CASE( test_main ) { expected_results(); BOOST_MATH_CONTROL_FP; @@ -109,7 +109,7 @@ int test_main(int, char* []) "not available at all, or because they are too inaccurate for these tests " "to pass." << std::cout; #endif - return 0; + } diff --git a/test/test_zeta.hpp b/test/test_zeta.hpp index 7fc446381..93f3056fc 100644 --- a/test/test_zeta.hpp +++ b/test/test_zeta.hpp @@ -6,7 +6,8 @@ #include #include -#include +#define BOOST_TEST_MAIN +#include #include #include #include diff --git a/tools/carlson_ellint_data.cpp b/tools/carlson_ellint_data.cpp index c88571f80..024aee8dd 100644 --- a/tools/carlson_ellint_data.cpp +++ b/tools/carlson_ellint_data.cpp @@ -7,7 +7,7 @@ #include //#include #include -#include +#include #include #include #include @@ -100,7 +100,7 @@ boost::math::tuple #include -#include +#include #include #include @@ -26,7 +26,7 @@ float truncate_to_float(boost::math::ntl::RR r) return force_truncate(&f); } -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { boost::math::ntl::RR::SetPrecision(1000); boost::math::ntl::RR::SetOutputPrecision(40); diff --git a/tools/ellint_e_data.cpp b/tools/ellint_e_data.cpp index f2b83c555..89da37855 100644 --- a/tools/ellint_e_data.cpp +++ b/tools/ellint_e_data.cpp @@ -5,7 +5,7 @@ #include #include -#include +#include #include #include #include @@ -21,7 +21,7 @@ T ellint_e_data(T k) return ellint_2(k); } -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { using namespace boost::math::tools; diff --git a/tools/ellint_f_data.cpp b/tools/ellint_f_data.cpp index eb909e308..cd71cf8c7 100644 --- a/tools/ellint_f_data.cpp +++ b/tools/ellint_f_data.cpp @@ -5,7 +5,7 @@ #include #include -#include +#include #include #include #include @@ -31,7 +31,7 @@ T ellint_f_data(T phi, T k) return ellint_1(k, phi); } -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { using namespace boost::math::tools; diff --git a/tools/ellint_k_data.cpp b/tools/ellint_k_data.cpp index e239b650c..cee63ad88 100644 --- a/tools/ellint_k_data.cpp +++ b/tools/ellint_k_data.cpp @@ -5,7 +5,7 @@ #include #include -#include +#include #include #include #include @@ -21,7 +21,7 @@ T ellint_k_data(T k) return ellint_1(k); } -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { using namespace boost::math::tools; diff --git a/tools/ellint_pi2_data.cpp b/tools/ellint_pi2_data.cpp index 9bde56feb..526966bda 100644 --- a/tools/ellint_pi2_data.cpp +++ b/tools/ellint_pi2_data.cpp @@ -6,7 +6,7 @@ #include //#include #include -#include +#include #include #include #include @@ -17,7 +17,7 @@ using namespace boost::math::tools; using namespace boost::math; using namespace std; -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { using namespace boost::math::tools; diff --git a/tools/ellint_pi3_data.cpp b/tools/ellint_pi3_data.cpp index d77d81901..93045506a 100644 --- a/tools/ellint_pi3_data.cpp +++ b/tools/ellint_pi3_data.cpp @@ -9,7 +9,7 @@ #include //#include #include -#include +#include #include #include #include @@ -33,7 +33,7 @@ boost::math::tuple generate_data(boo return boost::math::make_tuple(kr, result); } -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { using namespace boost::math::tools; diff --git a/tools/erf_data.cpp b/tools/erf_data.cpp index 99ca5e314..3a5d1bdc8 100644 --- a/tools/erf_data.cpp +++ b/tools/erf_data.cpp @@ -4,7 +4,7 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include -#include +#include #include #include // for inverses #include @@ -128,7 +128,7 @@ boost::math::tuple erfc_inv(boost::m } -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { boost::math::ntl::RR::SetPrecision(1000); boost::math::ntl::RR::SetOutputPrecision(40); diff --git a/tools/gamma_P_inva_data.cpp b/tools/gamma_P_inva_data.cpp index 1cb31464f..5e887dec7 100644 --- a/tools/gamma_P_inva_data.cpp +++ b/tools/gamma_P_inva_data.cpp @@ -4,7 +4,7 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include -#include +#include #include #include #include @@ -46,7 +46,7 @@ struct gamma_inverse_generator_a }; -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { boost::math::ntl::RR::SetPrecision(1000); boost::math::ntl::RR::SetOutputPrecision(100); diff --git a/tools/hermite_data.cpp b/tools/hermite_data.cpp index b4c6ec902..f52d05c1e 100644 --- a/tools/hermite_data.cpp +++ b/tools/hermite_data.cpp @@ -5,7 +5,7 @@ #include #include -#include +#include #include #include #include @@ -24,7 +24,7 @@ boost::math::tuple hermite_data(T n, T x) return boost::math::make_tuple(n, x, r1); } -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { using namespace boost::math::tools; diff --git a/tools/hypergeometric_dist_data.cpp b/tools/hypergeometric_dist_data.cpp index 3ed87ddea..0c92d5774 100644 --- a/tools/hypergeometric_dist_data.cpp +++ b/tools/hypergeometric_dist_data.cpp @@ -6,7 +6,7 @@ //#define BOOST_MATH_INSTRUMENT #include -#include +#include #include #include #include @@ -69,7 +69,7 @@ struct hypergeometric_generator } }; -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { boost::math::ntl::RR::SetPrecision(1000); boost::math::ntl::RR::SetOutputPrecision(100); diff --git a/tools/ibeta_data.cpp b/tools/ibeta_data.cpp index be08cc4e6..3b9058dd0 100644 --- a/tools/ibeta_data.cpp +++ b/tools/ibeta_data.cpp @@ -4,7 +4,7 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include -#include +#include #include #include #include @@ -239,7 +239,7 @@ struct beta_data_generator_int } }; -int test_main(int, char* []) +int cpp_main(int, char* []) { boost::math::ntl::RR::SetPrecision(1000); boost::math::ntl::RR::SetOutputPrecision(40); diff --git a/tools/ibeta_inv_data.cpp b/tools/ibeta_inv_data.cpp index 4f8193da6..adc9d4534 100644 --- a/tools/ibeta_inv_data.cpp +++ b/tools/ibeta_inv_data.cpp @@ -5,7 +5,7 @@ #if 1 #include -#include +#include #include #include #include @@ -57,7 +57,7 @@ struct ibeta_inv_data_generator } }; -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { boost::math::ntl::RR::SetPrecision(1000); boost::math::ntl::RR::SetOutputPrecision(100); diff --git a/tools/ibeta_invab_data.cpp b/tools/ibeta_invab_data.cpp index e51fb35ba..4aeb43c9c 100644 --- a/tools/ibeta_invab_data.cpp +++ b/tools/ibeta_invab_data.cpp @@ -4,7 +4,7 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include -#include +#include #include #include #include @@ -61,7 +61,7 @@ struct ibeta_inv_data_generator } }; -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { boost::math::ntl::RR::SetPrecision(1000); boost::math::ntl::RR::SetOutputPrecision(100); diff --git a/tools/igamma_data.cpp b/tools/igamma_data.cpp index 49ae2467b..bfc2ecae8 100644 --- a/tools/igamma_data.cpp +++ b/tools/igamma_data.cpp @@ -4,7 +4,7 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include -#include +#include #include #include #include @@ -106,7 +106,7 @@ struct gamma_inverse_generator_a }; -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { boost::math::ntl::RR::SetPrecision(1000); boost::math::ntl::RR::SetOutputPrecision(100); diff --git a/tools/inv_hyp_data.cpp b/tools/inv_hyp_data.cpp index b18396722..93b8f7683 100644 --- a/tools/inv_hyp_data.cpp +++ b/tools/inv_hyp_data.cpp @@ -4,7 +4,7 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include -#include +#include #include #include #include @@ -47,7 +47,7 @@ struct atanh_data_generator } }; -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { boost::math::ntl::RR::SetPrecision(500); boost::math::ntl::RR::SetOutputPrecision(40); diff --git a/tools/laguerre_data.cpp b/tools/laguerre_data.cpp index 47d48c894..02c821cff 100644 --- a/tools/laguerre_data.cpp +++ b/tools/laguerre_data.cpp @@ -5,7 +5,7 @@ #include #include -#include +#include #include #include #include @@ -34,7 +34,7 @@ boost::math::tuple laguerre3_data(T n, T m, T x) return boost::math::make_tuple(n, m, x, r1); } -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { using namespace boost::math::tools; diff --git a/tools/lanczos_generator.cpp b/tools/lanczos_generator.cpp index f5bf59b63..f3e105ffe 100644 --- a/tools/lanczos_generator.cpp +++ b/tools/lanczos_generator.cpp @@ -16,7 +16,7 @@ #include #include #include -#include +#include // // this is a sort of recursive include, since this file @@ -4278,7 +4278,7 @@ void find_best_lanczos(const char* name, T eps, int max_scan = 100) print_code(best, name); } -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { bool test_double(false), test_long(false), test_float(false), test_quad(false), spots(false), test_data(false); diff --git a/tools/legendre_data.cpp b/tools/legendre_data.cpp index b2d7bd4d2..9db6a7c5e 100644 --- a/tools/legendre_data.cpp +++ b/tools/legendre_data.cpp @@ -5,7 +5,7 @@ #include #include -#include +#include #include #include #include @@ -37,7 +37,7 @@ boost::math::tuple assoc_legendre_p_data(T n, T x) return boost::math::make_tuple(n, m, x, r1); } -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { using namespace boost::math::tools; diff --git a/tools/spherical_harmonic_data.cpp b/tools/spherical_harmonic_data.cpp index b6e03c19b..5344fcb58 100644 --- a/tools/spherical_harmonic_data.cpp +++ b/tools/spherical_harmonic_data.cpp @@ -5,7 +5,7 @@ #include #include -#include +#include #include #include #include @@ -45,7 +45,7 @@ boost::math::tuple spherical_harmonic_data(T i) return boost::math::make_tuple(n, m, theta, phi, r1, r2); } -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { using namespace boost::math::tools; diff --git a/tools/tgamma_ratio_data.cpp b/tools/tgamma_ratio_data.cpp index 9271d8aa0..7300c7dd0 100644 --- a/tools/tgamma_ratio_data.cpp +++ b/tools/tgamma_ratio_data.cpp @@ -4,7 +4,7 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include -#include +#include #include #include #include @@ -34,7 +34,7 @@ boost::math::ntl::RR tgamma_ratio2(const boost::math::ntl::RR& a, const boost::m } -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { boost::math::ntl::RR::SetPrecision(1000); boost::math::ntl::RR::SetOutputPrecision(40); diff --git a/tools/zeta_data.cpp b/tools/zeta_data.cpp index 96641d200..99c990dff 100644 --- a/tools/zeta_data.cpp +++ b/tools/zeta_data.cpp @@ -4,7 +4,7 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include -#include +#include #include #include #include @@ -38,7 +38,7 @@ struct zeta_data_generator2 }; -int test_main(int argc, char*argv []) +int cpp_main(int argc, char*argv []) { boost::math::ntl::RR::SetPrecision(500); boost::math::ntl::RR::SetOutputPrecision(40);