diff options
author | Evgeniy Berlog <berlog@apache.org> | 2012-07-06 17:00:20 +0000 |
---|---|---|
committer | Evgeniy Berlog <berlog@apache.org> | 2012-07-06 17:00:20 +0000 |
commit | 06df547a594c30a10d9d25eb82fcd107c2f42ae4 (patch) | |
tree | 282a5d2aa4afba1221bced5ef0ae2b9b3219a483 /src/testcases/org/apache/poi/hssf/model/TestDrawingShapes.java | |
parent | 5f543636b754773ab470a104ae6acd36102c7cb9 (diff) | |
download | poi-06df547a594c30a10d9d25eb82fcd107c2f42ae4.tar.gz poi-06df547a594c30a10d9d25eb82fcd107c2f42ae4.zip |
implemented creating shapes in new file using new model
git-svn-id: https://svn.apache.org/repos/asf/poi/branches/gsoc2012@1358301 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/testcases/org/apache/poi/hssf/model/TestDrawingShapes.java')
-rw-r--r-- | src/testcases/org/apache/poi/hssf/model/TestDrawingShapes.java | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/testcases/org/apache/poi/hssf/model/TestDrawingShapes.java b/src/testcases/org/apache/poi/hssf/model/TestDrawingShapes.java index 4e120a7cb8..e50aa47adf 100644 --- a/src/testcases/org/apache/poi/hssf/model/TestDrawingShapes.java +++ b/src/testcases/org/apache/poi/hssf/model/TestDrawingShapes.java @@ -324,4 +324,14 @@ public class TestDrawingShapes extends TestCase { textbox.setLineStyleColor(textbox.getLineStyleColor());
assertEquals(opt1Str, textbox.getEscherContainer().getChildById(EscherOptRecord.RECORD_ID).toXml());
}
+
+ public void testDgRecordNumShapes(){
+ HSSFWorkbook wb = new HSSFWorkbook();
+ HSSFSheet sheet = wb.createSheet();
+ HSSFPatriarch patriarch = sheet.createDrawingPatriarch();
+
+ EscherAggregate aggregate = HSSFTestHelper.getEscherAggregate(patriarch);
+ EscherDgRecord dgRecord = (EscherDgRecord) aggregate.getEscherRecord(0).getChild(0);
+ assertEquals(dgRecord.getNumShapes(), 1);
+ }
}
|