diff options
author | Jan Schmidt <jan.schmidt@sun.com> | 2009-10-09 00:14:07 +0100 |
---|---|---|
committer | Jan Schmidt <jan.schmidt@sun.com> | 2009-10-09 00:14:07 +0100 |
commit | 993a29a39064e3afe070eb08e99ee50caea66242 (patch) | |
tree | c52e705c5821f73daf199f1962c313dd43cf1218 /tests | |
parent | c40cb187627e84db6adb1dcc349f31b5af0f11a9 (diff) |
check: Make the level unit test succeed on Solaris 10
Add a configure check for functional isinf() and fpclass(), and
use fpclass() where possible when isinf() is not available.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/check/elements/level.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/check/elements/level.c b/tests/check/elements/level.c index 558a1c60..e37c0225 100644 --- a/tests/check/elements/level.c +++ b/tests/check/elements/level.c @@ -256,7 +256,11 @@ GST_START_TEST (test_int16_panned) value = gst_value_list_get_value (list, 0); dB = g_value_get_double (value); GST_DEBUG ("%s[0] is %lf", fields[j], dB); - fail_if (!isinf (dB)); +#ifdef HAVE_ISINF + fail_unless (isinf (dB)); +#elif HAVE_FPCLASS + fail_unless (fpclass (dB) == FP_NINF); +#endif } /* block wave of half amplitude has -5.94 dB for rms, peak and decay */ for (j = 0; j < 3; ++j) { |