<changes>
<release version="3.8-beta4" date="2011-??-??">
+ <action dev="poi-developers" type="fix">51481 - Fixed autofilters in HSSF to avoid warnings in Excel 2007</action>
<action dev="poi-developers" type="fix">51533 - Avoid exception when changing name of a sheet containing shared formulas</action>
<action dev="poi-developers" type="add">Support for appending images to existing drawings in HSSF</action>
<action dev="poi-developers" type="fix">Added initial support for bookmarks in HWFP</action>
import java.io.File;
import java.io.FileInputStream;
import java.io.FileOutputStream;
+import java.util.List;
import junit.framework.AssertionFailedError;
assertNotNull(afilter );
assertEquals(2, afilter.getNumEntries()); //filter covers two columns
+ HSSFPatriarch dr = sh.getDrawingPatriarch();
+ assertNotNull(dr);
+ HSSFSimpleShape comboBoxShape = (HSSFSimpleShape)dr.getChildren().get(0);
+ assertEquals(comboBoxShape.getShapeType(), HSSFSimpleShape.OBJECT_TYPE_COMBO_BOX);
+
+ assertNull( ish.findFirstRecordBySid(ObjRecord.sid) ); // ObjRecord will appear after serializetion
+
+ wb = HSSFTestDataSamples.writeOutAndReadBack(wb);
+ sh = wb.getSheetAt(0);
+ ish = sh.getSheet();
+ ObjRecord objRecord = (ObjRecord)ish.findFirstRecordBySid(ObjRecord.sid);
+ List<SubRecord> subRecords = objRecord.getSubRecords();
+ assertEquals(3, subRecords.size());
+ assertTrue(subRecords.get(0) instanceof CommonObjectDataSubRecord );
+ assertTrue(subRecords.get(1) instanceof FtCblsSubRecord ); // must be present, see Bug 51481
+ assertTrue(subRecords.get(2) instanceof LbsDataSubRecord );
}
}