message.getContext().setContext(SecurityService.AUTH_REQUEST, encryptedAuthRequest);
final boolean processingResult = pipeline.process(message);
assertTrue(processingResult);
assertEquals(new TestPrincipal("test").getName(), MockSecuredActionProcessor.getSubject().getPrincipals().iterator().next().getName());
assertEquals("The encrypted AuthenticationRequest should have been set as a thread local",
encryptedAuthRequest, AuthenticationRequestImpl.getEncryptedAuthRequest());
assertTrue("The SecurityContext should have been pushed", MockSecurityContextPropagator.wasPushCalled());
assertTrue("The SerirityContext should have been popped", MockSecurityContextPropagator.wasPopCalled());
assertNull("AuthenticationRequest should have been removed from the message context",