mirror of
https://github.com/spring-projects/spring-boot.git
synced 2024-08-29 03:06:45 +08:00
Fix configLocationsWithConfigurationFileSystemProperty
See gh-32740
This commit is contained in:
parent
1481676b54
commit
6b385a4f79
@ -314,8 +314,8 @@ class Log4J2LoggingSystemTests extends AbstractLoggingSystemTests {
|
||||
void configLocationsWithConfigurationFileSystemProperty() {
|
||||
System.setProperty(ConfigurationFactory.CONFIGURATION_FILE_PROPERTY, "custom-log4j2.properties");
|
||||
try {
|
||||
assertThat(this.loggingSystem.getStandardConfigLocations()).contains("log4j2-test.properties",
|
||||
"log4j2-test.xml", "log4j2.properties", "log4j2.xml");
|
||||
assertThat(this.loggingSystem.getStandardConfigLocations()).containsExactly("log4j2-test.properties",
|
||||
"log4j2-test.xml", "log4j2.properties", "log4j2.xml", "custom-log4j2.properties");
|
||||
}
|
||||
finally {
|
||||
System.clearProperty(ConfigurationFactory.CONFIGURATION_FILE_PROPERTY);
|
||||
|
Loading…
Reference in New Issue
Block a user