SEC-428: Security interceptor does not work with schema based aop:config
http://jira.springframework.org/browse/SEC-428. Fixed broken test method.
This commit is contained in:
parent
a375d8e59e
commit
028af06d61
|
@ -3,14 +3,15 @@ package org.springframework.security.intercept.method.aopalliance;
|
||||||
import org.junit.After;
|
import org.junit.After;
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
import org.springframework.context.support.AbstractXmlApplicationContext;
|
import org.springframework.context.support.AbstractXmlApplicationContext;
|
||||||
|
import org.springframework.security.AccessDeniedException;
|
||||||
|
import org.springframework.security.AuthenticationCredentialsNotFoundException;
|
||||||
import org.springframework.security.ITargetObject;
|
import org.springframework.security.ITargetObject;
|
||||||
import org.springframework.security.util.InMemoryXmlApplicationContext;
|
import org.springframework.security.util.InMemoryXmlApplicationContext;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Tests for SEC-428.
|
* Tests for SEC-428.
|
||||||
*
|
*
|
||||||
* @author Luke Taylor
|
* @author Luke Taylor
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
public class MethodSecurityInterceptorWithAopConfigTests {
|
public class MethodSecurityInterceptorWithAopConfigTests {
|
||||||
static final String AUTH_PROVIDER_XML =
|
static final String AUTH_PROVIDER_XML =
|
||||||
|
@ -38,7 +39,7 @@ public class MethodSecurityInterceptorWithAopConfigTests {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test(expected=AuthenticationCredentialsNotFoundException.class)
|
||||||
public void securityInterceptorIsAppliedWhenUsedWithAopConfig() {
|
public void securityInterceptorIsAppliedWhenUsedWithAopConfig() {
|
||||||
setContext(
|
setContext(
|
||||||
"<aop:config>" +
|
"<aop:config>" +
|
||||||
|
|
Loading…
Reference in New Issue