]> source.dussan.org Git - poi.git/commitdiff
Testcase for bug 13769 .. thanks michael tosdevin
authorAvik Sengupta <avik@apache.org>
Thu, 31 Jul 2003 20:00:03 +0000 (20:00 +0000)
committerAvik Sengupta <avik@apache.org>
Thu, 31 Jul 2003 20:00:03 +0000 (20:00 +0000)
the bug has already been fixed in 2.0pre3

git-svn-id: https://svn.apache.org/repos/asf/jakarta/poi/trunk@353279 13f79535-47bb-0310-9956-ffa450edef68

src/testcases/org/apache/poi/hssf/data/13796.xls [new file with mode: 0644]
src/testcases/org/apache/poi/hssf/usermodel/TestBugs.java

diff --git a/src/testcases/org/apache/poi/hssf/data/13796.xls b/src/testcases/org/apache/poi/hssf/data/13796.xls
new file mode 100644 (file)
index 0000000..efae53f
Binary files /dev/null and b/src/testcases/org/apache/poi/hssf/data/13796.xls differ
index 48cec0192aee9004f5737d39f12497aa85827fc8..487c123f91f3766562dc151fc0b13fd5f02e341a 100644 (file)
@@ -91,7 +91,24 @@ extends TestCase {
           assertTrue("File Should Exist", file.exists());
             
     }
-    
+       public void test13796()
+        throws java.io.IOException
+    {
+         String readFilename = System.getProperty("HSSF.testdata.path");
+          FileInputStream in = new FileInputStream(readFilename+File.separator+"13796.xls");
+          HSSFWorkbook wb = new HSSFWorkbook(in);
+          HSSFSheet s = wb.getSheetAt(0);
+          HSSFRow r = s.createRow(0);
+          HSSFCell c = r.createCell((short)0);
+          c.setCellValue(10);
+          File file = File.createTempFile("test13796",".xls");
+          FileOutputStream out    = new FileOutputStream(file);
+          wb.write(out);
+          assertTrue("No exception thrown", true);
+          assertTrue("File Should Exist", file.exists());
+
+    }
+   
 }