Use tabs rather than spaces in tests
Update tests to ensure that tabs are used instead of spaces. Also consistently apply a new line at the end of each file. Issue: SPR-16968
This commit is contained in:
committed by
Juergen Hoeller
parent
1c25cec44f
commit
a89e716cc7
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2017 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -34,4 +34,4 @@ public @interface DevComponent {
|
||||
|
||||
String value() default "";
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2011 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -22,4 +22,4 @@ import org.springframework.context.annotation.ScopedProxyMode;
|
||||
public @interface MyScope {
|
||||
String value() default BeanDefinition.SCOPE_SINGLETON;
|
||||
ScopedProxyMode proxyMode() default ScopedProxyMode.DEFAULT;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2013 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -77,24 +77,24 @@ public class AspectAndAdvicePrecedenceTests {
|
||||
private static final String[] EXPECTED = {
|
||||
// this order confirmed by running the same aspects (minus the Spring AOP advisors)
|
||||
// through AspectJ...
|
||||
"beforeAdviceOne(highPrecedenceAspect)", // 1
|
||||
"beforeAdviceTwo(highPrecedenceAspect)", // 2
|
||||
"aroundAdviceOne(highPrecedenceAspect)", // 3, before proceed
|
||||
"aroundAdviceTwo(highPrecedenceAspect)", // 4, before proceed
|
||||
"beforeAdviceOne(highPrecedenceSpringAdvice)", // 5
|
||||
"beforeAdviceOne(lowPrecedenceSpringAdvice)", // 6
|
||||
"beforeAdviceOne(lowPrecedenceAspect)", // 7
|
||||
"beforeAdviceTwo(lowPrecedenceAspect)", // 8
|
||||
"aroundAdviceOne(lowPrecedenceAspect)", // 9, before proceed
|
||||
"aroundAdviceTwo(lowPrecedenceAspect)", // 10, before proceed
|
||||
"aroundAdviceTwo(lowPrecedenceAspect)", // 11, after proceed
|
||||
"aroundAdviceOne(lowPrecedenceAspect)", // 12, after proceed
|
||||
"afterAdviceOne(lowPrecedenceAspect)", // 13
|
||||
"afterAdviceTwo(lowPrecedenceAspect)", // 14
|
||||
"aroundAdviceTwo(highPrecedenceAspect)", // 15, after proceed
|
||||
"aroundAdviceOne(highPrecedenceAspect)", // 16, after proceed
|
||||
"afterAdviceOne(highPrecedenceAspect)", // 17
|
||||
"afterAdviceTwo(highPrecedenceAspect)" // 18
|
||||
"beforeAdviceOne(highPrecedenceAspect)", // 1
|
||||
"beforeAdviceTwo(highPrecedenceAspect)", // 2
|
||||
"aroundAdviceOne(highPrecedenceAspect)", // 3, before proceed
|
||||
"aroundAdviceTwo(highPrecedenceAspect)", // 4, before proceed
|
||||
"beforeAdviceOne(highPrecedenceSpringAdvice)", // 5
|
||||
"beforeAdviceOne(lowPrecedenceSpringAdvice)", // 6
|
||||
"beforeAdviceOne(lowPrecedenceAspect)", // 7
|
||||
"beforeAdviceTwo(lowPrecedenceAspect)", // 8
|
||||
"aroundAdviceOne(lowPrecedenceAspect)", // 9, before proceed
|
||||
"aroundAdviceTwo(lowPrecedenceAspect)", // 10, before proceed
|
||||
"aroundAdviceTwo(lowPrecedenceAspect)", // 11, after proceed
|
||||
"aroundAdviceOne(lowPrecedenceAspect)", // 12, after proceed
|
||||
"afterAdviceOne(lowPrecedenceAspect)", // 13
|
||||
"afterAdviceTwo(lowPrecedenceAspect)", // 14
|
||||
"aroundAdviceTwo(highPrecedenceAspect)", // 15, after proceed
|
||||
"aroundAdviceOne(highPrecedenceAspect)", // 16, after proceed
|
||||
"afterAdviceOne(highPrecedenceAspect)", // 17
|
||||
"afterAdviceTwo(highPrecedenceAspect)" // 18
|
||||
};
|
||||
|
||||
private int adviceInvocationNumber = 0;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2013 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -74,4 +74,4 @@ class CallCountingInterceptor implements MethodInterceptor {
|
||||
public void reset() {
|
||||
this.count = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2013 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -91,4 +91,4 @@ class NonAnnotatedMakeLockable {
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2015 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -148,4 +148,4 @@ class JoinPointMonitorAtAspectJAspect {
|
||||
this.counter = counter;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2012 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -95,4 +95,4 @@ class SubtypeMatchingTestClassC implements Bar {
|
||||
@Override
|
||||
public void bar(Object o) {}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2012 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -119,4 +119,4 @@ class TestImpl implements TestInterface {
|
||||
@Override
|
||||
public void doIt() {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2012 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -99,4 +99,4 @@ class ResourceArrayFactoryBean implements FactoryBean<Object> {
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2014 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -31,4 +31,4 @@ public class AnnotationDrivenCacheConfigTests extends AbstractCacheAnnotationTes
|
||||
"/org/springframework/cache/config/annotationDrivenCacheConfig.xml");
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2014 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -28,19 +28,19 @@ import org.springframework.cache.interceptor.KeyGenerator;
|
||||
*/
|
||||
public class SomeCustomKeyGenerator implements KeyGenerator {
|
||||
|
||||
@Override
|
||||
public Object generate(Object target, Method method, Object... params) {
|
||||
return generateKey(method.getName(), params);
|
||||
}
|
||||
@Override
|
||||
public Object generate(Object target, Method method, Object... params) {
|
||||
return generateKey(method.getName(), params);
|
||||
}
|
||||
|
||||
/**
|
||||
* @see #generate(Object, java.lang.reflect.Method, Object...)
|
||||
*/
|
||||
static Object generateKey(String methodName, Object... params) {
|
||||
final StringBuilder sb = new StringBuilder(methodName);
|
||||
for (Object param : params) {
|
||||
sb.append(param);
|
||||
}
|
||||
return sb.toString();
|
||||
}
|
||||
/**
|
||||
* @see #generate(Object, java.lang.reflect.Method, Object...)
|
||||
*/
|
||||
static Object generateKey(String methodName, Object... params) {
|
||||
final StringBuilder sb = new StringBuilder(methodName);
|
||||
for (Object param : params) {
|
||||
sb.append(param);
|
||||
}
|
||||
return sb.toString();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2008 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -27,4 +27,4 @@ public class DoubleScanTests extends SimpleScanTests {
|
||||
return new String[] {"doubleScanTests.xml"};
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -394,7 +394,7 @@ public class ImportSelectorTests {
|
||||
public Iterable<Entry> selectImports() {
|
||||
LinkedList<Entry> content = new LinkedList<>();
|
||||
TestImportGroup.imports.forEach((metadata, values) ->
|
||||
values.forEach(value -> content.add(new Entry(metadata, value))));
|
||||
values.forEach(value -> content.add(new Entry(metadata, value))));
|
||||
Collections.reverse(content);
|
||||
return content;
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2017 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -31,7 +31,7 @@ public class Spr16217Tests {
|
||||
@Ignore("TODO")
|
||||
public void baseConfigurationIsIncludedWhenFirstSuperclassReferenceIsSkippedInRegisterBeanPhase() {
|
||||
try (AnnotationConfigApplicationContext context =
|
||||
new AnnotationConfigApplicationContext(RegisterBeanPhaseImportingConfiguration.class)) {
|
||||
new AnnotationConfigApplicationContext(RegisterBeanPhaseImportingConfiguration.class)) {
|
||||
context.getBean("someBean");
|
||||
}
|
||||
}
|
||||
@@ -39,7 +39,7 @@ public class Spr16217Tests {
|
||||
@Test
|
||||
public void baseConfigurationIsIncludedWhenFirstSuperclassReferenceIsSkippedInParseConfigurationPhase() {
|
||||
try (AnnotationConfigApplicationContext context =
|
||||
new AnnotationConfigApplicationContext(ParseConfigurationPhaseImportingConfiguration.class)) {
|
||||
new AnnotationConfigApplicationContext(ParseConfigurationPhaseImportingConfiguration.class)) {
|
||||
context.getBean("someBean");
|
||||
}
|
||||
}
|
||||
@@ -58,7 +58,7 @@ public class Spr16217Tests {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
public static class RegisterBeanPhaseCondition implements ConfigurationCondition {
|
||||
|
||||
@Override
|
||||
@@ -72,7 +72,7 @@ public class Spr16217Tests {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
public static class ParseConfigurationPhaseCondition implements ConfigurationCondition {
|
||||
|
||||
@Override
|
||||
@@ -91,7 +91,7 @@ public class Spr16217Tests {
|
||||
public static class RegisterBeanPhaseImportingConfiguration {
|
||||
}
|
||||
|
||||
|
||||
|
||||
@Import({ParseConfigurationPhaseConditionConfiguration.class, BarConfiguration.class})
|
||||
public static class ParseConfigurationPhaseImportingConfiguration {
|
||||
}
|
||||
@@ -101,7 +101,7 @@ public class Spr16217Tests {
|
||||
public static class UnconditionalImportingConfiguration {
|
||||
}
|
||||
|
||||
|
||||
|
||||
public static class BaseConfiguration {
|
||||
|
||||
@Bean
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2013 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -28,4 +28,4 @@ public class Level1Config {
|
||||
public TestBean level1Bean() {
|
||||
return new TestBean("level1Bean");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2011 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -40,4 +40,4 @@ public abstract class BaseConfig {
|
||||
public Bar workaroundBar() {
|
||||
return protectedBar();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2013 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -25,4 +25,4 @@ import org.springframework.stereotype.Component;
|
||||
@Role(BeanDefinition.ROLE_INFRASTRUCTURE)
|
||||
@Description("A Component with a role")
|
||||
public class ComponentWithRole {
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2011 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -20,4 +20,4 @@ import org.springframework.stereotype.Component;
|
||||
|
||||
@Component("componentWithoutRole")
|
||||
public class ComponentWithoutRole {
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2016 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -127,4 +127,4 @@ public class FactoryBeanAccessTests {
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2016 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -95,4 +95,4 @@ public class MapAccessorTests {
|
||||
return map2;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2017 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -117,4 +117,4 @@ public class LiveBeansViewTests {
|
||||
return ManagementFactory.getPlatformMBeanServer().queryNames(new ObjectName(objectName), null);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2016 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -125,7 +125,7 @@ public class MBeanExporterTests extends AbstractMBeanServerTests {
|
||||
ObjectNameManager.getInstance(OBJECT_NAME));
|
||||
}
|
||||
finally {
|
||||
exporter.destroy();
|
||||
exporter.destroy();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -148,7 +148,7 @@ public class MBeanExporterTests extends AbstractMBeanServerTests {
|
||||
assertFalse("Assembler should not have been invoked", asm.invoked);
|
||||
}
|
||||
finally {
|
||||
exporter.destroy();
|
||||
exporter.destroy();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package org.springframework.scripting.groovy;
|
||||
|
||||
public interface TestService {
|
||||
public String sayHello();
|
||||
|
||||
public String sayHello();
|
||||
}
|
||||
|
||||
@@ -2,8 +2,9 @@ package org.springframework.scripting.groovy;
|
||||
|
||||
@Log
|
||||
public class TestServiceImpl implements TestService{
|
||||
@Override
|
||||
public String sayHello() {
|
||||
throw new TestException("TestServiceImpl");
|
||||
}
|
||||
|
||||
@Override
|
||||
public String sayHello() {
|
||||
throw new TestException("TestServiceImpl");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2005 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -49,4 +49,4 @@ public class TestMethodInvokingTask {
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2005 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -32,4 +32,4 @@ public class BeanWithObjectProperty {
|
||||
this.object = object;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2014 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -40,4 +40,4 @@ public class FieldAccessBean {
|
||||
return spouse;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -47,4 +47,4 @@ public class PerTargetAspect implements Ordered {
|
||||
public void setOrder(int order) {
|
||||
this.order = order;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2012 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package test.mixin;
|
||||
package test.mixin;
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2012 the original author or authors.
|
||||
* Copyright 2002-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -30,4 +30,4 @@ public interface Lockable {
|
||||
void unlock();
|
||||
|
||||
boolean locked();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user