commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From er...@apache.org
Subject svn commit: r1097418 - /commons/proper/math/trunk/src/test/java/org/apache/commons/math/random/AbstractRandomGeneratorTest.java
Date Thu, 28 Apr 2011 11:23:07 GMT
Author: erans
Date: Thu Apr 28 11:23:06 2011
New Revision: 1097418

URL: http://svn.apache.org/viewvc?rev=1097418&view=rev
Log:
Added "@Retry" annotations.

Modified:
    commons/proper/math/trunk/src/test/java/org/apache/commons/math/random/AbstractRandomGeneratorTest.java

Modified: commons/proper/math/trunk/src/test/java/org/apache/commons/math/random/AbstractRandomGeneratorTest.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/test/java/org/apache/commons/math/random/AbstractRandomGeneratorTest.java?rev=1097418&r1=1097417&r2=1097418&view=diff
==============================================================================
--- commons/proper/math/trunk/src/test/java/org/apache/commons/math/random/AbstractRandomGeneratorTest.java
(original)
+++ commons/proper/math/trunk/src/test/java/org/apache/commons/math/random/AbstractRandomGeneratorTest.java
Thu Apr 28 11:23:06 2011
@@ -18,6 +18,10 @@ package org.apache.commons.math.random;
 
 import org.apache.commons.math.stat.Frequency;
 import org.apache.commons.math.exception.MathIllegalArgumentException;
+import org.apache.commons.math.Retry;
+import org.apache.commons.math.RetryRunner;
+
+import org.junit.runner.RunWith;
 import org.junit.Assert;
 import org.junit.Test;
 
@@ -27,6 +31,7 @@ import org.junit.Test;
  * @version $Revision$ $Date$
  */
 
+@RunWith(RetryRunner.class)
 public class AbstractRandomGeneratorTest extends RandomDataTest {
 
     protected TestRandomGenerator testGenerator = new TestRandomGenerator();
@@ -37,6 +42,7 @@ public class AbstractRandomGeneratorTest
 
     @Override
     @Test
+    @Retry(2)
     public void testNextInt() {
         try {
             testGenerator.nextInt(-1);
@@ -65,6 +71,7 @@ public class AbstractRandomGeneratorTest
 
     @Override
     @Test
+    @Retry(2)
     public void testNextLong() {
         long q1 = Long.MAX_VALUE/4;
         long q2 = 2 *  q1;
@@ -99,6 +106,7 @@ public class AbstractRandomGeneratorTest
     }
 
     @Test
+    @Retry(2)
     public void testNextBoolean() {
         long halfSampleSize = smallSampleSize / 2;
         double[] expected = {halfSampleSize, halfSampleSize};
@@ -118,6 +126,7 @@ public class AbstractRandomGeneratorTest
     }
 
     @Test
+    @Retry(2)
     public void testNextFloat() {
         Frequency freq = new Frequency();
         float val = 0;



Mime
View raw message