Skip to content

Commit 59ee5cb

Browse files
committed
Do not restore locale to the unusable one
1 parent 7d068cf commit 59ee5cb

File tree

1 file changed

+0
-11
lines changed

1 file changed

+0
-11
lines changed

test/framework/src/main/java/org/elasticsearch/test/ESTestCase.java

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -193,8 +193,6 @@ public abstract class ESTestCase extends LuceneTestCase {
193193

194194
private static final Collection<String> nettyLoggedLeaks = new ArrayList<>();
195195

196-
private static Locale restoreLocale;
197-
198196
@AfterClass
199197
public static void resetPortCounter() {
200198
portGenerator.set(0);
@@ -335,19 +333,10 @@ public static void ensureSupportedLocale() {
335333
Logger logger = LogManager.getLogger(ESTestCase.class);
336334
logger.warn("Attempting to run tests in an unusable locale in a FIPS JVM. Certificate expiration validation will fail, " +
337335
"switching to English. See: https://github.com/bcgit/bc-java/issues/405");
338-
restoreLocale = Locale.getDefault();
339336
Locale.setDefault(Locale.ENGLISH);
340337
}
341338
}
342339

343-
@AfterClass
344-
public static void restoreLocale() {
345-
if (restoreLocale != null) {
346-
Locale.setDefault(restoreLocale);
347-
restoreLocale = null;
348-
}
349-
}
350-
351340
@Before
352341
public final void before() {
353342
logger.info("{}before test", getTestParamsForLogging());

0 commit comments

Comments
 (0)