2007-02-16 Roland Levillain <roland(a)lrde.epita.fr>
Fix test `stat' in tests/utils.
* tests/utils/tests/stat: Be more tolerant on comparisons of
floating point values for the variance.
Revert to the previous comparison for the mean.
--- 10.294/olena/tests/utils/tests/stat Thu, 15 Feb 2007 16:50:48 +0100 levill_r
(oln/u/28_stat.cc 1.5 644)
+++ 10.295/olena/tests/utils/tests/stat Fri, 16 Feb 2007 10:54:17 +0100 levill_r
(oln/u/28_stat.cc 1.6 644)
@@ -65,8 +65,11 @@
traverse(moments, src);
- if (fabs(moments.mean() - 123.32) <= 1e-1 &&
- fabs(moments.variance() - 2239.9) <= 1e-1)
+ if (fabs(moments.mean() - 123.32) <= 1e-2 &&
+ /* Be more tolerant with the variance: the result can be
+ slightly different depending on whether the test is compiled
+ with g++ or icpc. */
+ fabs(moments.variance() - 2240) <= 3)
OK_OR_FAIL;
return fail;
--- 10.294/oln.prj
+++ 10.295/oln.prj
@@ -1,15 +1,18 @@
;; -*- Prcs -*-
(Created-By-Prcs-Version 1 3 3)
(Project-Description "Olena")
-(Project-Version oln 10 294)
-(Parent-Version oln 10 293)
+(Project-Version oln 10 295)
+(Parent-Version oln 10 294)
(Version-Log "2007-02-16 Roland Levillain <roland(a)lrde.epita.fr>
- * tests/check/Makefile.runtests (check-runtests): Pass the
- C++ compiler chosen at configuration time to contrib/runtests.
+ Fix test `stat' in tests/utils.
+
+ * tests/utils/tests/stat: Be more tolerant on comparisons of
+ floating point values for the variance.
+ Revert to the previous comparison for the mean.
")
(New-Version-Log "")
-(Checkin-Time "Fri, 16 Feb 2007 10:49:36 +0100")
+(Checkin-Time "Fri, 16 Feb 2007 10:54:17 +0100")
(Checkin-Login levill_r)
;; diff-ignore tests/data/.*pbm$
;; diff-ignore .*\.pbm$
@@ -126,7 +129,7 @@
(doc/ChangeLog (oln/o/31_ChangeLog 1.38.1.7.1.5.1.14.1.24 644))
(integre/ChangeLog (oln/q/35_ChangeLog 1.12.1.2.1.56 755))
(metalic/ChangeLog (oln/q/30_ChangeLog 1.3.1.48 644))
- (olena/ChangeLog (oln/o/30_ChangeLog
1.27.1.36.1.3.1.11.1.5.1.64.1.47.1.93.1.27.2.18.1.18 644))
+ (olena/ChangeLog (oln/o/30_ChangeLog
1.27.1.36.1.3.1.11.1.5.1.64.1.47.1.93.1.27.2.18.1.19 644))
(tools/ChangeLog (oln/o/32_ChangeLog 1.10.1.20 644))
(tools/swilena/ChangeLog (oln/n/37_ChangeLog 1.7.1.55 644))
@@ -999,7 +1002,7 @@
(olena/tests/core/multiple_sources_1.cc (oln/u/25_multiple_s 1.1 644))
(olena/tests/utils/Makefile.am (oln/u/26_Makefile.a 1.2 644))
(olena/tests/utils/tests/histogram (oln/u/27_histogram. 1.2.1.6 644))
- (olena/tests/utils/tests/stat (oln/u/28_stat.cc 1.5 644))
+ (olena/tests/utils/tests/stat (oln/u/28_stat.cc 1.6 644))
(olena/tests/utils/tests/timer (oln/u/29_timer.cc 1.7 644))
(olena/tests/topo/tests/tarjan (oln/u/30_test-tarja 1.4 644))
(olena/oln/convert/abstract/conversion.hh (oln/u/31_conversion 1.6.1.1 644))