diff options
author | Glen Stampoultzis <glens@apache.org> | 2005-05-01 11:26:18 +0000 |
---|---|---|
committer | Glen Stampoultzis <glens@apache.org> | 2005-05-01 11:26:18 +0000 |
commit | 585f86a986ea2d6f23a61ce6c552fc0f6194798f (patch) | |
tree | 881e2b617dbbfaaa025a322d224b7c62b8e0e32d /src/testcases/org/apache/poi/ddf | |
parent | 3c991cfc7a0e09e5ee0b11fd8ad401aabbaf32fd (diff) | |
download | poi-585f86a986ea2d6f23a61ce6c552fc0f6194798f.tar.gz poi-585f86a986ea2d6f23a61ce6c552fc0f6194798f.zip |
Added image support for POI. See the quick guide for details. Sponsored through superlink software.
git-svn-id: https://svn.apache.org/repos/asf/jakarta/poi/trunk@353660 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/testcases/org/apache/poi/ddf')
-rw-r--r-- | src/testcases/org/apache/poi/ddf/TestEscherBSERecord.java | 3 | ||||
-rw-r--r-- | src/testcases/org/apache/poi/ddf/TestEscherBlipWMFRecord.java (renamed from src/testcases/org/apache/poi/ddf/TestEscherBlipRecord.java) | 14 | ||||
-rw-r--r-- | src/testcases/org/apache/poi/ddf/TestEscherBoolProperty.java | 2 | ||||
-rw-r--r-- | src/testcases/org/apache/poi/ddf/TestEscherClientDataRecord.java | 2 | ||||
-rw-r--r-- | src/testcases/org/apache/poi/ddf/TestEscherOptRecord.java | 2 |
5 files changed, 12 insertions, 11 deletions
diff --git a/src/testcases/org/apache/poi/ddf/TestEscherBSERecord.java b/src/testcases/org/apache/poi/ddf/TestEscherBSERecord.java index 8025e839e5..ce18f7025e 100644 --- a/src/testcases/org/apache/poi/ddf/TestEscherBSERecord.java +++ b/src/testcases/org/apache/poi/ddf/TestEscherBSERecord.java @@ -98,8 +98,9 @@ public class TestEscherBSERecord extends TestCase " Name: 5" + nl + " Unused2: 6" + nl + " Unused3: 7" + nl + + " blipRecord: null" + nl + " Extra Data:" + nl + - "No Data", record.toString() ); + "No Data" + nl, record.toString() ); } } diff --git a/src/testcases/org/apache/poi/ddf/TestEscherBlipRecord.java b/src/testcases/org/apache/poi/ddf/TestEscherBlipWMFRecord.java index 8b82135c41..aff89c29e3 100644 --- a/src/testcases/org/apache/poi/ddf/TestEscherBlipRecord.java +++ b/src/testcases/org/apache/poi/ddf/TestEscherBlipWMFRecord.java @@ -21,7 +21,7 @@ import junit.framework.TestCase; import org.apache.poi.util.HexDump; import org.apache.poi.util.HexRead; -public class TestEscherBlipRecord extends TestCase +public class TestEscherBlipWMFRecord extends TestCase { private String dataStr; private byte[] data; @@ -37,7 +37,7 @@ public class TestEscherBlipRecord extends TestCase public void testSerialize() throws Exception { - EscherBlipRecord r = new EscherBlipRecord(); + EscherBlipWMFRecord r = new EscherBlipWMFRecord(); r.setBoundaryLeft(1); r.setBoundaryHeight(2); r.setBoundaryTop(3); @@ -52,7 +52,7 @@ public class TestEscherBlipRecord extends TestCase (byte)0x01, (byte)0x01, (byte)0x01, (byte)0x01, }); r.setWidth(10); r.setHeight(11); - r.setRecordId(EscherBlipRecord.RECORD_ID_START); + r.setRecordId(EscherBlipWMFRecord.RECORD_ID_START); r.setOptions((short)5420); r.setData(new byte[] { (byte)0x01, (byte)0x02 } ); @@ -79,10 +79,10 @@ public class TestEscherBlipRecord extends TestCase public void testFillFields() throws Exception { - EscherBlipRecord r = new EscherBlipRecord(); + EscherBlipWMFRecord r = new EscherBlipWMFRecord(); r.fillFields( data, 0, new DefaultEscherRecordFactory()); - assertEquals( EscherBlipRecord.RECORD_ID_START, r.getRecordId() ); + assertEquals( EscherBlipWMFRecord.RECORD_ID_START, r.getRecordId() ); assertEquals( 1, r.getBoundaryLeft() ); assertEquals( 2, r.getBoundaryHeight() ); assertEquals( 3, r.getBoundaryTop() ); @@ -100,12 +100,12 @@ public class TestEscherBlipRecord extends TestCase public void testToString() throws Exception { - EscherBlipRecord r = new EscherBlipRecord(); + EscherBlipWMFRecord r = new EscherBlipWMFRecord(); r.fillFields( data, 0, new DefaultEscherRecordFactory() ); String nl = System.getProperty("line.separator"); - assertEquals( "org.apache.poi.ddf.EscherBlipRecord:" + nl + + assertEquals( "org.apache.poi.ddf.EscherBlipWMFRecord:" + nl + " RecordId: 0xF018" + nl + " Options: 0x152C" + nl + " Secondary UID: [01, 01, 01, 01, 01, 01, 01, 01, 01, 01, 01, 01, 01, 01, 01, 01, ]" + nl + diff --git a/src/testcases/org/apache/poi/ddf/TestEscherBoolProperty.java b/src/testcases/org/apache/poi/ddf/TestEscherBoolProperty.java index 473e03cc62..3fe0c762f8 100644 --- a/src/testcases/org/apache/poi/ddf/TestEscherBoolProperty.java +++ b/src/testcases/org/apache/poi/ddf/TestEscherBoolProperty.java @@ -24,7 +24,7 @@ public class TestEscherBoolProperty extends TestCase public void testToString() throws Exception { EscherBoolProperty p = new EscherBoolProperty((short)1, 1); - assertEquals("propNum: 1, propName: unknown, complex: false, blipId: false, value: 1 (0x00000001)", p.toString()); + assertEquals("propNum: 1, RAW: 0x0001, propName: unknown, complex: false, blipId: false, value: 1 (0x00000001)", p.toString()); } } diff --git a/src/testcases/org/apache/poi/ddf/TestEscherClientDataRecord.java b/src/testcases/org/apache/poi/ddf/TestEscherClientDataRecord.java index 0491029d29..d8cdab4414 100644 --- a/src/testcases/org/apache/poi/ddf/TestEscherClientDataRecord.java +++ b/src/testcases/org/apache/poi/ddf/TestEscherClientDataRecord.java @@ -58,7 +58,7 @@ public class TestEscherClientDataRecord extends TestCase " RecordId: 0xF011" + nl + " Options: 0x0002" + nl + " Extra Data:" + nl + - "No Data" ; + "No Data" + nl ; assertEquals( expected, createRecord().toString() ); } diff --git a/src/testcases/org/apache/poi/ddf/TestEscherOptRecord.java b/src/testcases/org/apache/poi/ddf/TestEscherOptRecord.java index 8795de77ad..334eeb49df 100644 --- a/src/testcases/org/apache/poi/ddf/TestEscherOptRecord.java +++ b/src/testcases/org/apache/poi/ddf/TestEscherOptRecord.java @@ -150,7 +150,7 @@ public class TestEscherOptRecord extends TestCase " recordId: 0x" + HexDump.toHex(EscherOptRecord.RECORD_ID) + nl + " numchildren: 0" + nl + " properties:" + nl + - " propNum: 1, propName: unknown, complex: false, blipId: false, value: 1 (0x00000001)" + nl; + " propNum: 1, RAW: 0x0001, propName: unknown, complex: false, blipId: false, value: 1 (0x00000001)" + nl; assertEquals( expected, r.toString()); } |