Polishing

This commit is contained in:
Juergen Hoeller 2016-07-26 17:15:15 +02:00
parent 7b564b72a1
commit e03dea1d64
193 changed files with 324 additions and 323 deletions

View File

@ -30,7 +30,7 @@ import org.junit.Test;
* @author Adrian Colyer * @author Adrian Colyer
* @author Chris Beams * @author Chris Beams
*/ */
public final class AspectJAdviceParameterNameDiscoverAnnotationTests public class AspectJAdviceParameterNameDiscoverAnnotationTests
extends AspectJAdviceParameterNameDiscovererTests { extends AspectJAdviceParameterNameDiscovererTests {
@Retention(RetentionPolicy.RUNTIME) @Retention(RetentionPolicy.RUNTIME)

View File

@ -43,7 +43,7 @@ import static org.junit.Assert.*;
* @author Rod Johnson * @author Rod Johnson
* @author Chris Beams * @author Chris Beams
*/ */
public final class AspectJExpressionPointcutTests { public class AspectJExpressionPointcutTests {
public static final String MATCH_ALL_METHODS = "execution(* *(..))"; public static final String MATCH_ALL_METHODS = "execution(* *(..))";

View File

@ -28,7 +28,7 @@ import static org.junit.Assert.*;
* @author Ramnivas Laddad * @author Ramnivas Laddad
* @author Chris Beams * @author Chris Beams
*/ */
public final class BeanNamePointcutMatchingTests { public class BeanNamePointcutMatchingTests {
@Test @Test
public void testMatchingPointcuts() { public void testMatchingPointcuts() {

View File

@ -44,7 +44,7 @@ import static org.junit.Assert.*;
* @author Ramnivas Laddad * @author Ramnivas Laddad
* @since 2.0 * @since 2.0
*/ */
public final class MethodInvocationProceedingJoinPointTests { public class MethodInvocationProceedingJoinPointTests {
@Test @Test
public void testingBindingWithJoinPoint() { public void testingBindingWithJoinPoint() {

View File

@ -27,7 +27,7 @@ import org.springframework.aop.aspectj.AspectJAdviceParameterNameDiscoverer.Ambi
* @author Adrian Colyer * @author Adrian Colyer
* @author Chris Beams * @author Chris Beams
*/ */
public final class TigerAspectJAdviceParameterNameDiscovererTests public class TigerAspectJAdviceParameterNameDiscovererTests
extends AspectJAdviceParameterNameDiscovererTests { extends AspectJAdviceParameterNameDiscovererTests {
@Test @Test

View File

@ -35,9 +35,9 @@ import static org.junit.Assert.*;
* @author Rick Evans * @author Rick Evans
* @author Chris Beams * @author Chris Beams
*/ */
public final class TypePatternClassFilterTests { public class TypePatternClassFilterTests {
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testInvalidPattern() { public void testInvalidPattern() {
// should throw - pattern must be recognized as invalid // should throw - pattern must be recognized as invalid
new TypePatternClassFilter("-"); new TypePatternClassFilter("-");
@ -78,12 +78,12 @@ public final class TypePatternClassFilterTests {
assertTrue("matches Double",tpcf.matches(Double.class)); assertTrue("matches Double",tpcf.matches(Double.class));
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testSetTypePatternWithNullArgument() throws Exception { public void testSetTypePatternWithNullArgument() throws Exception {
new TypePatternClassFilter(null); new TypePatternClassFilter(null);
} }
@Test(expected=IllegalStateException.class) @Test(expected = IllegalStateException.class)
public void testInvocationOfMatchesMethodBlowsUpWhenNoTypePatternHasBeenSet() throws Exception { public void testInvocationOfMatchesMethodBlowsUpWhenNoTypePatternHasBeenSet() throws Exception {
new TypePatternClassFilter().matches(String.class); new TypePatternClassFilter().matches(String.class);
} }

View File

@ -586,7 +586,7 @@ public abstract class AbstractAspectJAdvisorFactoryTests {
itb.getAge(); itb.getAge();
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testDeclarePrecedenceNotSupported() { public void testDeclarePrecedenceNotSupported() {
TestBean target = new TestBean(); TestBean target = new TestBean();
MetadataAwareAspectInstanceFactory aspectInstanceFactory = new SingletonMetadataAwareAspectInstanceFactory( MetadataAwareAspectInstanceFactory aspectInstanceFactory = new SingletonMetadataAwareAspectInstanceFactory(

View File

@ -39,7 +39,7 @@ import static org.junit.Assert.*;
*/ */
public class ArgumentBindingTests { public class ArgumentBindingTests {
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testBindingInPointcutUsedByAdvice() { public void testBindingInPointcutUsedByAdvice() {
TestBean tb = new TestBean(); TestBean tb = new TestBean();
AspectJProxyFactory proxyFactory = new AspectJProxyFactory(tb); AspectJProxyFactory proxyFactory = new AspectJProxyFactory(tb);
@ -49,7 +49,7 @@ public class ArgumentBindingTests {
proxiedTestBean.setName("Supercalifragalisticexpialidocious"); proxiedTestBean.setName("Supercalifragalisticexpialidocious");
} }
@Test(expected=IllegalStateException.class) @Test(expected = IllegalStateException.class)
public void testAnnotationArgumentNameBinding() { public void testAnnotationArgumentNameBinding() {
TransactionalBean tb = new TransactionalBean(); TransactionalBean tb = new TransactionalBean();
AspectJProxyFactory proxyFactory = new AspectJProxyFactory(tb); AspectJProxyFactory proxyFactory = new AspectJProxyFactory(tb);

View File

@ -30,9 +30,9 @@ import static org.junit.Assert.*;
* @author Rod Johnson * @author Rod Johnson
* @author Chris Beams * @author Chris Beams
*/ */
public final class AspectMetadataTests { public class AspectMetadataTests {
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testNotAnAspect() { public void testNotAnAspect() {
new AspectMetadata(String.class,"someBean"); new AspectMetadata(String.class,"someBean");
} }

View File

@ -23,7 +23,7 @@ package org.springframework.aop.aspectj.annotation;
* @author Rod Johnson * @author Rod Johnson
* @since 2.0 * @since 2.0
*/ */
public final class ReflectiveAspectJAdvisorFactoryTests extends AbstractAspectJAdvisorFactoryTests { public class ReflectiveAspectJAdvisorFactoryTests extends AbstractAspectJAdvisorFactoryTests {
@Override @Override
protected AspectJAdvisorFactory getFixture() { protected AspectJAdvisorFactory getFixture() {

View File

@ -37,7 +37,7 @@ import static org.junit.Assert.*;
* @author Rob Harrop * @author Rob Harrop
* @author Chris Beams * @author Chris Beams
*/ */
public final class AspectJNamespaceHandlerTests { public class AspectJNamespaceHandlerTests {
private ParserContext parserContext; private ParserContext parserContext;

View File

@ -40,7 +40,7 @@ import static org.springframework.tests.TestResourceUtils.*;
* @author Juergen Hoeller * @author Juergen Hoeller
* @author Chris Beams * @author Chris Beams
*/ */
public final class AopNamespaceHandlerEventTests { public class AopNamespaceHandlerEventTests {
private static final Class<?> CLASS = AopNamespaceHandlerEventTests.class; private static final Class<?> CLASS = AopNamespaceHandlerEventTests.class;

View File

@ -30,7 +30,7 @@ import static org.springframework.tests.TestResourceUtils.*;
* @author Mark Fisher * @author Mark Fisher
* @author Chris Beams * @author Chris Beams
*/ */
public final class AopNamespaceHandlerPointcutErrorTests { public class AopNamespaceHandlerPointcutErrorTests {
@Test @Test
public void testDuplicatePointcutConfig() { public void testDuplicatePointcutConfig() {

View File

@ -31,7 +31,7 @@ import static org.springframework.tests.TestResourceUtils.*;
* @author Rob Harrop * @author Rob Harrop
* @author Chris Beams * @author Chris Beams
*/ */
public final class TopLevelAopTagTests { public class TopLevelAopTagTests {
private static final Resource CONTEXT = qualifiedResource(TopLevelAopTagTests.class, "context.xml"); private static final Resource CONTEXT = qualifiedResource(TopLevelAopTagTests.class, "context.xml");

View File

@ -32,7 +32,7 @@ import org.springframework.util.StopWatch;
* @author Chris Beams * @author Chris Beams
* @since 2.0 * @since 2.0
*/ */
public final class IntroductionBenchmarkTests { public class IntroductionBenchmarkTests {
private static final int EXPECTED_COMPARE = 13; private static final int EXPECTED_COMPARE = 13;

View File

@ -33,7 +33,7 @@ import static org.junit.Assert.*;
* @author Chris Beams * @author Chris Beams
* @since 14.03.2003 * @since 14.03.2003
*/ */
public final class MethodInvocationTests { public class MethodInvocationTests {
@Test @Test
public void testValidInvocation() throws Throwable { public void testValidInvocation() throws Throwable {

View File

@ -32,7 +32,7 @@ import static org.springframework.tests.TestResourceUtils.*;
* @author Chris Beams * @author Chris Beams
* @since 03.09.2004 * @since 03.09.2004
*/ */
public final class PrototypeTargetTests { public class PrototypeTargetTests {
private static final Resource CONTEXT = qualifiedResource(PrototypeTargetTests.class, "context.xml"); private static final Resource CONTEXT = qualifiedResource(PrototypeTargetTests.class, "context.xml");

View File

@ -34,7 +34,7 @@ import static org.junit.Assert.*;
* @author Chris Beams * @author Chris Beams
* @since 06.04.2004 * @since 06.04.2004
*/ */
public final class ConcurrencyThrottleInterceptorTests { public class ConcurrencyThrottleInterceptorTests {
protected static final Log logger = LogFactory.getLog(ConcurrencyThrottleInterceptorTests.class); protected static final Log logger = LogFactory.getLog(ConcurrencyThrottleInterceptorTests.class);

View File

@ -29,51 +29,51 @@ import static org.mockito.BDDMockito.*;
* @author Juergen Hoeller * @author Juergen Hoeller
* @author Chris Beams * @author Chris Beams
*/ */
public final class CustomizableTraceInterceptorTests { public class CustomizableTraceInterceptorTests {
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testSetEmptyEnterMessage() { public void testSetEmptyEnterMessage() {
// Must not be able to set empty enter message // Must not be able to set empty enter message
new CustomizableTraceInterceptor().setEnterMessage(""); new CustomizableTraceInterceptor().setEnterMessage("");
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testSetEnterMessageWithReturnValuePlaceholder() { public void testSetEnterMessageWithReturnValuePlaceholder() {
// Must not be able to set enter message with return value placeholder // Must not be able to set enter message with return value placeholder
new CustomizableTraceInterceptor().setEnterMessage(CustomizableTraceInterceptor.PLACEHOLDER_RETURN_VALUE); new CustomizableTraceInterceptor().setEnterMessage(CustomizableTraceInterceptor.PLACEHOLDER_RETURN_VALUE);
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testSetEnterMessageWithExceptionPlaceholder() { public void testSetEnterMessageWithExceptionPlaceholder() {
// Must not be able to set enter message with exception placeholder // Must not be able to set enter message with exception placeholder
new CustomizableTraceInterceptor().setEnterMessage(CustomizableTraceInterceptor.PLACEHOLDER_EXCEPTION); new CustomizableTraceInterceptor().setEnterMessage(CustomizableTraceInterceptor.PLACEHOLDER_EXCEPTION);
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testSetEnterMessageWithInvocationTimePlaceholder() { public void testSetEnterMessageWithInvocationTimePlaceholder() {
// Must not be able to set enter message with invocation time placeholder // Must not be able to set enter message with invocation time placeholder
new CustomizableTraceInterceptor().setEnterMessage(CustomizableTraceInterceptor.PLACEHOLDER_INVOCATION_TIME); new CustomizableTraceInterceptor().setEnterMessage(CustomizableTraceInterceptor.PLACEHOLDER_INVOCATION_TIME);
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testSetEmptyExitMessage() { public void testSetEmptyExitMessage() {
// Must not be able to set empty exit message // Must not be able to set empty exit message
new CustomizableTraceInterceptor().setExitMessage(""); new CustomizableTraceInterceptor().setExitMessage("");
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testSetExitMessageWithExceptionPlaceholder() { public void testSetExitMessageWithExceptionPlaceholder() {
// Must not be able to set exit message with exception placeholder // Must not be able to set exit message with exception placeholder
new CustomizableTraceInterceptor().setExitMessage(CustomizableTraceInterceptor.PLACEHOLDER_EXCEPTION); new CustomizableTraceInterceptor().setExitMessage(CustomizableTraceInterceptor.PLACEHOLDER_EXCEPTION);
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testSetEmptyExceptionMessage() { public void testSetEmptyExceptionMessage() {
// Must not be able to set empty exception message // Must not be able to set empty exception message
new CustomizableTraceInterceptor().setExceptionMessage(""); new CustomizableTraceInterceptor().setExceptionMessage("");
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testSetExceptionMethodWithReturnValuePlaceholder() { public void testSetExceptionMethodWithReturnValuePlaceholder() {
// Must not be able to set exception message with return value placeholder // Must not be able to set exception message with return value placeholder
new CustomizableTraceInterceptor().setExceptionMessage(CustomizableTraceInterceptor.PLACEHOLDER_RETURN_VALUE); new CustomizableTraceInterceptor().setExceptionMessage(CustomizableTraceInterceptor.PLACEHOLDER_RETURN_VALUE);

View File

@ -29,7 +29,7 @@ import static org.mockito.BDDMockito.*;
* @author Rick Evans * @author Rick Evans
* @author Chris Beams * @author Chris Beams
*/ */
public final class DebugInterceptorTests { public class DebugInterceptorTests {
@Test @Test
public void testSunnyDayPathLogsCorrectly() throws Throwable { public void testSunnyDayPathLogsCorrectly() throws Throwable {

View File

@ -29,7 +29,7 @@ import static org.junit.Assert.*;
* @author Rod Johnson * @author Rod Johnson
* @author Chris Beams * @author Chris Beams
*/ */
public final class ExposeBeanNameAdvisorsTests { public class ExposeBeanNameAdvisorsTests {
private class RequiresBeanNameBoundTestBean extends TestBean { private class RequiresBeanNameBoundTestBean extends TestBean {
private final String beanName; private final String beanName;

View File

@ -34,7 +34,7 @@ import static org.springframework.tests.TestResourceUtils.*;
* @author Rod Johnson * @author Rod Johnson
* @author Chris Beams * @author Chris Beams
*/ */
public final class ExposeInvocationInterceptorTests { public class ExposeInvocationInterceptorTests {
private static final Resource CONTEXT = private static final Resource CONTEXT =
qualifiedResource(ExposeInvocationInterceptorTests.class, "context.xml"); qualifiedResource(ExposeInvocationInterceptorTests.class, "context.xml");

View File

@ -28,7 +28,7 @@ import static org.mockito.BDDMockito.*;
* @author Rick Evans * @author Rick Evans
* @author Chris Beams * @author Chris Beams
*/ */
public final class PerformanceMonitorInterceptorTests { public class PerformanceMonitorInterceptorTests {
@Test @Test
public void testSuffixAndPrefixAssignment() { public void testSuffixAndPrefixAssignment() {

View File

@ -29,7 +29,7 @@ import static org.mockito.BDDMockito.*;
* @author Rick Evans * @author Rick Evans
* @author Chris Beams * @author Chris Beams
*/ */
public final class SimpleTraceInterceptorTests { public class SimpleTraceInterceptorTests {
@Test @Test
public void testSunnyDayPathLogsCorrectly() throws Throwable { public void testSunnyDayPathLogsCorrectly() throws Throwable {

View File

@ -28,27 +28,27 @@ import static org.mockito.BDDMockito.*;
* @author Rick Evans * @author Rick Evans
* @author Chris Beams * @author Chris Beams
*/ */
public final class DefaultScopedObjectTests { public class DefaultScopedObjectTests {
private static final String GOOD_BEAN_NAME = "foo"; private static final String GOOD_BEAN_NAME = "foo";
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testCtorWithNullBeanFactory() throws Exception { public void testCtorWithNullBeanFactory() throws Exception {
new DefaultScopedObject(null, GOOD_BEAN_NAME); new DefaultScopedObject(null, GOOD_BEAN_NAME);
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testCtorWithNullTargetBeanName() throws Exception { public void testCtorWithNullTargetBeanName() throws Exception {
testBadTargetBeanName(null); testBadTargetBeanName(null);
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testCtorWithEmptyTargetBeanName() throws Exception { public void testCtorWithEmptyTargetBeanName() throws Exception {
testBadTargetBeanName(""); testBadTargetBeanName("");
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testCtorWithJustWhitespacedTargetBeanName() throws Exception { public void testCtorWithJustWhitespacedTargetBeanName() throws Exception {
testBadTargetBeanName(" "); testBadTargetBeanName(" ");
} }

View File

@ -29,7 +29,7 @@ import static org.springframework.tests.TestResourceUtils.*;
* @author Mark Fisher * @author Mark Fisher
* @author Chris Beams * @author Chris Beams
*/ */
public final class ScopedProxyAutowireTests { public class ScopedProxyAutowireTests {
private static final Class<?> CLASS = ScopedProxyAutowireTests.class; private static final Class<?> CLASS = ScopedProxyAutowireTests.class;

View File

@ -35,7 +35,7 @@ import static org.junit.Assert.*;
* @author Rod Johnson * @author Rod Johnson
* @author Chris Beams * @author Chris Beams
*/ */
public final class AopUtilsTests { public class AopUtilsTests {
@Test @Test
public void testPointcutCanNeverApply() { public void testPointcutCanNeverApply() {

View File

@ -29,7 +29,7 @@ import static org.junit.Assert.*;
* @author Rod Johnson * @author Rod Johnson
* @author Chris Beams * @author Chris Beams
*/ */
public final class ClassFiltersTests { public class ClassFiltersTests {
private ClassFilter exceptionFilter = new RootClassFilter(Exception.class); private ClassFilter exceptionFilter = new RootClassFilter(Exception.class);

View File

@ -30,7 +30,7 @@ import static org.junit.Assert.*;
* @author Rod Johnson * @author Rod Johnson
* @author Chris Beams * @author Chris Beams
*/ */
public final class ControlFlowPointcutTests { public class ControlFlowPointcutTests {
@Test @Test
public void testMatches() { public void testMatches() {

View File

@ -43,9 +43,9 @@ import static org.mockito.BDDMockito.*;
* @author Chris Beams * @author Chris Beams
* @since 13.05.2003 * @since 13.05.2003
*/ */
public final class DelegatingIntroductionInterceptorTests { public class DelegatingIntroductionInterceptorTests {
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testNullTarget() throws Exception { public void testNullTarget() throws Exception {
// Shouldn't accept null target // Shouldn't accept null target
new DelegatingIntroductionInterceptor(null); new DelegatingIntroductionInterceptor(null);

View File

@ -19,7 +19,7 @@ package org.springframework.aop.support;
/** /**
* @author Dmitriy Kopylenko * @author Dmitriy Kopylenko
*/ */
public final class JdkRegexpMethodPointcutTests extends AbstractRegexpMethodPointcutTests { public class JdkRegexpMethodPointcutTests extends AbstractRegexpMethodPointcutTests {
@Override @Override
protected AbstractRegexpMethodPointcut getRegexpMethodPointcut() { protected AbstractRegexpMethodPointcut getRegexpMethodPointcut() {

View File

@ -33,7 +33,7 @@ import static org.junit.Assert.*;
* @author Rod Johnson * @author Rod Johnson
* @author Chris Beams * @author Chris Beams
*/ */
public final class NameMatchMethodPointcutTests { public class NameMatchMethodPointcutTests {
protected NameMatchMethodPointcut pc; protected NameMatchMethodPointcut pc;

View File

@ -36,7 +36,7 @@ import static org.springframework.tests.TestResourceUtils.*;
* @author Rod Johnson * @author Rod Johnson
* @author Chris Beams * @author Chris Beams
*/ */
public final class RegexpMethodPointcutAdvisorIntegrationTests { public class RegexpMethodPointcutAdvisorIntegrationTests {
private static final Resource CONTEXT = private static final Resource CONTEXT =
qualifiedResource(RegexpMethodPointcutAdvisorIntegrationTests.class, "context.xml"); qualifiedResource(RegexpMethodPointcutAdvisorIntegrationTests.class, "context.xml");

View File

@ -30,7 +30,7 @@ import static org.springframework.tests.TestResourceUtils.*;
/** /**
* @author Stephane Nicoll * @author Stephane Nicoll
*/ */
public final class CommonsPool2TargetSourceProxyTests { public class CommonsPool2TargetSourceProxyTests {
private static final Resource CONTEXT = private static final Resource CONTEXT =
qualifiedResource(CommonsPool2TargetSourceProxyTests.class, "context.xml"); qualifiedResource(CommonsPool2TargetSourceProxyTests.class, "context.xml");

View File

@ -39,7 +39,7 @@ import static org.springframework.tests.TestResourceUtils.*;
* @author Rod Johnson * @author Rod Johnson
* @author Chris Beams * @author Chris Beams
*/ */
public final class HotSwappableTargetSourceTests { public class HotSwappableTargetSourceTests {
private static final Resource CONTEXT = qualifiedResource(HotSwappableTargetSourceTests.class, "context.xml"); private static final Resource CONTEXT = qualifiedResource(HotSwappableTargetSourceTests.class, "context.xml");

View File

@ -28,7 +28,7 @@ import static org.junit.Assert.*;
* @author Juergen Hoeller * @author Juergen Hoeller
* @author Chris Beams * @author Chris Beams
*/ */
public final class LazyCreationTargetSourceTests { public class LazyCreationTargetSourceTests {
@Test @Test
public void testCreateLazy() { public void testCreateLazy() {

View File

@ -34,7 +34,7 @@ import static org.springframework.tests.TestResourceUtils.*;
* @author Chris Beams * @author Chris Beams
* @since 07.01.2005 * @since 07.01.2005
*/ */
public final class LazyInitTargetSourceTests { public class LazyInitTargetSourceTests {
private static final Class<?> CLASS = LazyInitTargetSourceTests.class; private static final Class<?> CLASS = LazyInitTargetSourceTests.class;

View File

@ -35,7 +35,7 @@ import static org.junit.Assert.*;
* @author Rod Johnson * @author Rod Johnson
* @author Chris Beams * @author Chris Beams
*/ */
public final class PrototypeBasedTargetSourceTests { public class PrototypeBasedTargetSourceTests {
@Test @Test
public void testSerializability() throws Exception { public void testSerializability() throws Exception {

View File

@ -33,7 +33,7 @@ import static org.springframework.tests.TestResourceUtils.*;
* @author Rod Johnson * @author Rod Johnson
* @author Chris Beams * @author Chris Beams
*/ */
public final class PrototypeTargetSourceTests { public class PrototypeTargetSourceTests {
private static final Resource CONTEXT = qualifiedResource(PrototypeTargetSourceTests.class, "context.xml"); private static final Resource CONTEXT = qualifiedResource(PrototypeTargetSourceTests.class, "context.xml");

View File

@ -27,7 +27,7 @@ import static org.junit.Assert.*;
* @author Rob Harrop * @author Rob Harrop
* @author Chris Beams * @author Chris Beams
*/ */
public final class RefreshableTargetSourceTests { public class RefreshableTargetSourceTests {
/** /**
* Test what happens when checking for refresh but not refreshing object. * Test what happens when checking for refresh but not refreshing object.

View File

@ -26,7 +26,7 @@ import org.springframework.cache.interceptor.KeyGenerator;
* *
* @author Stephane Nicoll * @author Stephane Nicoll
*/ */
public final class SomeCustomKeyGenerator implements KeyGenerator { public class SomeCustomKeyGenerator implements KeyGenerator {
@Override @Override
public Object generate(Object target, Method method, Object... params) { public Object generate(Object target, Method method, Object... params) {

View File

@ -42,7 +42,7 @@ import static org.junit.Assert.*;
* @author Chris Beams * @author Chris Beams
* @since 19.05.2003 * @since 19.05.2003
*/ */
public final class BeanUtilsTests { public class BeanUtilsTests {
@Test @Test
public void testInstantiateClass() { public void testInstantiateClass() {

View File

@ -31,7 +31,7 @@ import static org.junit.Assert.*;
* @author Juergen Hoeller * @author Juergen Hoeller
* @author Chris Beams * @author Chris Beams
*/ */
public final class BeanWrapperEnumTests { public class BeanWrapperEnumTests {
@Test @Test
public void testCustomEnum() { public void testCustomEnum() {

View File

@ -36,7 +36,7 @@ import static org.junit.Assert.*;
* @author Chris Beams * @author Chris Beams
* @since 08.03.2004 * @since 08.03.2004
*/ */
public final class ConcurrentBeanWrapperTests { public class ConcurrentBeanWrapperTests {
private final Log logger = LogFactory.getLog(getClass()); private final Log logger = LogFactory.getLog(getClass());

View File

@ -26,7 +26,7 @@ import static org.junit.Assert.*;
* @author Rod Johnson * @author Rod Johnson
* @author Chris Beams * @author Chris Beams
*/ */
public final class MutablePropertyValuesTests extends AbstractPropertyValuesTests { public class MutablePropertyValuesTests extends AbstractPropertyValuesTests {
@Test @Test
public void testValid() throws Exception { public void testValid() throws Exception {

View File

@ -26,7 +26,7 @@ import static org.junit.Assert.*;
* @author Juergen Hoeller * @author Juergen Hoeller
* @author Chris Beams * @author Chris Beams
*/ */
public final class PropertyAccessorUtilsTests { public class PropertyAccessorUtilsTests {
@Test @Test
public void testCanonicalPropertyName() { public void testCanonicalPropertyName() {

View File

@ -43,7 +43,7 @@ import static org.springframework.tests.TestResourceUtils.*;
* @author Chris Beams * @author Chris Beams
* @since 04.07.2003 * @since 04.07.2003
*/ */
public final class BeanFactoryUtilsTests { public class BeanFactoryUtilsTests {
private static final Class<?> CLASS = BeanFactoryUtilsTests.class; private static final Class<?> CLASS = BeanFactoryUtilsTests.class;
private static final Resource ROOT_CONTEXT = qualifiedResource(CLASS, "root.xml"); private static final Resource ROOT_CONTEXT = qualifiedResource(CLASS, "root.xml");

View File

@ -48,7 +48,7 @@ import static org.springframework.tests.TestResourceUtils.*;
* @author Chris Beams * @author Chris Beams
* @since 10.03.2004 * @since 10.03.2004
*/ */
public final class ConcurrentBeanFactoryTests { public class ConcurrentBeanFactoryTests {
private static final Log logger = LogFactory.getLog(ConcurrentBeanFactoryTests.class); private static final Log logger = LogFactory.getLog(ConcurrentBeanFactoryTests.class);
private static final Resource CONTEXT = qualifiedResource(ConcurrentBeanFactoryTests.class, "context.xml"); private static final Resource CONTEXT = qualifiedResource(ConcurrentBeanFactoryTests.class, "context.xml");

View File

@ -26,7 +26,7 @@ import static org.junit.Assert.*;
* @author Rick Evans * @author Rick Evans
* @author Chris Beams * @author Chris Beams
*/ */
public final class AnnotationBeanWiringInfoResolverTests { public class AnnotationBeanWiringInfoResolverTests {
@Test @Test
public void testResolveWiringInfo() throws Exception { public void testResolveWiringInfo() throws Exception {

View File

@ -36,7 +36,7 @@ import static org.springframework.tests.TestResourceUtils.*;
* @author Juergen Hoeller * @author Juergen Hoeller
* @author Chris Beams * @author Chris Beams
*/ */
public final class CustomAutowireConfigurerTests { public class CustomAutowireConfigurerTests {
private static final Resource CONTEXT = qualifiedResource(CustomAutowireConfigurerTests.class, "context.xml"); private static final Resource CONTEXT = qualifiedResource(CustomAutowireConfigurerTests.class, "context.xml");

View File

@ -39,7 +39,7 @@ import static org.junit.Assert.*;
* @author Chris Beams * @author Chris Beams
* @since 2.0 * @since 2.0
*/ */
public final class RequiredAnnotationBeanPostProcessorTests { public class RequiredAnnotationBeanPostProcessorTests {
@Test @Test
public void testWithRequiredPropertyOmitted() { public void testWithRequiredPropertyOmitted() {

View File

@ -42,7 +42,7 @@ import static org.junit.Assert.*;
* @author Chris Beams * @author Chris Beams
* @since 31.07.2004 * @since 31.07.2004
*/ */
public final class CustomEditorConfigurerTests { public class CustomEditorConfigurerTests {
@Test @Test
public void testCustomEditorConfigurerWithPropertyEditorRegistrar() throws ParseException { public void testCustomEditorConfigurerWithPropertyEditorRegistrar() throws ParseException {

View File

@ -34,7 +34,7 @@ import static org.mockito.BDDMockito.*;
* @author Juergen Hoeller * @author Juergen Hoeller
* @author Chris Beams * @author Chris Beams
*/ */
public final class CustomScopeConfigurerTests { public class CustomScopeConfigurerTests {
private static final String FOO_SCOPE = "fooScope"; private static final String FOO_SCOPE = "fooScope";
private ConfigurableListableBeanFactory factory; private ConfigurableListableBeanFactory factory;
@ -81,7 +81,7 @@ public final class CustomScopeConfigurerTests {
assertTrue(factory.getRegisteredScope(FOO_SCOPE) instanceof NoOpScope); assertTrue(factory.getRegisteredScope(FOO_SCOPE) instanceof NoOpScope);
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testWhereScopeMapHasNullScopeValueInEntrySet() throws Exception { public void testWhereScopeMapHasNullScopeValueInEntrySet() throws Exception {
Map<String, Object> scopes = new HashMap<>(); Map<String, Object> scopes = new HashMap<>();
scopes.put(FOO_SCOPE, null); scopes.put(FOO_SCOPE, null);
@ -90,7 +90,7 @@ public final class CustomScopeConfigurerTests {
figurer.postProcessBeanFactory(factory); figurer.postProcessBeanFactory(factory);
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testWhereScopeMapHasNonScopeInstanceInEntrySet() throws Exception { public void testWhereScopeMapHasNonScopeInstanceInEntrySet() throws Exception {
Map<String, Object> scopes = new HashMap<>(); Map<String, Object> scopes = new HashMap<>();
scopes.put(FOO_SCOPE, this); // <-- not a valid value... scopes.put(FOO_SCOPE, this); // <-- not a valid value...
@ -100,7 +100,7 @@ public final class CustomScopeConfigurerTests {
} }
@SuppressWarnings("unchecked") @SuppressWarnings("unchecked")
@Test(expected=ClassCastException.class) @Test(expected = ClassCastException.class)
public void testWhereScopeMapHasNonStringTypedScopeNameInKeySet() throws Exception { public void testWhereScopeMapHasNonStringTypedScopeNameInKeySet() throws Exception {
Map scopes = new HashMap(); Map scopes = new HashMap();
scopes.put(this, new NoOpScope()); // <-- not a valid value (the key)... scopes.put(this, new NoOpScope()); // <-- not a valid value (the key)...

View File

@ -35,7 +35,7 @@ import static org.springframework.tests.TestResourceUtils.*;
* @author Chris Beams * @author Chris Beams
* @since 31.07.2004 * @since 31.07.2004
*/ */
public final class FieldRetrievingFactoryBeanTests { public class FieldRetrievingFactoryBeanTests {
private static final Resource CONTEXT = private static final Resource CONTEXT =
qualifiedResource(FieldRetrievingFactoryBeanTests.class, "context.xml"); qualifiedResource(FieldRetrievingFactoryBeanTests.class, "context.xml");

View File

@ -32,7 +32,7 @@ import static org.springframework.tests.TestResourceUtils.*;
* @author Chris Beams * @author Chris Beams
* @since 01.11.2003 * @since 01.11.2003
*/ */
public final class PropertiesFactoryBeanTests { public class PropertiesFactoryBeanTests {
private static final Class<?> CLASS = PropertiesFactoryBeanTests.class; private static final Class<?> CLASS = PropertiesFactoryBeanTests.class;
private static final Resource TEST_PROPS = qualifiedResource(CLASS, "test.properties"); private static final Resource TEST_PROPS = qualifiedResource(CLASS, "test.properties");

View File

@ -38,7 +38,7 @@ import static org.springframework.beans.factory.support.BeanDefinitionBuilder.*;
* @author Rick Evans * @author Rick Evans
* @author Chris Beams * @author Chris Beams
*/ */
public final class ServiceLocatorFactoryBeanTests { public class ServiceLocatorFactoryBeanTests {
private DefaultListableBeanFactory bf; private DefaultListableBeanFactory bf;
@ -237,12 +237,12 @@ public final class ServiceLocatorFactoryBeanTests {
assertTrue(testBean4 instanceof ExtendedTestService); assertTrue(testBean4 instanceof ExtendedTestService);
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testNoServiceLocatorInterfaceSupplied() throws Exception { public void testNoServiceLocatorInterfaceSupplied() throws Exception {
new ServiceLocatorFactoryBean().afterPropertiesSet(); new ServiceLocatorFactoryBean().afterPropertiesSet();
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testWhenServiceLocatorInterfaceIsNotAnInterfaceType() throws Exception { public void testWhenServiceLocatorInterfaceIsNotAnInterfaceType() throws Exception {
ServiceLocatorFactoryBean factory = new ServiceLocatorFactoryBean(); ServiceLocatorFactoryBean factory = new ServiceLocatorFactoryBean();
factory.setServiceLocatorInterface(getClass()); factory.setServiceLocatorInterface(getClass());
@ -250,14 +250,14 @@ public final class ServiceLocatorFactoryBeanTests {
// should throw, bad (non-interface-type) serviceLocator interface supplied // should throw, bad (non-interface-type) serviceLocator interface supplied
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testWhenServiceLocatorExceptionClassToExceptionTypeWithOnlyNoArgCtor() throws Exception { public void testWhenServiceLocatorExceptionClassToExceptionTypeWithOnlyNoArgCtor() throws Exception {
ServiceLocatorFactoryBean factory = new ServiceLocatorFactoryBean(); ServiceLocatorFactoryBean factory = new ServiceLocatorFactoryBean();
factory.setServiceLocatorExceptionClass(ExceptionClassWithOnlyZeroArgCtor.class); factory.setServiceLocatorExceptionClass(ExceptionClassWithOnlyZeroArgCtor.class);
// should throw, bad (invalid-Exception-type) serviceLocatorException class supplied // should throw, bad (invalid-Exception-type) serviceLocatorException class supplied
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
@SuppressWarnings("unchecked") @SuppressWarnings("unchecked")
public void testWhenServiceLocatorExceptionClassIsNotAnExceptionSubclass() throws Exception { public void testWhenServiceLocatorExceptionClassIsNotAnExceptionSubclass() throws Exception {
ServiceLocatorFactoryBean factory = new ServiceLocatorFactoryBean(); ServiceLocatorFactoryBean factory = new ServiceLocatorFactoryBean();
@ -265,7 +265,7 @@ public final class ServiceLocatorFactoryBeanTests {
// should throw, bad (non-Exception-type) serviceLocatorException class supplied // should throw, bad (non-Exception-type) serviceLocatorException class supplied
} }
@Test(expected=UnsupportedOperationException.class) @Test(expected = UnsupportedOperationException.class)
public void testWhenServiceLocatorMethodCalledWithTooManyParameters() throws Exception { public void testWhenServiceLocatorMethodCalledWithTooManyParameters() throws Exception {
ServiceLocatorFactoryBean factory = new ServiceLocatorFactoryBean(); ServiceLocatorFactoryBean factory = new ServiceLocatorFactoryBean();
factory.setServiceLocatorInterface(ServiceLocatorInterfaceWithExtraNonCompliantMethod.class); factory.setServiceLocatorInterface(ServiceLocatorInterfaceWithExtraNonCompliantMethod.class);

View File

@ -38,7 +38,7 @@ import static org.springframework.tests.TestResourceUtils.*;
* @author Juergen Hoeller * @author Juergen Hoeller
* @author Chris Beams * @author Chris Beams
*/ */
public final class SimpleScopeTests { public class SimpleScopeTests {
private static final Resource CONTEXT = qualifiedResource(SimpleScopeTests.class, "context.xml"); private static final Resource CONTEXT = qualifiedResource(SimpleScopeTests.class, "context.xml");

View File

@ -24,9 +24,9 @@ import org.junit.Test;
* @author Rick Evans * @author Rick Evans
* @author Chris Beams * @author Chris Beams
*/ */
public final class ConstructorArgumentEntryTests { public class ConstructorArgumentEntryTests {
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testCtorBailsOnNegativeCtorIndexArgument() { public void testCtorBailsOnNegativeCtorIndexArgument() {
new ConstructorArgumentEntry(-1); new ConstructorArgumentEntry(-1);
} }

View File

@ -35,7 +35,7 @@ import static org.springframework.tests.TestResourceUtils.*;
* @author Chris Beams * @author Chris Beams
* @since 2.0 * @since 2.0
*/ */
public final class CustomProblemReporterTests { public class CustomProblemReporterTests {
private static final Resource CONTEXT = qualifiedResource(CustomProblemReporterTests.class, "context.xml"); private static final Resource CONTEXT = qualifiedResource(CustomProblemReporterTests.class, "context.xml");

View File

@ -28,9 +28,9 @@ import static org.mockito.BDDMockito.*;
* @author Juergen Hoeller * @author Juergen Hoeller
* @author Chris Beams * @author Chris Beams
*/ */
public final class FailFastProblemReporterTests { public class FailFastProblemReporterTests {
@Test(expected=BeanDefinitionParsingException.class) @Test(expected = BeanDefinitionParsingException.class)
public void testError() throws Exception { public void testError() throws Exception {
FailFastProblemReporter reporter = new FailFastProblemReporter(); FailFastProblemReporter reporter = new FailFastProblemReporter();
reporter.error(new Problem("VGER", new Location(new DescriptiveResource("here")), reporter.error(new Problem("VGER", new Location(new DescriptiveResource("here")),

View File

@ -24,7 +24,7 @@ import static org.junit.Assert.*;
* @author Rick Evans * @author Rick Evans
* @author Chris Beams * @author Chris Beams
*/ */
public final class NullSourceExtractorTests { public class NullSourceExtractorTests {
@Test @Test
public void testPassThroughContract() throws Exception { public void testPassThroughContract() throws Exception {

View File

@ -26,7 +26,7 @@ import static org.junit.Assert.*;
* @author Rick Evans * @author Rick Evans
* @author Chris Beams * @author Chris Beams
*/ */
public final class PassThroughSourceExtractorTests { public class PassThroughSourceExtractorTests {
@Test @Test
public void testPassThroughContract() throws Exception { public void testPassThroughContract() throws Exception {

View File

@ -24,19 +24,19 @@ import org.junit.Test;
* @author Rick Evans * @author Rick Evans
* @author Chris Beams * @author Chris Beams
*/ */
public final class PropertyEntryTests { public class PropertyEntryTests {
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testCtorBailsOnNullPropertyNameArgument() throws Exception { public void testCtorBailsOnNullPropertyNameArgument() throws Exception {
new PropertyEntry(null); new PropertyEntry(null);
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testCtorBailsOnEmptyPropertyNameArgument() throws Exception { public void testCtorBailsOnEmptyPropertyNameArgument() throws Exception {
new PropertyEntry(""); new PropertyEntry("");
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testCtorBailsOnWhitespacedPropertyNameArgument() throws Exception { public void testCtorBailsOnWhitespacedPropertyNameArgument() throws Exception {
new PropertyEntry("\t "); new PropertyEntry("\t ");
} }

View File

@ -26,7 +26,7 @@ import static org.junit.Assert.*;
* @author Rick Evans * @author Rick Evans
* @author Sam Brannen * @author Sam Brannen
*/ */
public final class BeanWiringInfoTests { public class BeanWiringInfoTests {
@Test(expected = IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void ctorWithNullBeanName() throws Exception { public void ctorWithNullBeanName() throws Exception {

View File

@ -25,7 +25,7 @@ import static org.junit.Assert.*;
* *
* @author Rick Evans * @author Rick Evans
*/ */
public final class ClassNameBeanWiringInfoResolverTests { public class ClassNameBeanWiringInfoResolverTests {
@Test(expected = IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void resolveWiringInfoWithNullBeanInstance() throws Exception { public void resolveWiringInfoWithNullBeanInstance() throws Exception {

View File

@ -26,19 +26,19 @@ import org.xml.sax.InputSource;
* @author Rick Evans * @author Rick Evans
* @author Chris Beams * @author Chris Beams
*/ */
public final class DelegatingEntityResolverTests { public class DelegatingEntityResolverTests {
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testCtorWhereDtdEntityResolverIsNull() throws Exception { public void testCtorWhereDtdEntityResolverIsNull() throws Exception {
new DelegatingEntityResolver(null, new NoOpEntityResolver()); new DelegatingEntityResolver(null, new NoOpEntityResolver());
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testCtorWhereSchemaEntityResolverIsNull() throws Exception { public void testCtorWhereSchemaEntityResolverIsNull() throws Exception {
new DelegatingEntityResolver(new NoOpEntityResolver(), null); new DelegatingEntityResolver(new NoOpEntityResolver(), null);
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testCtorWhereEntityResolversAreBothNull() throws Exception { public void testCtorWhereEntityResolversAreBothNull() throws Exception {
new DelegatingEntityResolver(null, null); new DelegatingEntityResolver(null, null);
} }

View File

@ -61,7 +61,7 @@ public class ProfileXmlBeanDefinitionTests {
private static final String TARGET_BEAN = "foo"; private static final String TARGET_BEAN = "foo";
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testProfileValidation() { public void testProfileValidation() {
beanFactoryFor(PROD_ELIGIBLE_XML, NULL_ACTIVE); beanFactoryFor(PROD_ELIGIBLE_XML, NULL_ACTIVE);
} }

View File

@ -77,7 +77,7 @@ public class DefaultNamespaceHandlerResolverTests {
new DefaultNamespaceHandlerResolver(null); new DefaultNamespaceHandlerResolver(null);
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testCtorWithNullClassLoaderArgumentAndNullMappingLocationArgument() throws Exception { public void testCtorWithNullClassLoaderArgumentAndNullMappingLocationArgument() throws Exception {
new DefaultNamespaceHandlerResolver(null, null); new DefaultNamespaceHandlerResolver(null, null);
} }

View File

@ -27,7 +27,7 @@ import static org.junit.Assert.*;
* *
* @author Rick Evans * @author Rick Evans
*/ */
public final class ByteArrayPropertyEditorTests { public class ByteArrayPropertyEditorTests {
private final PropertyEditor byteEditor = new ByteArrayPropertyEditor(); private final PropertyEditor byteEditor = new ByteArrayPropertyEditor();

View File

@ -27,7 +27,7 @@ import static org.junit.Assert.*;
* *
* @author Rick Evans * @author Rick Evans
*/ */
public final class CharArrayPropertyEditorTests { public class CharArrayPropertyEditorTests {
private final PropertyEditor charEditor = new CharArrayPropertyEditor(); private final PropertyEditor charEditor = new CharArrayPropertyEditor();

View File

@ -30,20 +30,20 @@ import static org.junit.Assert.*;
* @author Rick Evans * @author Rick Evans
* @author Chris Beams * @author Chris Beams
*/ */
public final class CustomCollectionEditorTests { public class CustomCollectionEditorTests {
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testCtorWithNullCollectionType() throws Exception { public void testCtorWithNullCollectionType() throws Exception {
new CustomCollectionEditor(null); new CustomCollectionEditor(null);
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
@SuppressWarnings("unchecked") @SuppressWarnings("unchecked")
public void testCtorWithNonCollectionType() throws Exception { public void testCtorWithNonCollectionType() throws Exception {
new CustomCollectionEditor((Class) String.class); new CustomCollectionEditor((Class) String.class);
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testWithCollectionTypeThatDoesNotExposeAPublicNoArgCtor() throws Exception { public void testWithCollectionTypeThatDoesNotExposeAPublicNoArgCtor() throws Exception {
CustomCollectionEditor editor = new CustomCollectionEditor(CollectionTypeWithNoNoArgCtor.class); CustomCollectionEditor editor = new CustomCollectionEditor(CollectionTypeWithNoNoArgCtor.class);
editor.setValue("1"); editor.setValue("1");

View File

@ -31,7 +31,7 @@ import static org.junit.Assert.*;
* @author Chris Beams * @author Chris Beams
* @since 10.09.2003 * @since 10.09.2003
*/ */
public final class SimpleMailMessageTests { public class SimpleMailMessageTests {
@Test @Test
public void testSimpleMessageCopyCtor() { public void testSimpleMessageCopyCtor() {
@ -155,12 +155,12 @@ public final class SimpleMailMessageTests {
assertTrue(message1.equals(message2)); assertTrue(message1.equals(message2));
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testCopyCtorChokesOnNullOriginalMessage() throws Exception { public void testCopyCtorChokesOnNullOriginalMessage() throws Exception {
new SimpleMailMessage(null); new SimpleMailMessage(null);
} }
@Test(expected=IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
public void testCopyToChokesOnNullTargetMessage() throws Exception { public void testCopyToChokesOnNullTargetMessage() throws Exception {
new SimpleMailMessage().copyTo(null); new SimpleMailMessage().copyTo(null);
} }

View File

@ -36,7 +36,7 @@ import static org.mockito.BDDMockito.*;
* @author Rod Johnson * @author Rod Johnson
* @author Chris Beams * @author Chris Beams
*/ */
public final class AfterAdviceBindingTests { public class AfterAdviceBindingTests {
private AdviceBindingCollaborator mockCollaborator; private AdviceBindingCollaborator mockCollaborator;

View File

@ -37,7 +37,7 @@ import static org.mockito.BDDMockito.*;
* @author Juergen Hoeller * @author Juergen Hoeller
* @author Chris Beams * @author Chris Beams
*/ */
public final class AfterReturningAdviceBindingTests { public class AfterReturningAdviceBindingTests {
private AfterReturningAdviceBindingTestAspect afterAdviceAspect; private AfterReturningAdviceBindingTestAspect afterAdviceAspect;

View File

@ -31,7 +31,7 @@ import static org.mockito.BDDMockito.*;
* @author Adrian Colyer * @author Adrian Colyer
* @author Chris Beams * @author Chris Beams
*/ */
public final class AfterThrowingAdviceBindingTests { public class AfterThrowingAdviceBindingTests {
private ITestBean testBean; private ITestBean testBean;
@ -51,20 +51,20 @@ public final class AfterThrowingAdviceBindingTests {
afterThrowingAdviceAspect.setCollaborator(mockCollaborator); afterThrowingAdviceAspect.setCollaborator(mockCollaborator);
} }
@Test(expected=Throwable.class) @Test(expected = Throwable.class)
public void testSimpleAfterThrowing() throws Throwable { public void testSimpleAfterThrowing() throws Throwable {
this.testBean.exceptional(new Throwable()); this.testBean.exceptional(new Throwable());
verify(mockCollaborator).noArgs(); verify(mockCollaborator).noArgs();
} }
@Test(expected=Throwable.class) @Test(expected = Throwable.class)
public void testAfterThrowingWithBinding() throws Throwable { public void testAfterThrowingWithBinding() throws Throwable {
Throwable t = new Throwable(); Throwable t = new Throwable();
this.testBean.exceptional(t); this.testBean.exceptional(t);
verify(mockCollaborator).oneThrowable(t); verify(mockCollaborator).oneThrowable(t);
} }
@Test(expected=Throwable.class) @Test(expected = Throwable.class)
public void testAfterThrowingWithNamedTypeRestriction() throws Throwable { public void testAfterThrowingWithNamedTypeRestriction() throws Throwable {
Throwable t = new Throwable(); Throwable t = new Throwable();
this.testBean.exceptional(t); this.testBean.exceptional(t);
@ -73,20 +73,20 @@ public final class AfterThrowingAdviceBindingTests {
verify(mockCollaborator).noArgsOnThrowableMatch(); verify(mockCollaborator).noArgsOnThrowableMatch();
} }
@Test(expected=Throwable.class) @Test(expected = Throwable.class)
public void testAfterThrowingWithRuntimeExceptionBinding() throws Throwable { public void testAfterThrowingWithRuntimeExceptionBinding() throws Throwable {
RuntimeException ex = new RuntimeException(); RuntimeException ex = new RuntimeException();
this.testBean.exceptional(ex); this.testBean.exceptional(ex);
verify(mockCollaborator).oneRuntimeException(ex); verify(mockCollaborator).oneRuntimeException(ex);
} }
@Test(expected=Throwable.class) @Test(expected = Throwable.class)
public void testAfterThrowingWithTypeSpecified() throws Throwable { public void testAfterThrowingWithTypeSpecified() throws Throwable {
this.testBean.exceptional(new Throwable()); this.testBean.exceptional(new Throwable());
verify(mockCollaborator).noArgsOnThrowableMatch(); verify(mockCollaborator).noArgsOnThrowableMatch();
} }
@Test(expected=Throwable.class) @Test(expected = Throwable.class)
public void testAfterThrowingWithRuntimeTypeSpecified() throws Throwable { public void testAfterThrowingWithRuntimeTypeSpecified() throws Throwable {
this.testBean.exceptional(new RuntimeException()); this.testBean.exceptional(new RuntimeException());
verify(mockCollaborator).noArgsOnRuntimeExceptionMatch(); verify(mockCollaborator).noArgsOnRuntimeExceptionMatch();

View File

@ -26,7 +26,7 @@ import static org.junit.Assert.*;
* @author Juergen Hoeller * @author Juergen Hoeller
* @author Chris Beams * @author Chris Beams
*/ */
public final class AroundAdviceCircularTests extends AroundAdviceBindingTests { public class AroundAdviceCircularTests extends AroundAdviceBindingTests {
@Test @Test
public void testBothBeansAreProxies() { public void testBothBeansAreProxies() {

View File

@ -34,7 +34,7 @@ import static org.junit.Assert.*;
* @author Adrian Colyer * @author Adrian Colyer
* @author Chris Beams * @author Chris Beams
*/ */
public final class AspectAndAdvicePrecedenceTests { public class AspectAndAdvicePrecedenceTests {
private PrecedenceTestAspect highPrecedenceAspect; private PrecedenceTestAspect highPrecedenceAspect;

View File

@ -31,7 +31,7 @@ import static org.junit.Assert.*;
* @author Juergen Hoeller * @author Juergen Hoeller
* @author Chris Beams * @author Chris Beams
*/ */
public final class AspectJExpressionPointcutAdvisorTests { public class AspectJExpressionPointcutAdvisorTests {
private ITestBean testBean; private ITestBean testBean;

View File

@ -37,7 +37,7 @@ import static org.junit.Assert.*;
* @author Juergen Hoeller * @author Juergen Hoeller
* @author Chris Beams * @author Chris Beams
*/ */
public final class BeanNamePointcutTests { public class BeanNamePointcutTests {
private ITestBean testBean1; private ITestBean testBean1;
private ITestBean testBean2; private ITestBean testBean2;

View File

@ -36,7 +36,7 @@ import static org.mockito.BDDMockito.*;
* @author Rod Johnson * @author Rod Johnson
* @author Chris Beams * @author Chris Beams
*/ */
public final class BeforeAdviceBindingTests { public class BeforeAdviceBindingTests {
private AdviceBindingCollaborator mockCollaborator; private AdviceBindingCollaborator mockCollaborator;

View File

@ -31,7 +31,7 @@ import static org.junit.Assert.*;
* @author Adrian Colyer * @author Adrian Colyer
* @author Chris Beams * @author Chris Beams
*/ */
public final class DeclarationOrderIndependenceTests { public class DeclarationOrderIndependenceTests {
private TopsyTurvyAspect aspect; private TopsyTurvyAspect aspect;

View File

@ -33,7 +33,7 @@ import static org.junit.Assert.*;
* @author Rod Johnson * @author Rod Johnson
* @author Chris Beams * @author Chris Beams
*/ */
public final class DeclareParentsTests { public class DeclareParentsTests {
private ITestBean testBeanProxy; private ITestBean testBeanProxy;

View File

@ -30,7 +30,7 @@ import org.springframework.tests.sample.beans.TestBean;
* @author Ramnivas Laddad * @author Ramnivas Laddad
* @author Chris Beams * @author Chris Beams
*/ */
public final class ImplicitJPArgumentMatchingAtAspectJTests { public class ImplicitJPArgumentMatchingAtAspectJTests {
@Test @Test
public void testAspect() { public void testAspect() {

View File

@ -27,7 +27,7 @@ import org.springframework.context.support.ClassPathXmlApplicationContext;
* @author Ramnivas Laddad * @author Ramnivas Laddad
* @author Chris Beams * @author Chris Beams
*/ */
public final class ImplicitJPArgumentMatchingTests { public class ImplicitJPArgumentMatchingTests {
@Test @Test
public void testAspect() { public void testAspect() {

View File

@ -29,7 +29,7 @@ import static org.junit.Assert.*;
* @author Adrian Colyer * @author Adrian Colyer
* @author Chris Beams * @author Chris Beams
*/ */
public final class OverloadedAdviceTests { public class OverloadedAdviceTests {
@Test @Test
public void testExceptionOnConfigParsingWithMismatchedAdviceMethod() { public void testExceptionOnConfigParsingWithMismatchedAdviceMethod() {

View File

@ -33,7 +33,7 @@ import static org.junit.Assert.*;
* @author Adrian Colyer * @author Adrian Colyer
* @author Chris Beams * @author Chris Beams
*/ */
public final class ProceedTests { public class ProceedTests {
private SimpleBean testBean; private SimpleBean testBean;

View File

@ -36,7 +36,7 @@ import static org.junit.Assert.*;
* @author Chris Beams * @author Chris Beams
*/ */
@SuppressWarnings("resource") @SuppressWarnings("resource")
public final class PropertyDependentAspectTests { public class PropertyDependentAspectTests {
@Test @Test
public void propertyDependentAspectWithPropertyDeclaredBeforeAdvice() public void propertyDependentAspectWithPropertyDeclaredBeforeAdvice()

View File

@ -27,7 +27,7 @@ import org.springframework.context.support.ClassPathXmlApplicationContext;
* @author Adrian Colyer * @author Adrian Colyer
* @author Chris Beams * @author Chris Beams
*/ */
public final class SharedPointcutWithArgsMismatchTests { public class SharedPointcutWithArgsMismatchTests {
private ToBeAdvised toBeAdvised; private ToBeAdvised toBeAdvised;

View File

@ -30,7 +30,7 @@ import static org.junit.Assert.*;
* @author Adrian Colyer * @author Adrian Colyer
* @author Chris Beams * @author Chris Beams
*/ */
public final class SubtypeSensitiveMatchingTests { public class SubtypeSensitiveMatchingTests {
private NonSerializableFoo nonSerializableBean; private NonSerializableFoo nonSerializableBean;

View File

@ -33,7 +33,7 @@ import static org.junit.Assert.*;
* @author Ramnivas Laddad * @author Ramnivas Laddad
* @author Chris Beams * @author Chris Beams
*/ */
public final class TargetPointcutSelectionTests { public class TargetPointcutSelectionTests {
public TestInterface testImpl1; public TestInterface testImpl1;

View File

@ -30,7 +30,7 @@ import static org.junit.Assert.*;
* @author Ramnivas Laddad * @author Ramnivas Laddad
* @author Chris Beams * @author Chris Beams
*/ */
public final class ThisAndTargetSelectionOnlyPointcutsAtAspectJTests { public class ThisAndTargetSelectionOnlyPointcutsAtAspectJTests {
private TestInterface testBean; private TestInterface testBean;

View File

@ -27,7 +27,7 @@ import static org.junit.Assert.*;
* @author Ramnivas Laddad * @author Ramnivas Laddad
* @author Chris Beams * @author Chris Beams
*/ */
public final class ThisAndTargetSelectionOnlyPointcutsTests { public class ThisAndTargetSelectionOnlyPointcutsTests {
private TestInterface testBean; private TestInterface testBean;

View File

@ -29,7 +29,7 @@ import static org.junit.Assert.*;
* @author Juergen Hoeller * @author Juergen Hoeller
* @author Chris Beams * @author Chris Beams
*/ */
public final class AnnotationPointcutTests { public class AnnotationPointcutTests {
private AnnotatedTestBean testBean; private AnnotatedTestBean testBean;

View File

@ -31,7 +31,7 @@ import static org.junit.Assert.*;
* @author Ramnivas Laddad * @author Ramnivas Laddad
* @author Chris Beams * @author Chris Beams
*/ */
public final class AspectImplementingInterfaceTests { public class AspectImplementingInterfaceTests {
@Test @Test
public void testProxyCreation() { public void testProxyCreation() {

View File

@ -29,7 +29,7 @@ import static org.junit.Assert.*;
* @author Rob Harrop * @author Rob Harrop
* @author Chris Beams * @author Chris Beams
*/ */
public final class AspectJAutoProxyCreatorAndLazyInitTargetSourceTests { public class AspectJAutoProxyCreatorAndLazyInitTargetSourceTests {
@Test @Test
public void testAdrian() { public void testAdrian() {

View File

@ -68,7 +68,7 @@ import static org.junit.Assert.*;
* @author Chris Beams * @author Chris Beams
* @author Sam Brannen * @author Sam Brannen
*/ */
public final class AspectJAutoProxyCreatorTests { public class AspectJAutoProxyCreatorTests {
private static final Log factoryLog = LogFactory.getLog(DefaultListableBeanFactory.class); private static final Log factoryLog = LogFactory.getLog(DefaultListableBeanFactory.class);

View File

@ -33,7 +33,7 @@ import static org.junit.Assert.*;
* @author Chris Beams * @author Chris Beams
* @since 2.0 * @since 2.0
*/ */
public final class AtAspectJAfterThrowingTests { public class AtAspectJAfterThrowingTests {
@Test @Test
public void testAccessThrowable() throws Exception { public void testAccessThrowable() throws Exception {

View File

@ -33,7 +33,7 @@ import static org.junit.Assert.*;
* @author Juergen Hoeller * @author Juergen Hoeller
* @author Chris Beams * @author Chris Beams
*/ */
public final class AtAspectJAnnotationBindingTests { public class AtAspectJAnnotationBindingTests {
private AnnotatedTestBean testBean; private AnnotatedTestBean testBean;
private ClassPathXmlApplicationContext ctx; private ClassPathXmlApplicationContext ctx;

View File

@ -45,7 +45,7 @@ import static org.junit.Assert.*;
* @author Rod Johnson * @author Rod Johnson
* @author Chris Beams * @author Chris Beams
*/ */
public final class BenchmarkTests { public class BenchmarkTests {
private static final Class<?> CLASS = BenchmarkTests.class; private static final Class<?> CLASS = BenchmarkTests.class;

View File

@ -32,7 +32,7 @@ import static org.junit.Assert.*;
* @author Adrian Colyer * @author Adrian Colyer
* @author Chris Beams * @author Chris Beams
*/ */
public final class SPR3064Tests { public class SPR3064Tests {
private Service service; private Service service;

Some files were not shown because too many files have changed in this diff Show More