harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From smish...@apache.org
Subject svn commit: r396862 - in /incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java: javax/crypto/spec/ tests/api/javax/crypto/
Date Tue, 25 Apr 2006 12:31:31 GMT
Author: smishura
Date: Tue Apr 25 05:31:26 2006
New Revision: 396862

URL: http://svn.apache.org/viewcvs?rev=396862&view=rev
Log:
Apply patch for HARMONY-353 (improvements to junit test method usage) for crypto module. All
crypto tests passed on Windows.

Modified:
    incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/PBEKeySpecTest.java
  (contents, props changed)
    incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/PSourceTest.java
  (contents, props changed)
    incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/RC2ParameterSpecTest.java
  (contents, props changed)
    incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/RC5ParameterSpecTest.java
  (contents, props changed)
    incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/tests/api/javax/crypto/CipherTest.java

Modified: incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/PBEKeySpecTest.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/PBEKeySpecTest.java?rev=396862&r1=396861&r2=396862&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/PBEKeySpecTest.java
(original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/PBEKeySpecTest.java
Tue Apr 25 05:31:26 2006
@@ -253,8 +253,8 @@
                     + "should not cause the change of internal array.",
                     result[0] == pbeks.getSalt()[0]);
         pbeks = new PBEKeySpec(password);
-        assertTrue("The getSalt() method should return null if the salt "
-                    + "is not specified.", pbeks.getSalt() == null);
+        assertNull("The getSalt() method should return null if the salt "
+                    + "is not specified.", pbeks.getSalt());
     }
 
     /**

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/PBEKeySpecTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/PSourceTest.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/PSourceTest.java?rev=396862&r1=396861&r2=396862&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/PSourceTest.java
(original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/PSourceTest.java
Tue Apr 25 05:31:26 2006
@@ -47,8 +47,8 @@
         } catch (NullPointerException e) {
         }
 
-        assertTrue("The PSource.PSpecified DEFAULT value should be byte[0]",
-                            PSource.PSpecified.DEFAULT.getValue().length == 0);
+        assertEquals("The PSource.PSpecified DEFAULT value should be byte[0]",
+                            0, PSource.PSpecified.DEFAULT.getValue().length);
 
         byte[] p = new byte[] {1, 2, 3, 4, 5};
         PSource.PSpecified ps = new PSource.PSpecified(p);

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/PSourceTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/RC2ParameterSpecTest.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/RC2ParameterSpecTest.java?rev=396862&r1=396861&r2=396862&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/RC2ParameterSpecTest.java
(original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/RC2ParameterSpecTest.java
Tue Apr 25 05:31:26 2006
@@ -131,8 +131,8 @@
                     + "should not cause the change of internal array.",
                     result[0] == ps.getIV()[0]);
         ps = new RC2ParameterSpec(effectiveKeyBits);
-        assertTrue("The getIV() method should return null if the parameter "
-                    + "set does not contain iv.", ps.getIV() == null);
+        assertNull("The getIV() method should return null if the parameter "
+                    + "set does not contain iv.", ps.getIV());
     }
 
     /**

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/RC2ParameterSpecTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/RC5ParameterSpecTest.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/RC5ParameterSpecTest.java?rev=396862&r1=396861&r2=396862&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/RC5ParameterSpecTest.java
(original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/RC5ParameterSpecTest.java
Tue Apr 25 05:31:26 2006
@@ -192,8 +192,8 @@
                     + "should not cause the change of internal array.",
                     result[0] == ps.getIV()[0]);
         ps = new RC5ParameterSpec(version, rounds, wordSize);
-        assertTrue("The getIV() method should return null if the parameter "
-                    + "set does not contain IV.", ps.getIV() == null);
+        assertNull("The getIV() method should return null if the parameter "
+                    + "set does not contain IV.", ps.getIV());
     }
 
     /**

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/javax/crypto/spec/RC5ParameterSpecTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/tests/api/javax/crypto/CipherTest.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/tests/api/javax/crypto/CipherTest.java?rev=396862&r1=396861&r2=396862&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/tests/api/javax/crypto/CipherTest.java
(original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/crypto/src/test/java/tests/api/javax/crypto/CipherTest.java
Tue Apr 25 05:31:26 2006
@@ -157,7 +157,7 @@
 		final String algorithm = "DESede/CBC/PKCS5Padding";
 		try {
 			Cipher cipher = Cipher.getInstance(algorithm);
-			assertTrue("Block size does not match", cipher.getBlockSize() == 8);
+			assertEquals("Block size does not match", 8, cipher.getBlockSize());
 		} catch (Exception e) {
 			fail("Unexpected Exception");
 		}



Mime
View raw message