You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2015/09/25 09:13:25 UTC
svn commit: r1705231 -
/tomcat/trunk/test/org/apache/catalina/realm/TestSecretKeyCredentialHandler.java
Author: markt
Date: Fri Sep 25 07:13:25 2015
New Revision: 1705231
URL: http://svn.apache.org/viewvc?rev=1705231&view=rev
Log:
Provide state info if tests fails (it failed on Gump but I have no idea why)
Modified:
tomcat/trunk/test/org/apache/catalina/realm/TestSecretKeyCredentialHandler.java
Modified: tomcat/trunk/test/org/apache/catalina/realm/TestSecretKeyCredentialHandler.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/catalina/realm/TestSecretKeyCredentialHandler.java?rev=1705231&r1=1705230&r2=1705231&view=diff
==============================================================================
--- tomcat/trunk/test/org/apache/catalina/realm/TestSecretKeyCredentialHandler.java (original)
+++ tomcat/trunk/test/org/apache/catalina/realm/TestSecretKeyCredentialHandler.java Fri Sep 25 07:13:25 2015
@@ -33,17 +33,19 @@ public class TestSecretKeyCredentialHand
for (String digest : ALGORITHMS) {
for (int saltLength = 1; saltLength < 20; saltLength++) {
for (int iterations = 1; iterations < 10000; iterations += 1000)
- doTest(digest, saltLength, iterations);
+ doTest(digest, saltLength, iterations);
}
}
}
- private void doTest(String digest, int saltLength, int iterations) throws NoSuchAlgorithmException {
+ private void doTest(String digest, int saltLength, int iterations)
+ throws NoSuchAlgorithmException {
SecretKeyCredentialHandler pbech = new SecretKeyCredentialHandler();
pbech.setAlgorithm(digest);
pbech.setIterations(iterations);
pbech.setSaltLength(saltLength);
String storedCredential = pbech.mutate(PWD);
- Assert.assertTrue(pbech.matches(PWD, storedCredential));
+ Assert.assertTrue("[" + digest + "] [" + saltLength + "] [" + iterations + "] [" + PWD +
+ "] [" + storedCredential +"]", pbech.matches(PWD, storedCredential));
}
}
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org