Consistent use of @AliasFor

Closes gh-10836
This commit is contained in:
Stephane Nicoll
2017-12-13 14:42:16 +01:00
parent 47c8b5731a
commit a626f5462d
5 changed files with 12 additions and 2 deletions

View File

@@ -24,6 +24,7 @@ import java.lang.annotation.Target;
import org.springframework.boot.context.TypeExcludeFilter;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.core.annotation.AliasFor;
import org.springframework.stereotype.Component;
/**
@@ -50,6 +51,7 @@ public @interface TestComponent {
* a Spring bean in case of an auto-detected component.
* @return the specified bean name, if any
*/
@AliasFor(annotation = Component.class)
String value() default "";
}

View File

@@ -24,6 +24,7 @@ import java.lang.annotation.Target;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.context.annotation.Configuration;
import org.springframework.core.annotation.AliasFor;
/**
* {@link Configuration @Configuration} that can be used to define additional beans or
@@ -47,6 +48,7 @@ public @interface TestConfiguration {
* Configuration class. See {@link Configuration#value()} for details.
* @return the specified bean name, if any
*/
@AliasFor(annotation = Configuration.class)
String value() default "";
}