mirror of https://github.com/apache/poi.git
forbidden api issue
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1889872 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
0614835c55
commit
a28596d583
|
@ -41,6 +41,7 @@ import org.apache.poi.hssf.HSSFTestDataSamples;
|
|||
import org.apache.poi.poifs.filesystem.OfficeXmlFileException;
|
||||
import org.apache.poi.poifs.filesystem.POIFSFileSystem;
|
||||
import org.apache.commons.io.output.NullPrintStream;
|
||||
import org.apache.poi.util.LocaleUtil;
|
||||
import org.apache.poi.util.RecordFormatException;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
|
@ -323,7 +324,7 @@ final class TestOldExcelExtractor {
|
|||
File file = HSSFTestDataSamples.getSampleFile("testEXCEL_3.xls");
|
||||
PrintStream save = System.out;
|
||||
try (UnsynchronizedByteArrayOutputStream out = new UnsynchronizedByteArrayOutputStream();
|
||||
PrintStream str = new PrintStream(out, false, StandardCharsets.UTF_8.displayName())) {
|
||||
PrintStream str = new PrintStream(out, false, StandardCharsets.UTF_8.displayName(LocaleUtil.getUserLocale()))) {
|
||||
System.setOut(str);
|
||||
OldExcelExtractor.main(new String[] {file.getAbsolutePath()});
|
||||
String string = out.toString(StandardCharsets.UTF_8);
|
||||
|
|
Loading…
Reference in New Issue