From 771503f30d59cbe39a54fa6f507f89e4cd83dbfd Mon Sep 17 00:00:00 2001 From: Phillip Webb Date: Sun, 25 Oct 2020 09:20:57 -0700 Subject: [PATCH] Attempt to fix flaky logging tests --- .../boot/logging/logback/LogbackLoggingSystemTests.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/spring-boot-project/spring-boot/src/test/java/org/springframework/boot/logging/logback/LogbackLoggingSystemTests.java b/spring-boot-project/spring-boot/src/test/java/org/springframework/boot/logging/logback/LogbackLoggingSystemTests.java index 174c07fed3..ee4ff92d80 100644 --- a/spring-boot-project/spring-boot/src/test/java/org/springframework/boot/logging/logback/LogbackLoggingSystemTests.java +++ b/spring-boot-project/spring-boot/src/test/java/org/springframework/boot/logging/logback/LogbackLoggingSystemTests.java @@ -93,6 +93,8 @@ class LogbackLoggingSystemTests extends AbstractLoggingSystemTests { @BeforeEach void setup() { + System.getProperties().remove(LoggingSystemProperties.CONSOLE_LOG_CHARSET); + System.getProperties().remove(LoggingSystemProperties.FILE_LOG_CHARSET); this.systemPropertyNames = new HashSet<>(System.getProperties().keySet()); this.loggingSystem.cleanUp(); this.logger = ((LoggerContext) StaticLoggerBinder.getSingleton().getLoggerFactory()).getLogger(getClass());