{
rawBlocks[ j ] = new RawDataBlock(stream);
}
POIFSDocument document = new POIFSDocument("document", rawBlocks,
2000);
DocumentProperty property2 = document.getDocumentProperty();
DirectoryNode parent = new DirectoryNode(property1, null, null);
DocumentNode node = new DocumentNode(property2, parent);
// verify we can retrieve the document
assertEquals(property2.getDocument(), node.getDocument());
// verify we can get the size
assertEquals(property2.getSize(), node.getSize());
// verify isDocumentEntry returns true
assertTrue(node.isDocumentEntry());
// verify isDirectoryEntry returns false
assertTrue(!node.isDirectoryEntry());
// verify getName behaves correctly
assertEquals(property2.getName(), node.getName());
// verify getParent behaves correctly
assertEquals(parent, node.getParent());
}