Added test to confirm that nextUniform excludes endpoints.
git-svn-id: https://svn.apache.org/repos/asf/jakarta/commons/proper/math/trunk@556485 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
5976a62dee
commit
13eb8cca17
|
@ -367,6 +367,14 @@ public class RandomDataTest extends RetryTestCase {
|
|||
testStatistic.chiSquare(expected,observed) < 10.83);
|
||||
}
|
||||
|
||||
/** test exclusive endpoints of nextUniform **/
|
||||
public void testNextUniformExclusiveEndpoints() {
|
||||
for (int i = 0; i < 1000; i++) {
|
||||
double u = randomData.nextUniform(0.99, 1);
|
||||
assertTrue(u > 0.99 && u < 1);
|
||||
}
|
||||
}
|
||||
|
||||
/** test failure modes and distribution of nextGaussian() */
|
||||
public void testNextGaussian() {
|
||||
try {
|
||||
|
|
Loading…
Reference in New Issue