Fix bug in test.

This commit is contained in:
Gary Gregory 2020-06-22 09:28:58 -04:00
parent b7b4ae33dc
commit 64b2f90d20
1 changed files with 12 additions and 7 deletions

View File

@ -244,6 +244,8 @@ public void testContainsIgnoreCase_LocaleIndependence() {
{ "\u00DF", "SS" },
};
final Locale defaultLocale = Locale.getDefault();
try {
for (final Locale testLocale : locales) {
Locale.setDefault(testLocale);
for (int j = 0; j < tdata.length; j++) {
@ -255,6 +257,9 @@ public void testContainsIgnoreCase_LocaleIndependence() {
Locale.getDefault() + ": " + j + " " + fdata[j][0] + " " + fdata[j][1]);
}
}
} finally {
Locale.setDefault(defaultLocale);
}
}
@Test