poi-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From one...@apache.org
Subject svn commit: r1722081 - /poi/trunk/src/ooxml/testcases/org/apache/poi/ss/TestWorkbookFactory.java
Date Tue, 29 Dec 2015 09:54:59 GMT
Author: onealj
Date: Tue Dec 29 09:54:59 2015
New Revision: 1722081

URL: http://svn.apache.org/viewvc?rev=1722081&view=rev
Log:
junit3 -> junit4

Modified:
    poi/trunk/src/ooxml/testcases/org/apache/poi/ss/TestWorkbookFactory.java

Modified: poi/trunk/src/ooxml/testcases/org/apache/poi/ss/TestWorkbookFactory.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/ooxml/testcases/org/apache/poi/ss/TestWorkbookFactory.java?rev=1722081&r1=1722080&r2=1722081&view=diff
==============================================================================
--- poi/trunk/src/ooxml/testcases/org/apache/poi/ss/TestWorkbookFactory.java (original)
+++ poi/trunk/src/ooxml/testcases/org/apache/poi/ss/TestWorkbookFactory.java Tue Dec 29 09:54:59
2015
@@ -17,6 +17,8 @@
 
 package org.apache.poi.ss;
 
+import static org.junit.Assert.*;
+
 import java.io.ByteArrayInputStream;
 import java.io.File;
 import java.io.InputStream;
@@ -35,9 +37,9 @@ import org.apache.poi.xssf.usermodel.XSS
 import org.apache.poi.openxml4j.exceptions.InvalidFormatException;
 import org.apache.poi.openxml4j.opc.OPCPackage;
 
-import junit.framework.TestCase;
+import org.junit.Test;
 
-public final class TestWorkbookFactory extends TestCase {
+public final class TestWorkbookFactory {
     private static final String xls = "SampleSS.xls";
     private static final String xlsx = "SampleSS.xlsx";
     private static final String[] xls_prot = new String[] {"password.xls", "password"};
@@ -66,6 +68,7 @@ public final class TestWorkbookFactory e
         }
     }
 
+    @Test
     public void testCreateNative() throws Exception {
         Workbook wb;
 
@@ -88,6 +91,7 @@ public final class TestWorkbookFactory e
         revert(wb);
     }
 
+    @Test
     public void testCreateReadOnly() throws Exception {
         Workbook wb;
 
@@ -109,6 +113,7 @@ public final class TestWorkbookFactory e
      *  checking the mime magic at the start of the
      *  InputStream, then creating what's required.
      */
+    @Test
     public void testCreateGeneric() throws Exception {
         Workbook wb;
 
@@ -161,6 +166,7 @@ public final class TestWorkbookFactory e
     /**
      * Check that the overloaded stream methods which take passwords work properly
      */
+    @Test
     public void testCreateWithPasswordFromStream() throws Exception {
         Workbook wb;
 
@@ -234,6 +240,7 @@ public final class TestWorkbookFactory e
     /**
      * Check that the overloaded file methods which take passwords work properly
      */
+    @Test
     public void testCreateWithPasswordFromFile() throws Exception {
         Workbook wb;
 
@@ -303,6 +310,7 @@ public final class TestWorkbookFactory e
     /**
      * Check that a helpful exception is given on an empty file / stream
      */
+    @Test
     public void testEmptyFile() throws Exception {
         InputStream emptyStream = new ByteArrayInputStream(new byte[0]);
         File emptyFile = TempFile.createTempFile("empty", ".poi");



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@poi.apache.org
For additional commands, e-mail: commits-help@poi.apache.org


Mime
View raw message