|
@@ -55,11 +55,14 @@ public class SecureContextImplTests extends TestCase {
|
|
context.setAuthentication(auth);
|
|
context.setAuthentication(auth);
|
|
context.validate();
|
|
context.validate();
|
|
assertEquals(auth, context.getAuthentication());
|
|
assertEquals(auth, context.getAuthentication());
|
|
|
|
+ assertTrue(context.toString().lastIndexOf("marissa") != -1);
|
|
}
|
|
}
|
|
|
|
|
|
public void testSecureContextDetectsMissingAuthenticationObject() {
|
|
public void testSecureContextDetectsMissingAuthenticationObject() {
|
|
SecureContext context = new SecureContextImpl();
|
|
SecureContext context = new SecureContextImpl();
|
|
|
|
|
|
|
|
+ assertTrue(context.toString().lastIndexOf("Null authentication") != -1);
|
|
|
|
+
|
|
try {
|
|
try {
|
|
context.validate();
|
|
context.validate();
|
|
fail("Should have thrown ContextInvalidException");
|
|
fail("Should have thrown ContextInvalidException");
|