ResolvableType-based matching respects generic factory method return type
Includes consistent use of ResolvableType.resolve() wherever applicable. Issue: SPR-15011
This commit is contained in:
@@ -1295,7 +1295,6 @@ public class AutowiredAnnotationBeanPostProcessorTests {
|
||||
}
|
||||
catch (UnsatisfiedDependencyException ex) {
|
||||
// expected
|
||||
ex.printStackTrace();
|
||||
assertSame(CustomAnnotationRequiredFieldResourceInjectionBean.class,
|
||||
ex.getInjectionPoint().getField().getDeclaringClass());
|
||||
}
|
||||
@@ -1681,9 +1680,6 @@ public class AutowiredAnnotationBeanPostProcessorTests {
|
||||
assertSame(ir, bean.integerRepositoryMap.get("integerRepository"));
|
||||
}
|
||||
|
||||
@Qualifier("integerRepo")
|
||||
private Repository<?> integerRepositoryQualifierProvider;
|
||||
|
||||
@Test
|
||||
public void testGenericsBasedFieldInjectionWithSimpleMatch() {
|
||||
DefaultListableBeanFactory bf = new DefaultListableBeanFactory();
|
||||
@@ -2194,6 +2190,10 @@ public class AutowiredAnnotationBeanPostProcessorTests {
|
||||
}
|
||||
|
||||
|
||||
@Qualifier("integerRepo")
|
||||
private Repository<?> integerRepositoryQualifierProvider;
|
||||
|
||||
|
||||
public static class ResourceInjectionBean {
|
||||
|
||||
@Autowired(required = false)
|
||||
|
||||
Reference in New Issue
Block a user