From 765d970a458f8ff9523447f9a2d8368fda9f6cd7 Mon Sep 17 00:00:00 2001 From: Nick Burch Date: Mon, 5 Dec 2011 05:12:23 +0000 Subject: [PATCH] Add test file for bug #51873 from Jeremy, and a test that uses it git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1210332 13f79535-47bb-0310-9956-ffa450edef68 --- .../hsmf/parsers/TestPOIFSChunkParser.java | 18 +++++++++++++++++- test-data/hsmf/51873.msg | Bin 0 -> 10240 bytes 2 files changed, 17 insertions(+), 1 deletion(-) create mode 100644 test-data/hsmf/51873.msg diff --git a/src/scratchpad/testcases/org/apache/poi/hsmf/parsers/TestPOIFSChunkParser.java b/src/scratchpad/testcases/org/apache/poi/hsmf/parsers/TestPOIFSChunkParser.java index 2ef19603e7..721f60591c 100644 --- a/src/scratchpad/testcases/org/apache/poi/hsmf/parsers/TestPOIFSChunkParser.java +++ b/src/scratchpad/testcases/org/apache/poi/hsmf/parsers/TestPOIFSChunkParser.java @@ -332,5 +332,21 @@ public final class TestPOIFSChunkParser extends TestCase { } catch(ChunkNotFoundException e) { fail(); } - } + } + + /** + * Bugzilla #51873 - Outlook 2002 files created with dragging and + * dropping files to the disk include a non-standard named streams + * such as "Olk10SideProps_0001" + */ + public void testOlk10SideProps() throws Exception { + POIFSFileSystem poifs = new POIFSFileSystem( + new FileInputStream(samples.getFile("51873.msg")) + ); + MAPIMessage msg = new MAPIMessage(poifs); + + // Check core details came through + assertEquals("bubba@bubbasmith.com", msg.getDisplayTo()); + assertEquals("Test with Olk10SideProps_ Chunk", msg.getSubject()); + } } diff --git a/test-data/hsmf/51873.msg b/test-data/hsmf/51873.msg new file mode 100644 index 0000000000000000000000000000000000000000..28a0a57db568db6c737228b4e1e4e51b7b7741b4 GIT binary patch literal 10240 zcmeHNZ)_Y#6@Pns{(FgiPEt2@T8IQg>$~U#D~wf z7vG+-KOkKN2tLvF8z7Z7A>ji8seuptNd-}nK!OUwCsGOAL=92|A84h@QILpvzuBAk z?&S5(IUuN%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