diff options
Diffstat (limited to 'bcprov/src/main/java/org/bouncycastle/crypto/prng/test/AllTests.java')
-rw-r--r-- | bcprov/src/main/java/org/bouncycastle/crypto/prng/test/AllTests.java | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/bcprov/src/main/java/org/bouncycastle/crypto/prng/test/AllTests.java b/bcprov/src/main/java/org/bouncycastle/crypto/prng/test/AllTests.java new file mode 100644 index 0000000..4c0504f --- /dev/null +++ b/bcprov/src/main/java/org/bouncycastle/crypto/prng/test/AllTests.java @@ -0,0 +1,39 @@ +package org.bouncycastle.crypto.prng.test; + +import junit.framework.Test; +import junit.framework.TestCase; +import junit.framework.TestSuite; +import org.bouncycastle.util.test.SimpleTestResult; + +public class AllTests + extends TestCase +{ + public void testCrypto() + { + org.bouncycastle.util.test.Test[] tests = RegressionTest.tests; + + for (int i = 0; i != tests.length; i++) + { + SimpleTestResult result = (SimpleTestResult)tests[i].perform(); + + if (!result.isSuccessful()) + { + fail(result.toString()); + } + } + } + + public static void main (String[] args) + { + junit.textui.TestRunner.run(suite()); + } + + public static Test suite() + { + TestSuite suite = new TestSuite("Lightweight Crypto PRNG Tests"); + + suite.addTestSuite(AllTests.class); + + return suite; + } +} |