|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjunit.framework.Assert
junit.framework.TestCase
org.apache.commons.math.RetryTestCase
org.apache.commons.math.random.EmpiricalDistributionTest
public final class EmpiricalDistributionTest
Test cases for the EmpiricalDistribution class
Field Summary | |
---|---|
protected double[] |
dataArray
|
protected org.apache.commons.math.random.EmpiricalDistribution |
empiricalDistribution
|
protected org.apache.commons.math.random.EmpiricalDistribution |
empiricalDistribution2
|
protected java.io.File |
file
|
protected java.net.URL |
url
|
Constructor Summary | |
---|---|
EmpiricalDistributionTest(java.lang.String name)
|
Method Summary | |
---|---|
void |
setUp()
|
static junit.framework.Test |
suite()
|
void |
testBinIndexOverflow()
Test bin index overflow problem (BZ 36450) |
void |
testDoubleLoad()
Test EmpiricalDistrbution.load(double[]) using data taken from sample data file. Check that the sampleCount, mu and sigma match data in the sample data file. |
void |
testGridTooFat()
How about too fat? |
void |
testGridTooFine()
Make sure we can handle a grid size that is too fine |
void |
testLoad()
Test EmpiricalDistrbution.load() using sample data file. Check that the sampleCount, mu and sigma match data in the sample data file. |
void |
testNexFail()
Make sure exception thrown if digest getNext is attempted before loading empiricalDistribution. |
void |
testNext()
Generate 1000 random values and make sure they look OK. Note that there is a non-zero (but very small) probability that these tests will fail even if the code is working as designed. |
void |
testSerialization()
|
Methods inherited from class org.apache.commons.math.RetryTestCase |
---|
runTest |
Methods inherited from class junit.framework.TestCase |
---|
countTestCases, createResult, getName, run, run, runBare, setName, tearDown, toString |
Methods inherited from class junit.framework.Assert |
---|
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame, failSame |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected org.apache.commons.math.random.EmpiricalDistribution empiricalDistribution
protected org.apache.commons.math.random.EmpiricalDistribution empiricalDistribution2
protected java.io.File file
protected java.net.URL url
protected double[] dataArray
Constructor Detail |
---|
public EmpiricalDistributionTest(java.lang.String name)
Method Detail |
---|
public void setUp() throws java.io.IOException
setUp
in class junit.framework.TestCase
java.io.IOException
public static junit.framework.Test suite()
public void testLoad() throws java.lang.Exception
java.lang.Exception
public void testDoubleLoad() throws java.lang.Exception
java.lang.Exception
public void testNext() throws java.lang.Exception
java.lang.Exception
public void testNexFail()
public void testGridTooFine() throws java.lang.Exception
java.lang.Exception
public void testGridTooFat() throws java.lang.Exception
java.lang.Exception
public void testBinIndexOverflow() throws java.lang.Exception
java.lang.Exception
public void testSerialization()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |