Skip to content

Commit 3e376b9

Browse files
committed
Fix build failure
See gh-24943
1 parent 56ce5bd commit 3e376b9

File tree

8 files changed

+22
-21
lines changed

8 files changed

+22
-21
lines changed

spring-boot-project/spring-boot-actuator-autoconfigure/src/test/java/org/springframework/boot/actuate/autoconfigure/integrationtest/WebEndpointsAutoConfigurationIntegrationTests.java

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2012-2020 the original author or authors.
2+
* Copyright 2012-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -33,7 +33,6 @@
3333
import org.springframework.boot.autoconfigure.data.redis.RedisAutoConfiguration;
3434
import org.springframework.boot.autoconfigure.data.redis.RedisRepositoriesAutoConfiguration;
3535
import org.springframework.boot.autoconfigure.data.rest.RepositoryRestMvcAutoConfiguration;
36-
import org.springframework.boot.autoconfigure.data.solr.SolrRepositoriesAutoConfiguration;
3736
import org.springframework.boot.autoconfigure.flyway.FlywayAutoConfiguration;
3837
import org.springframework.boot.autoconfigure.hazelcast.HazelcastAutoConfiguration;
3938
import org.springframework.boot.autoconfigure.liquibase.LiquibaseAutoConfiguration;
@@ -80,10 +79,12 @@ private ReactiveWebApplicationContextRunner reactiveWebRunner() {
8079
Neo4jRepositoriesAutoConfiguration.class, MongoAutoConfiguration.class, MongoDataAutoConfiguration.class,
8180
MongoReactiveAutoConfiguration.class, MongoReactiveDataAutoConfiguration.class,
8281
RepositoryRestMvcAutoConfiguration.class, HazelcastAutoConfiguration.class,
83-
ElasticsearchDataAutoConfiguration.class, SolrRepositoriesAutoConfiguration.class,
82+
ElasticsearchDataAutoConfiguration.class,
83+
org.springframework.boot.autoconfigure.data.solr.SolrRepositoriesAutoConfiguration.class,
8484
SolrAutoConfiguration.class, RedisAutoConfiguration.class, RedisRepositoriesAutoConfiguration.class,
8585
MetricsAutoConfiguration.class })
8686
@SpringBootConfiguration
87+
@SuppressWarnings("deprecation")
8788
static class WebEndpointTestApplication {
8889

8990
}

spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/data/solr/SolrRepositoriesAutoConfiguration.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2012-2019 the original author or authors.
2+
* Copyright 2012-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.

spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/data/solr/SolrRepositoriesRegistrar.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2012-2019 the original author or authors.
2+
* Copyright 2012-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.

spring-boot-project/spring-boot-autoconfigure/src/test/java/org/springframework/boot/autoconfigure/data/alt/solr/CitySolrRepository.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2012-2019 the original author or authors.
2+
* Copyright 2012-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -16,10 +16,10 @@
1616

1717
package org.springframework.boot.autoconfigure.data.alt.solr;
1818

19-
import org.springframework.boot.autoconfigure.data.solr.city.City;
2019
import org.springframework.data.repository.Repository;
2120

2221
@Deprecated
23-
public interface CitySolrRepository extends Repository<City, String> {
22+
public interface CitySolrRepository
23+
extends Repository<org.springframework.boot.autoconfigure.data.solr.city.City, String> {
2424

2525
}

spring-boot-project/spring-boot-autoconfigure/src/test/java/org/springframework/boot/autoconfigure/data/jpa/JpaRepositoriesAutoConfigurationTests.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2012-2020 the original author or authors.
2+
* Copyright 2012-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.

spring-boot-project/spring-boot-autoconfigure/src/test/java/org/springframework/boot/autoconfigure/data/solr/SolrRepositoriesAutoConfigurationTests.java

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2012-2019 the original author or authors.
2+
* Copyright 2012-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -24,10 +24,7 @@
2424
import org.springframework.beans.factory.NoSuchBeanDefinitionException;
2525
import org.springframework.boot.autoconfigure.TestAutoConfigurationPackage;
2626
import org.springframework.boot.autoconfigure.context.PropertyPlaceholderAutoConfiguration;
27-
import org.springframework.boot.autoconfigure.data.alt.solr.CitySolrRepository;
2827
import org.springframework.boot.autoconfigure.data.empty.EmptyDataPackage;
29-
import org.springframework.boot.autoconfigure.data.solr.city.City;
30-
import org.springframework.boot.autoconfigure.data.solr.city.CityRepository;
3128
import org.springframework.boot.autoconfigure.solr.SolrAutoConfiguration;
3229
import org.springframework.context.annotation.AnnotationConfigApplicationContext;
3330
import org.springframework.context.annotation.Configuration;
@@ -55,7 +52,8 @@ void close() {
5552
@Test
5653
void testDefaultRepositoryConfiguration() {
5754
initContext(TestConfiguration.class);
58-
assertThat(this.context.getBean(CityRepository.class)).isNotNull();
55+
assertThat(this.context.getBean(org.springframework.boot.autoconfigure.data.solr.city.CityRepository.class))
56+
.isNotNull();
5957
assertThat(this.context.getBean(SolrClient.class)).isInstanceOf(HttpSolrClient.class);
6058
}
6159

@@ -68,14 +66,15 @@ void testNoRepositoryConfiguration() {
6866
@Test
6967
void doesNotTriggerDefaultRepositoryDetectionIfCustomized() {
7068
initContext(CustomizedConfiguration.class);
71-
assertThat(this.context.getBean(CitySolrRepository.class)).isNotNull();
69+
assertThat(this.context.getBean(org.springframework.boot.autoconfigure.data.solr.city.CityRepository.class))
70+
.isNotNull();
7271
}
7372

7473
@Test
7574
void autoConfigurationShouldNotKickInEvenIfManualConfigDidNotCreateAnyRepositories() {
7675
initContext(SortOfInvalidCustomConfiguration.class);
77-
assertThatExceptionOfType(NoSuchBeanDefinitionException.class)
78-
.isThrownBy(() -> this.context.getBean(CityRepository.class));
76+
assertThatExceptionOfType(NoSuchBeanDefinitionException.class).isThrownBy(
77+
() -> this.context.getBean(org.springframework.boot.autoconfigure.data.solr.city.CityRepository.class));
7978
}
8079

8180
private void initContext(Class<?> configClass) {
@@ -87,7 +86,7 @@ private void initContext(Class<?> configClass) {
8786
}
8887

8988
@Configuration(proxyBeanMethods = false)
90-
@TestAutoConfigurationPackage(City.class)
89+
@TestAutoConfigurationPackage(org.springframework.boot.autoconfigure.data.solr.city.City.class)
9190
static class TestConfiguration {
9291

9392
}
@@ -100,7 +99,8 @@ static class EmptyConfiguration {
10099

101100
@Configuration(proxyBeanMethods = false)
102101
@TestAutoConfigurationPackage(SolrRepositoriesAutoConfigurationTests.class)
103-
@EnableSolrRepositories(basePackageClasses = CitySolrRepository.class)
102+
@EnableSolrRepositories(
103+
basePackageClasses = org.springframework.boot.autoconfigure.data.solr.city.CityRepository.class)
104104
static class CustomizedConfiguration {
105105

106106
}

spring-boot-project/spring-boot-autoconfigure/src/test/java/org/springframework/boot/autoconfigure/data/solr/city/City.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2012-2019 the original author or authors.
2+
* Copyright 2012-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.

spring-boot-project/spring-boot-autoconfigure/src/test/java/org/springframework/boot/autoconfigure/data/solr/city/CityRepository.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2012-2019 the original author or authors.
2+
* Copyright 2012-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.

0 commit comments

Comments
 (0)