commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject commons-crypto git commit: Windows does not have /dev/random
Date Wed, 06 Jul 2016 23:06:44 GMT
Repository: commons-crypto
Updated Branches:
  refs/heads/master a3417803b -> 3b619e19a


Windows does not have /dev/random

Project: http://git-wip-us.apache.org/repos/asf/commons-crypto/repo
Commit: http://git-wip-us.apache.org/repos/asf/commons-crypto/commit/3b619e19
Tree: http://git-wip-us.apache.org/repos/asf/commons-crypto/tree/3b619e19
Diff: http://git-wip-us.apache.org/repos/asf/commons-crypto/diff/3b619e19

Branch: refs/heads/master
Commit: 3b619e19ada1d70dfa996337ed0ee0643a122229
Parents: a341780
Author: Sebb <sebb@apache.org>
Authored: Thu Jul 7 00:06:41 2016 +0100
Committer: Sebb <sebb@apache.org>
Committed: Thu Jul 7 00:06:41 2016 +0100

----------------------------------------------------------------------
 .../org/apache/commons/crypto/random/CryptoRandomFactoryTest.java | 3 +++
 1 file changed, 3 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/commons-crypto/blob/3b619e19/src/test/java/org/apache/commons/crypto/random/CryptoRandomFactoryTest.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/commons/crypto/random/CryptoRandomFactoryTest.java b/src/test/java/org/apache/commons/crypto/random/CryptoRandomFactoryTest.java
index 5a71564..3f33519 100644
--- a/src/test/java/org/apache/commons/crypto/random/CryptoRandomFactoryTest.java
+++ b/src/test/java/org/apache/commons/crypto/random/CryptoRandomFactoryTest.java
@@ -21,6 +21,7 @@ import java.security.GeneralSecurityException;
 import java.util.Properties;
 
 import org.junit.Assert;
+import org.junit.Assume;
 import org.junit.Test;
 
 public class CryptoRandomFactoryTest {
@@ -52,6 +53,8 @@ public class CryptoRandomFactoryTest {
 
     @Test
     public void testGetOSRandom() throws GeneralSecurityException {
+        // Windows does not have a /dev/random device
+        Assume.assumeTrue(!System.getProperty("os.name").contains("Windows"));
         Properties props = new Properties();
         props.setProperty(
             CryptoRandomFactory.CLASSES_KEY,


Mime
View raw message