Merge pull request #27736 from izeye

* gh-27736:
  Polish "Polish access modifiers for test classes"
  Polish access modifiers for test classes

Closes gh-27736
This commit is contained in:
Andy Wilkinson 2021-08-18 17:52:58 +01:00
commit ea9f8516ce
61 changed files with 193 additions and 121 deletions

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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,7 +27,7 @@ import static org.assertj.core.api.Assertions.assertThat;
*
* @author Andy Wilkinson
*/
public class ArtifactoryRepositoryTests {
class ArtifactoryRepositoryTests {
@Test
void whenProjectVersionIsMilestoneThenRepositoryIsMilestone() {

View File

@ -38,14 +38,14 @@ import static org.assertj.core.api.Assertions.assertThat;
*
* @author Andy Wilkinson
*/
public class BomPluginIntegrationTests {
class BomPluginIntegrationTests {
private File projectDir;
private File buildFile;
@BeforeEach
public void setup(@TempDir File projectDir) throws IOException {
void setup(@TempDir File projectDir) throws IOException {
this.projectDir = projectDir;
this.buildFile = new File(this.projectDir, "build.gradle");
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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,7 +25,7 @@ import static org.assertj.core.api.Assertions.assertThat;
*
* @author Andy Wilkinson
*/
public class ArtifactVersionDependencyVersionTests {
class ArtifactVersionDependencyVersionTests {
@Test
void parseWhenVersionIsNotAMavenVersionShouldReturnNull() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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,7 +25,7 @@ import static org.assertj.core.api.Assertions.assertThat;
*
* @author Andy Wilkinson
*/
public class CalendarVersionDependencyVersionTests {
class CalendarVersionDependencyVersionTests {
@Test
void parseWhenVersionIsNotACalendarVersionShouldReturnNull() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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,7 +25,7 @@ import static org.assertj.core.api.Assertions.assertThat;
*
* @author Andy Wilkinson
*/
public class DependencyVersionTests {
class DependencyVersionTests {
@Test
void parseWhenValidMavenVersionShouldReturnArtifactVersionDependencyVersion() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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,7 +25,7 @@ import static org.assertj.core.api.Assertions.assertThat;
*
* @author Andy Wilkinson
*/
public class NumericQualifierDependencyVersionTests {
class NumericQualifierDependencyVersionTests {
@Test
void isNewerThanOnVersionWithNumericQualifierWhenInputHasNoQualifierShouldReturnTrue() {

View File

@ -25,7 +25,7 @@ import static org.assertj.core.api.Assertions.assertThat;
*
* @author Andy Wilkinson
*/
public class ReleaseTrainDependencyVersionTests {
class ReleaseTrainDependencyVersionTests {
@Test
void parsingOfANonReleaseTrainVersionReturnsNull() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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,7 +25,7 @@ import static org.assertj.core.api.Assertions.assertThat;
*
* @author Brian Clozel
*/
public class CompoundConfigurationTableEntryTests {
class CompoundConfigurationTableEntryTests {
private static final String NEWLINE = System.lineSeparator();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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,7 +25,7 @@ import static org.assertj.core.api.Assertions.assertThat;
*
* @author Brian Clozel
*/
public class ConfigurationTableTests {
class ConfigurationTableTests {
private static final String NEWLINE = System.lineSeparator();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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,7 +25,7 @@ import static org.assertj.core.api.Assertions.assertThat;
*
* @author Brian Clozel
*/
public class SingleConfigurationTableEntryTests {
class SingleConfigurationTableEntryTests {
private static final String NEWLINE = System.lineSeparator();

View File

@ -37,7 +37,7 @@ import static org.assertj.core.api.Assertions.assertThat;
*
* @author Andy Wilkinson
*/
public class ReproduciblePluginsDatActionTests {
class ReproduciblePluginsDatActionTests {
@Test
void postProcessingOrdersCategoriesAndPlugins() throws IOException {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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.
@ -33,7 +33,7 @@ import static org.assertj.core.api.Assertions.assertThatThrownBy;
* @author Andy Wilkinson
* @author Mike Smithson
*/
public class PluginXmlParserTests {
class PluginXmlParserTests {
private final PluginXmlParser parser = new PluginXmlParser();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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,14 +34,14 @@ import static org.assertj.core.api.Assertions.assertThat;
*
* @author Andy Wilkinson
*/
public class OptionalDependenciesPluginIntegrationTests {
class OptionalDependenciesPluginIntegrationTests {
private File projectDir;
private File buildFile;
@BeforeEach
public void setup(@TempDir File projectDir) throws IOException {
void setup(@TempDir File projectDir) throws IOException {
this.projectDir = projectDir;
this.buildFile = new File(this.projectDir, "build.gradle");
}
@ -80,7 +80,7 @@ public class OptionalDependenciesPluginIntegrationTests {
optionalDependenciesAreAddedToSourceSetClasspath("test", "runtimeClasspath");
}
public void optionalDependenciesAreAddedToSourceSetClasspath(String sourceSet, String classpath)
private void optionalDependenciesAreAddedToSourceSetClasspath(String sourceSet, String classpath)
throws IOException {
try (PrintWriter out = new PrintWriter(new FileWriter(this.buildFile))) {
out.println("plugins {");

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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.
@ -39,7 +39,7 @@ import static org.assertj.core.api.Assertions.assertThat;
*
* @author Andy Wilkinson
*/
public class DefaultWebMvcTagsProviderTests {
class DefaultWebMvcTagsProviderTests {
@Test
void whenTagsAreProvidedThenDefaultTagsArePresent() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2021 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,7 +25,7 @@ import static org.assertj.core.api.Assertions.assertThat;
*
* @author Andy Wilkinson
*/
public class OutcomeTests {
class OutcomeTests {
@Test
void outcomeForInformationalStatusIsInformational() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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.
@ -37,7 +37,7 @@ import static org.assertj.core.api.Assertions.assertThat;
*
* @author Andy Wilkinson
*/
public class DefaultWebFluxTagsProviderTests {
class DefaultWebFluxTagsProviderTests {
@Test
void whenTagsAreProvidedThenDefaultTagsArePresent() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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.
@ -35,7 +35,7 @@ import static org.assertj.core.api.Assertions.assertThatIllegalStateException;
* @author Oliver Gierke
*/
@SuppressWarnings("resource")
public class AutoConfigurationPackagesTests {
class AutoConfigurationPackagesTests {
@Test
void setAndGet() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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,6 +31,7 @@ import org.springframework.beans.factory.FactoryBean;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.beans.factory.support.BeanDefinitionBuilder;
import org.springframework.beans.factory.support.BeanDefinitionRegistry;
import org.springframework.boot.autoconfigure.condition.scan.ScanBean;
import org.springframework.boot.autoconfigure.condition.scan.ScannedFactoryBeanConfiguration;
import org.springframework.boot.autoconfigure.condition.scan.ScannedFactoryBeanWithBeanMethodArgumentsConfiguration;
import org.springframework.boot.autoconfigure.context.PropertyPlaceholderAutoConfiguration;
@ -60,7 +61,7 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Andy Wilkinson
*/
@SuppressWarnings("resource")
public class ConditionalOnMissingBeanTests {
class ConditionalOnMissingBeanTests {
private final ApplicationContextRunner contextRunner = new ApplicationContextRunner();
@ -161,7 +162,7 @@ public class ConditionalOnMissingBeanTests {
this.contextRunner
.withUserConfiguration(ComponentScannedFactoryBeanBeanMethodConfiguration.class,
ConditionalOnFactoryBean.class, PropertyPlaceholderAutoConfiguration.class)
.run((context) -> assertThat(context.getBean(ExampleBean.class).toString()).isEqualTo("fromFactory"));
.run((context) -> assertThat(context.getBean(ScanBean.class).toString()).isEqualTo("fromFactory"));
}
@Test
@ -169,7 +170,7 @@ public class ConditionalOnMissingBeanTests {
this.contextRunner
.withUserConfiguration(ComponentScannedFactoryBeanBeanMethodWithArgumentsConfiguration.class,
ConditionalOnFactoryBean.class, PropertyPlaceholderAutoConfiguration.class)
.run((context) -> assertThat(context.getBean(ExampleBean.class).toString()).isEqualTo("fromFactory"));
.run((context) -> assertThat(context.getBean(ScanBean.class).toString()).isEqualTo("fromFactory"));
}
@Test
@ -617,9 +618,9 @@ public class ConditionalOnMissingBeanTests {
}
public static class ExampleFactoryBean implements FactoryBean<ExampleBean> {
static class ExampleFactoryBean implements FactoryBean<ExampleBean> {
public ExampleFactoryBean(String value) {
ExampleFactoryBean(String value) {
Assert.state(!value.contains("$"), "value should not contain '$'");
}
@ -738,11 +739,11 @@ public class ConditionalOnMissingBeanTests {
}
@TestAnnotation
public static class ExampleBean {
static class ExampleBean {
private String value;
public ExampleBean(String value) {
ExampleBean(String value) {
this.value = value;
}

View File

@ -0,0 +1,32 @@
/*
* Copyright 2012-2021 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.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.boot.autoconfigure.condition.scan;
public class ScanBean {
private String value;
public ScanBean(String value) {
this.value = value;
}
@Override
public String toString() {
return this.value;
}
}

View File

@ -0,0 +1,43 @@
/*
* Copyright 2012-2021 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.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.boot.autoconfigure.condition.scan;
import org.springframework.beans.factory.FactoryBean;
import org.springframework.util.Assert;
class ScanFactoryBean implements FactoryBean<ScanBean> {
ScanFactoryBean(String value) {
Assert.state(!value.contains("$"), "value should not contain '$'");
}
@Override
public ScanBean getObject() {
return new ScanBean("fromFactory");
}
@Override
public Class<?> getObjectType() {
return ScanBean.class;
}
@Override
public boolean isSingleton() {
return false;
}
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2021 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.
@ -17,8 +17,6 @@
package org.springframework.boot.autoconfigure.condition.scan;
import org.springframework.beans.factory.FactoryBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBeanTests.ExampleBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBeanTests.ExampleFactoryBean;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
@ -32,8 +30,8 @@ import org.springframework.context.annotation.Configuration;
public class ScannedFactoryBeanConfiguration {
@Bean
public FactoryBean<ExampleBean> exampleBeanFactoryBean() {
return new ExampleFactoryBean("foo");
public FactoryBean<ScanBean> exampleBeanFactoryBean() {
return new ScanFactoryBean("foo");
}
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2021 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.
@ -16,7 +16,6 @@
package org.springframework.boot.autoconfigure.condition.scan;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBeanTests.ExampleFactoryBean;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
@ -35,8 +34,8 @@ public class ScannedFactoryBeanWithBeanMethodArgumentsConfiguration {
}
@Bean
public ExampleFactoryBean exampleBeanFactoryBean(Foo foo) {
return new ExampleFactoryBean("foo");
public ScanFactoryBean exampleBeanFactoryBean(Foo foo) {
return new ScanFactoryBean("foo");
}
static class Foo {

View File

@ -32,7 +32,7 @@ import static org.assertj.core.api.Assertions.assertThat;
*
* @author Andy Wilkinson
*/
public class LifecycleAutoConfigurationTests {
class LifecycleAutoConfigurationTests {
private final ApplicationContextRunner contextRunner = new ApplicationContextRunner()
.withConfiguration(AutoConfigurations.of(LifecycleAutoConfiguration.class));

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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.
@ -45,7 +45,7 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Brian Clozel
*/
@Testcontainers(disabledWithoutDocker = true)
public class ReactiveElasticsearchRepositoriesAutoConfigurationTests {
class ReactiveElasticsearchRepositoriesAutoConfigurationTests {
@Container
static ElasticsearchContainer elasticsearch = new ElasticsearchContainer(DockerImageNames.elasticsearch())

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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.
@ -45,7 +45,7 @@ import static org.mockito.Mockito.mock;
* @author Brian Clozel
*/
@Testcontainers(disabledWithoutDocker = true)
public class ReactiveElasticsearchRestClientAutoConfigurationTests {
class ReactiveElasticsearchRestClientAutoConfigurationTests {
@Container
static ElasticsearchContainer elasticsearch = new ElasticsearchContainer(DockerImageNames.elasticsearch())

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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,7 +40,7 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Stephane Nicoll
* @author Michael J. Simons
*/
public class Neo4jReactiveRepositoriesAutoConfigurationTests {
class Neo4jReactiveRepositoriesAutoConfigurationTests {
private final ApplicationContextRunner contextRunner = new ApplicationContextRunner()
.withUserConfiguration(MockedDriverConfiguration.class)

View File

@ -43,7 +43,7 @@ import static org.assertj.core.api.Assertions.assertThat;
*/
@SpringBootTest
@Testcontainers(disabledWithoutDocker = true)
public class Neo4jRepositoriesAutoConfigurationIntegrationTests {
class Neo4jRepositoriesAutoConfigurationIntegrationTests {
@Container
private static final Neo4jContainer<?> neo4jServer = new Neo4jContainer<>(DockerImageNames.neo4j())

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2021 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.
@ -37,7 +37,7 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Kazuki Shimizu
*/
@ExtendWith(OutputCaptureExtension.class)
public class FreeMarkerAutoConfigurationTests {
class FreeMarkerAutoConfigurationTests {
private final BuildOutput buildOutput = new BuildOutput(getClass());

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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.
@ -17,11 +17,10 @@
package org.springframework.boot.autoconfigure.packagestest.two;
import org.springframework.boot.autoconfigure.AutoConfigurationPackage;
import org.springframework.boot.autoconfigure.AutoConfigurationPackagesTests;
import org.springframework.context.annotation.Configuration;
/**
* Sample configuration used in {@link AutoConfigurationPackagesTests}.
* Sample configuration used in {@code AutoConfigurationPackagesTests}.
*
* @author Oliver Gierke
*/

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2021 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 @@ import org.springframework.web.servlet.config.annotation.EnableWebMvc;
*/
@DirtiesContext
@SpringBootTest(webEnvironment = WebEnvironment.DEFINED_PORT, properties = { "server.port=0", "value=123" })
public class SpringBootTestWebEnvironmentDefinedPortTests extends AbstractSpringBootTestWebServerWebEnvironmentTests {
class SpringBootTestWebEnvironmentDefinedPortTests extends AbstractSpringBootTestWebServerWebEnvironmentTests {
@Configuration(proxyBeanMethods = false)
@EnableWebMvc

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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.
@ -42,7 +42,7 @@ import static org.assertj.core.api.Assertions.assertThat;
@SpringBootTest
@ActiveProfiles({ "test1", "test2" })
@ContextConfiguration(loader = SpringBootTestWithActiveProfilesAndEnvironmentPropertyTests.Loader.class)
public class SpringBootTestWithActiveProfilesAndEnvironmentPropertyTests {
class SpringBootTestWithActiveProfilesAndEnvironmentPropertyTests {
@Autowired
private Environment environment;

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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.
@ -44,7 +44,7 @@ import static org.assertj.core.api.Assertions.assertThat;
@SpringBootTest
@ActiveProfiles({ "test1", "test2" })
@ContextConfiguration(loader = SpringBootTestWithActiveProfilesAndSystemEnvironmentPropertyTests.Loader.class)
public class SpringBootTestWithActiveProfilesAndSystemEnvironmentPropertyTests {
class SpringBootTestWithActiveProfilesAndSystemEnvironmentPropertyTests {
@Autowired
private Environment environment;

View File

@ -33,7 +33,7 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Andy Wilkinson
*/
@ClassPathExclusions({ "reactor-netty*.jar", "jetty-client*.jar" })
public class WebTestClientContextCustomizerWithoutSupportedHttpClientTests {
class WebTestClientContextCustomizerWithoutSupportedHttpClientTests {
@Test
void createContextCustomizerWhenNoSupportedHttpClientIsAvailableShouldReturnNull() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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,7 +34,7 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Stephane Nicoll
*/
@ClassPathExclusions("spring-webflux*.jar")
public class WebTestClientContextCustomizerWithoutWebfluxIntegrationTests {
class WebTestClientContextCustomizerWithoutWebfluxIntegrationTests {
@Test
void customizerIsNotCreatedWithoutWebClient() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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.
@ -44,7 +44,7 @@ import static org.assertj.core.api.Assertions.entry;
* @author Phillip Webb
* @author Scott Frederick
*/
public class BuildRequestTests {
class BuildRequestTests {
@TempDir
File tempDir;

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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.
@ -26,7 +26,7 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Wei Jiang
* @author Scott Frederick
*/
public class DockerConfigurationTests {
class DockerConfigurationTests {
@Test
void createDockerConfigurationWithDefaults() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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.
@ -29,7 +29,7 @@ import static org.assertj.core.api.Assertions.assertThat;
*
* @author Phillip Webb
*/
public class ImmutableNameAnnotationPropertiesTests extends AbstractMetadataGenerationTests {
class ImmutableNameAnnotationPropertiesTests extends AbstractMetadataGenerationTests {
@Test
void immutableNameAnnotationProperties() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2021 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,7 +28,7 @@ import org.springframework.boot.configurationprocessor.fieldvalues.FieldValuesPa
*
* @author Phillip Webb
*/
public class JavaCompilerFieldValuesProcessorTests extends AbstractFieldValuesProcessorTests {
class JavaCompilerFieldValuesProcessorTests extends AbstractFieldValuesProcessorTests {
@Override
protected FieldValuesParser createProcessor(ProcessingEnvironment env) {

View File

@ -49,7 +49,7 @@ import static org.assertj.core.api.Assertions.assertThat;
@GradleCompatibility
@Testcontainers(disabledWithoutDocker = true)
@Disabled("Disabled until differences between running locally and in CI can be diagnosed")
public class BootBuildImageRegistryIntegrationTests {
class BootBuildImageRegistryIntegrationTests {
@Container
static final RegistryContainer registry = new RegistryContainer().withStartupAttempts(5)

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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,7 +32,7 @@ import static org.assertj.core.api.Assertions.assertThatExceptionOfType;
* @author Wei Jiang
* @author Scott Frederick
*/
public class DockerSpecTests {
class DockerSpecTests {
@Test
void asDockerConfigurationWithDefaults() {

View File

@ -43,7 +43,7 @@ import static org.assertj.core.api.Assertions.assertThat;
@ExtendWith(MavenBuildExtension.class)
@Testcontainers(disabledWithoutDocker = true)
@Disabled("Disabled until differences between running locally and in CI can be diagnosed")
public class BuildImageRegistryIntegrationTests extends AbstractArchiveIntegrationTests {
class BuildImageRegistryIntegrationTests extends AbstractArchiveIntegrationTests {
@Container
static final RegistryContainer registry = new RegistryContainer().withStartupAttempts(5)

View File

@ -41,7 +41,7 @@ import static org.assertj.core.api.Assertions.assertThat;
*/
@ExtendWith(MavenBuildExtension.class)
@DisabledIfDockerUnavailable
public class BuildImageTests extends AbstractArchiveIntegrationTests {
class BuildImageTests extends AbstractArchiveIntegrationTests {
@TestTemplate
void whenBuildImageIsInvokedWithoutRepackageTheArchiveIsRepackagedOnTheFly(MavenBuild mavenBuild) {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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.
@ -37,7 +37,7 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Andy Wilkinson
*/
@ExtendWith(MavenBuildExtension.class)
public class BuildInfoIntegrationTests {
class BuildInfoIntegrationTests {
@TestTemplate
void buildInfoPropertiesAreGenerated(MavenBuild mavenBuild) {

View File

@ -32,7 +32,7 @@ import static org.assertj.core.api.Assertions.assertThat;
*
* @author Phillip Webb
*/
public class EclipseM2eIntegrationTests {
class EclipseM2eIntegrationTests {
@Test // gh-21992
void pluginPomIncludesOptionalShadeDependency() throws Exception {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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,7 +40,7 @@ import static org.mockito.Mockito.mock;
* @author Madhura Bhave
* @author Scott Frederick
*/
public class CustomLayersProviderTests {
class CustomLayersProviderTests {
private CustomLayersProvider customLayersProvider;

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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 @@ import static org.assertj.core.api.Assertions.assertThatIllegalArgumentException
* @author Wei Jiang
* @author Scott Frederick
*/
public class DockerTests {
class DockerTests {
@Test
void asDockerConfigurationWithDefaults() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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.
@ -37,7 +37,7 @@ import static org.mockito.Mockito.mock;
* @author Madhura Bhave
* @author Phillip Webb
*/
public class ConfigTreeConfigDataLoaderTests {
class ConfigTreeConfigDataLoaderTests {
private ConfigTreeConfigDataLoader loader = new ConfigTreeConfigDataLoader();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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,7 +30,7 @@ import static org.assertj.core.api.Assertions.assertThatIllegalArgumentException
* @author Madhura Bhave
* @author Phillip Webb
*/
public class ConfigTreeConfigDataResourceTests {
class ConfigTreeConfigDataResourceTests {
@Test
void constructorWhenPathStringIsNullThrowsException() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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,7 +34,7 @@ import static org.mockito.Mockito.mock;
* @author Madhura Bhave
* @author Phillip Webb
*/
public class StandardConfigDataLoaderTests {
class StandardConfigDataLoaderTests {
private StandardConfigDataLoader loader = new StandardConfigDataLoader();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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.
@ -44,7 +44,7 @@ import static org.mockito.Mockito.mock;
* @author Madhura Bhave
* @author Phillip Webb
*/
public class StandardConfigDataLocationResolverTests {
class StandardConfigDataLocationResolverTests {
private StandardConfigDataLocationResolver resolver;

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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 @@ import static org.mockito.Mockito.mock;
* @author Madhura Bhave
* @author Phillip Webb
*/
public class StandardConfigDataResourceTests {
class StandardConfigDataResourceTests {
StandardConfigDataReference reference = mock(StandardConfigDataReference.class);

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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.
@ -41,7 +41,7 @@ import static org.mockito.Mockito.verify;
* @author Madhura Bhave
*/
@ExtendWith(MockitoExtension.class)
public class BoundPropertiesTrackingBindHandlerTests {
class BoundPropertiesTrackingBindHandlerTests {
private List<ConfigurationPropertySource> sources = new ArrayList<>();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2021 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.
@ -21,7 +21,7 @@ package org.springframework.boot.json;
*
* @author Dave Syer
*/
public class BasicJsonParserTests extends AbstractJsonParserTests {
class BasicJsonParserTests extends AbstractJsonParserTests {
@Override
protected JsonParser getParser() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2021 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.
@ -21,7 +21,7 @@ package org.springframework.boot.json;
*
* @author Dave Syer
*/
public class GsonJsonParserTests extends AbstractJsonParserTests {
class GsonJsonParserTests extends AbstractJsonParserTests {
@Override
protected JsonParser getParser() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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.
@ -26,7 +26,7 @@ import static org.assertj.core.api.Assertions.assertThatExceptionOfType;
*
* @author Dave Syer
*/
public class YamlJsonParserTests extends AbstractJsonParserTests {
class YamlJsonParserTests extends AbstractJsonParserTests {
@Override
protected JsonParser getParser() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2021 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.
@ -43,7 +43,7 @@ import static org.mockito.Mockito.mock;
* @author Ilya Lukyanovich
* @author Phillip Webb
*/
public class RestTemplateBuilderClientHttpRequestInitializerTests {
class RestTemplateBuilderClientHttpRequestInitializerTests {
private final MockClientHttpRequest request = new MockClientHttpRequest();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2021 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.
@ -29,7 +29,7 @@ import static org.mockito.Mockito.mock;
*
* @author Phillip Webb
*/
public class WebServerApplicationContextTests {
class WebServerApplicationContextTests {
@Test
void hasServerNamespaceWhenContextIsNotWebServerApplicationContextReturnsFalse() {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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,7 +30,7 @@ import static org.mockito.ArgumentMatchers.eq;
* @author Andy Wilkinson
*/
@ClassPathExclusions("spring-web-*.jar")
public class NoSpringWebFilterRegistrationBeanTests extends AbstractFilterRegistrationBeanTests {
class NoSpringWebFilterRegistrationBeanTests extends AbstractFilterRegistrationBeanTests {
private final MockFilter filter = new MockFilter();

View File

@ -25,6 +25,6 @@ import org.springframework.test.context.TestPropertySource;
* @author Andy Wilkinson
*/
@TestPropertySource(properties = { "spring.jersey.type=filter", "server.servlet.register-default-servlet=true" })
public class JerseyFilterManagementPortTests extends AbstractJerseyManagementPortTests {
class JerseyFilterManagementPortTests extends AbstractJerseyManagementPortTests {
}

View File

@ -22,6 +22,6 @@ package smoketest.jersey;
*
* @author Andy Wilkinson
*/
public class JerseyServletManagementPortTests extends AbstractJerseyManagementPortTests {
class JerseyServletManagementPortTests extends AbstractJerseyManagementPortTests {
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2012-2020 the original author or authors.
* Copyright 2012-2021 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 @@ import org.springframework.security.rsocket.metadata.UsernamePasswordMetadata;
import org.springframework.util.MimeTypeUtils;
@SpringBootTest(properties = "spring.rsocket.server.port=0")
public class SampleRSocketApplicationTests {
class SampleRSocketApplicationTests {
@LocalRSocketServerPort
private int port;