aboutsummaryrefslogtreecommitdiffstats
path: root/src/integrationtest/org/apache/poi/stress/XSSFFileHandler.java
diff options
context:
space:
mode:
authorAndreas Beeker <kiwiwings@apache.org>2020-12-24 18:42:29 +0000
committerAndreas Beeker <kiwiwings@apache.org>2020-12-24 18:42:29 +0000
commita0fa9e19b1196bc10034f15474d27ce23bf5865a (patch)
tree499c1eb427ebff72f7e447d13dd1de1552df8146 /src/integrationtest/org/apache/poi/stress/XSSFFileHandler.java
parentfb012041e8dd788637e68737199bc313b3e90098 (diff)
downloadpoi-a0fa9e19b1196bc10034f15474d27ce23bf5865a.tar.gz
poi-a0fa9e19b1196bc10034f15474d27ce23bf5865a.zip
#65026 - Migrate tests to Junit 5
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1884783 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/integrationtest/org/apache/poi/stress/XSSFFileHandler.java')
-rw-r--r--src/integrationtest/org/apache/poi/stress/XSSFFileHandler.java15
1 files changed, 7 insertions, 8 deletions
diff --git a/src/integrationtest/org/apache/poi/stress/XSSFFileHandler.java b/src/integrationtest/org/apache/poi/stress/XSSFFileHandler.java
index b1aa5b718c..ec060dee05 100644
--- a/src/integrationtest/org/apache/poi/stress/XSSFFileHandler.java
+++ b/src/integrationtest/org/apache/poi/stress/XSSFFileHandler.java
@@ -16,10 +16,10 @@
==================================================================== */
package org.apache.poi.stress;
-import static org.junit.Assert.assertFalse;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertTrue;
-import static org.junit.Assume.assumeFalse;
+import static org.junit.jupiter.api.Assertions.assertFalse;
+import static org.junit.jupiter.api.Assertions.assertNotNull;
+import static org.junit.jupiter.api.Assertions.assertTrue;
+import static org.junit.jupiter.api.Assumptions.assumeFalse;
import java.io.BufferedInputStream;
import java.io.ByteArrayInputStream;
@@ -54,7 +54,7 @@ import org.apache.poi.xssf.eventusermodel.XSSFReader;
import org.apache.poi.xssf.extractor.XSSFExportToXml;
import org.apache.poi.xssf.usermodel.XSSFMap;
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
-import org.junit.Test;
+import org.junit.jupiter.api.Test;
import org.xml.sax.SAXException;
public class XSSFFileHandler extends SpreadsheetHandler {
@@ -78,7 +78,7 @@ public class XSSFFileHandler extends SpreadsheetHandler {
Decryptor dec = ei.getDecryptor();
try {
boolean b = dec.verifyPassword(pass);
- assertTrue("password mismatch", b);
+ assertTrue( b, "password mismatch" );
} catch (EncryptedDocumentException e) {
String msg = "Export Restrictions in place - please install JCE Unlimited Strength Jurisdiction Policy files";
assumeFalse(msg.equals(e.getMessage()));
@@ -190,8 +190,7 @@ public class XSSFFileHandler extends SpreadsheetHandler {
XLSX2CSV.main(new String[]{file.getAbsolutePath()});
ExcelComparator.main(new String[]{file.getAbsolutePath(), file.getAbsolutePath()});
- assertFalse("Expected Extraction to fail for file " + file + " and handler " + this + ", but did not fail!",
- EXPECTED_ADDITIONAL_FAILURES.contains(testFile));
+ 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