]> source.dussan.org Git - poi.git/commitdiff
check column outline level for bug 55076
authorJaven O'Neal <onealj@apache.org>
Thu, 22 Sep 2016 04:37:04 +0000 (04:37 +0000)
committerJaven O'Neal <onealj@apache.org>
Thu, 22 Sep 2016 04:37:04 +0000 (04:37 +0000)
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1761847 13f79535-47bb-0310-9956-ffa450edef68

src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFBugs.java

index fea0262c41e554365089cd10e2247aa437ced7c5..7fb1b507d53dddf78de2982a9650cdef519ad651 100644 (file)
@@ -3110,9 +3110,11 @@ public final class TestXSSFBugs extends BaseTestBugzillaIssues {
         sheet.groupColumn(1, 3);
         sheet.setColumnGroupCollapsed(1, true);
         
-        assertEquals(400, sheet.getColumnWidth(1));
-        assertEquals(600, sheet.getColumnWidth(2));
-        assertEquals(800, sheet.getColumnWidth(3));
+        assertEquals(0, sheet.getColumnOutlineLevel(0));
+        assertEquals(1, sheet.getColumnOutlineLevel(1));
+        assertEquals(1, sheet.getColumnOutlineLevel(2));
+        assertEquals(1, sheet.getColumnOutlineLevel(3));
+        assertEquals(0, sheet.getColumnOutlineLevel(4));
         
         // none of the columns should be hidden
         // column group collapsing is a different concept
@@ -3120,6 +3122,10 @@ public final class TestXSSFBugs extends BaseTestBugzillaIssues {
             assertFalse("Column " + c, sheet.isColumnHidden(c));
         }
         
+        assertEquals(400, sheet.getColumnWidth(1));
+        assertEquals(600, sheet.getColumnWidth(2));
+        assertEquals(800, sheet.getColumnWidth(3));
+        
         wb.close();
     }
 }