Author: fanningpj
Date: Mon Jul 1 23:19:33 2024
New Revision: 1918805
URL: http://svn.apache.org/viewvc?rev=1918805&view=rev
Log:
try to stop poi-integration testing with corrupt file
Modified:
poi/trunk/poi-integration/src/test/java/org/apache/poi/stress/TestAllFiles.java
poi/trunk/poi-integration/src/test/java/org/apache/poi/stress/XSSFFileHandler.java
Modified:
poi/trunk/poi-integration/src/test/java/org/apache/poi/stress/TestAllFiles.java
URL:
http://svn.apache.org/viewvc/poi/trunk/poi-integration/src/test/java/org/apache/poi/stress/TestAllFiles.java?rev=1918805&r1=1918804&r2=1918805&view=diff
==============================================================================
---
poi/trunk/poi-integration/src/test/java/org/apache/poi/stress/TestAllFiles.java
(original)
+++
poi/trunk/poi-integration/src/test/java/org/apache/poi/stress/TestAllFiles.java
Mon Jul 1 23:19:33 2024
@@ -96,6 +96,9 @@ public class TestAllFiles {
"poifs/protected_sha512.xlsx",
"poifs/60320-protected.xlsx",
"poifs/protected_sha512.xlsx",
+
+ // corrupt file
+ "spreadsheet/duplicate-filename.xlsx"
};
// cheap workaround of skipping the few problematic files
@@ -145,6 +148,9 @@ public class TestAllFiles {
"poifs/protected_sha512.xlsx",
"poifs/60320-protected.xlsx",
"poifs/protected_sha512.xlsx",
+
+ // corrupt file
+ "spreadsheet/duplicate-filename.xlsx"
};
private static final Set<String> EXPECTED_FAILURES =
StressTestUtils.unmodifiableHashSet(
Modified:
poi/trunk/poi-integration/src/test/java/org/apache/poi/stress/XSSFFileHandler.java
URL:
http://svn.apache.org/viewvc/poi/trunk/poi-integration/src/test/java/org/apache/poi/stress/XSSFFileHandler.java?rev=1918805&r1=1918804&r2=1918805&view=diff
==============================================================================
---
poi/trunk/poi-integration/src/test/java/org/apache/poi/stress/XSSFFileHandler.java
(original)
+++
poi/trunk/poi-integration/src/test/java/org/apache/poi/stress/XSSFFileHandler.java
Mon Jul 1 23:19:33 2024
@@ -188,7 +188,6 @@ public class XSSFFileHandler extends Spr
EXPECTED_ADDITIONAL_FAILURES.add("spreadsheet/sample-beta.xlsx");
// corrupt/invalid
-
EXPECTED_ADDITIONAL_FAILURES.add("spreadsheet/duplicate-filename.xlsx");
EXPECTED_ADDITIONAL_FAILURES.add("openxml4j/invalid.xlsx");
}
@@ -204,7 +203,7 @@ public class XSSFFileHandler extends Spr
XLSX2CSV.main(new String[]{file.getAbsolutePath()});
ExcelComparator.main(new String[]{file.getAbsolutePath(),
file.getAbsolutePath()});
- assertFalse( EXPECTED_ADDITIONAL_FAILURES.contains(testFile),
"Expected Extraction to fail for file " + file + " and handler " + this + ",
but did not fail!" );
+ assertFalse(EXPECTED_ADDITIONAL_FAILURES.contains(testFile),
"Expected Extraction to fail for file " + file + " and handler " + this + ",
but did not fail!" );
} catch (OLE2NotOfficeXmlFileException e) {
// we have some files that are not actually OOXML and thus cannot
be tested here
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]