[Bug 60422] Tidy up test case
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1799722 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
66b39c70ad
commit
c1cc93a2ef
@ -858,18 +858,16 @@ public class TestDataFormatter {
|
||||
*/
|
||||
@Test
|
||||
public void testBug60422() {
|
||||
Locale defaultLocale = Locale.getDefault();
|
||||
Locale.setDefault(Locale.GERMANY);
|
||||
LocaleUtil.setUserLocale(Locale.ROOT);
|
||||
try {
|
||||
char euro = '\u20AC';
|
||||
DataFormatter df = new DataFormatter();
|
||||
DataFormatter df = new DataFormatter(Locale.GERMANY);
|
||||
String formatString = String.format(
|
||||
"_-* #,##0.00\\ \"%s\"_-;\\-* #,##0.00\\ \"%s\"_-;_-* \"-\"??\\ \"%s\"_-;_-@_-",
|
||||
euro, euro, euro);
|
||||
assertEquals("4.33 " + euro, df.formatRawCellContents(4.33, 178, formatString));
|
||||
} finally {
|
||||
Locale.setDefault(defaultLocale);
|
||||
LocaleUtil.resetUserLocale();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user