diff options
-rw-r--r-- | tests/tabs.c | 5 | ||||
-rw-r--r-- | tests/tconst_euler.c | 13 | ||||
-rw-r--r-- | tests/tconst_log2.c | 13 | ||||
-rw-r--r-- | tests/tconst_pi.c | 13 | ||||
-rw-r--r-- | tests/tfrac.c | 6 | ||||
-rw-r--r-- | tests/tset.c | 5 |
6 files changed, 55 insertions, 0 deletions
diff --git a/tests/tabs.c b/tests/tabs.c index ff95d78be..9100b9c10 100644 --- a/tests/tabs.c +++ b/tests/tabs.c @@ -155,6 +155,9 @@ check_cmp(int argc, char *argv[]) mpfr_clears (x, y, (void *) 0); } +#define TEST_FUNCTION mpfr_abs +#include "tgeneric.c" + int main (int argc, char *argv[]) { @@ -164,6 +167,8 @@ main (int argc, char *argv[]) check_inexact (); check_cmp (argc, argv); + test_generic (2, 1000, 10); + tests_end_mpfr (); return 0; } diff --git a/tests/tconst_euler.c b/tests/tconst_euler.c index 6243c603e..225aac9a3 100644 --- a/tests/tconst_euler.c +++ b/tests/tconst_euler.c @@ -25,6 +25,17 @@ MA 02110-1301, USA. */ #include "mpfr-test.h" +/* Wrapper for tgeneric */ +static int +my_const_euler (mpfr_ptr x, mpfr_srcptr y, mp_rnd_t r) +{ + return mpfr_const_euler (x, r); +} + +#define RAND_FUNCTION(x) mpfr_set_ui ((x), 0, GMP_RNDN) +#define TEST_FUNCTION my_const_euler +#include "tgeneric.c" + int main (int argc, char *argv[]) { @@ -98,6 +109,8 @@ main (int argc, char *argv[]) mpfr_clear (z); mpfr_clear (t); + test_generic (2, 200, 1); + tests_end_mpfr (); return 0; } diff --git a/tests/tconst_log2.c b/tests/tconst_log2.c index 061fabcf1..d2ef8425f 100644 --- a/tests/tconst_log2.c +++ b/tests/tconst_log2.c @@ -125,6 +125,17 @@ check_cache () mpfr_clear (x); } +/* Wrapper for tgeneric */ +static int +my_const_log2 (mpfr_ptr x, mpfr_srcptr y, mp_rnd_t r) +{ + return mpfr_const_log2 (x, r); +} + +#define RAND_FUNCTION(x) mpfr_set_ui ((x), 0, GMP_RNDN) +#define TEST_FUNCTION my_const_log2 +#include "tgeneric.c" + int main (int argc, char *argv[]) { @@ -183,6 +194,8 @@ main (int argc, char *argv[]) check_large(); check_cache (); + test_generic (2, 200, 1); + tests_end_mpfr (); return 0; } diff --git a/tests/tconst_pi.c b/tests/tconst_pi.c index 1d9befc4c..64a174587 100644 --- a/tests/tconst_pi.c +++ b/tests/tconst_pi.c @@ -60,6 +60,17 @@ check_large (void) mpfr_clears (x, y, z, (void *) 0); } +/* Wrapper for tgeneric */ +static int +my_const_pi (mpfr_ptr x, mpfr_srcptr y, mp_rnd_t r) +{ + return mpfr_const_pi (x, r); +} + +#define RAND_FUNCTION(x) mpfr_set_ui ((x), 0, GMP_RNDN) +#define TEST_FUNCTION my_const_pi +#include "tgeneric.c" + int main (int argc, char *argv[]) { @@ -109,6 +120,8 @@ main (int argc, char *argv[]) check_large(); + test_generic (2, 200, 1); + tests_end_mpfr (); return 0; } diff --git a/tests/tfrac.c b/tests/tfrac.c index 2f69f2648..dab896542 100644 --- a/tests/tfrac.c +++ b/tests/tfrac.c @@ -172,6 +172,9 @@ special (void) mpfr_clear (t); } +#define TEST_FUNCTION mpfr_frac +#include "tgeneric.c" + int main (void) { @@ -223,6 +226,9 @@ main (void) mpfr_clear (ip); mpfr_clear (fp); + + test_generic (2, 1000, 10); + tests_end_mpfr (); return 0; } diff --git a/tests/tset.c b/tests/tset.c index 8435d306d..6629815e8 100644 --- a/tests/tset.c +++ b/tests/tset.c @@ -42,6 +42,9 @@ check_neg_special () mpfr_clear (x); } +#define TEST_FUNCTION mpfr_set +#include "tgeneric.c" + int main (void) { @@ -141,6 +144,8 @@ main (void) check_neg_special (); + test_generic (2, 1000, 10); + tests_end_mpfr (); return 0; } |