/* There are two block areas. */
assertEquals(2, firstNormalFlowArea.getChildCount());
/* The second one contains the graphic. */
AreaNode node = firstNormalFlowArea.getChildAt(1);
assertTrue(node instanceof NormalBlockArea);
/* It has one child, a LineArea ... */
assertEquals(1, node.getChildCount());
node = node.getChildAt(0);
assertTrue(node instanceof LineArea);
/* ... which has one child, an ExternalGraphicArea. */
assertEquals(1, node.getChildCount());
node = node.getChildAt(0);
assertTrue(node instanceof ExternalGraphicArea);
/* First test the size of the viewport. */
final ExternalGraphicArea ega = (ExternalGraphicArea) node;
final int width = ega.crIpd();