@@ -210,6 +210,28 @@ public void testRemoveTableHeader() throws Exception {
210
210
+ "</structure-tree-sequence>" );
211
211
}
212
212
213
+ @ Test
214
+ public void testExternalGraphicArtifact () throws Exception {
215
+ String fo = "<fo:root xmlns:fo=\" http://www.w3.org/1999/XSL/Format\" >\n "
216
+ + " <fo:layout-master-set>\n "
217
+ + " <fo:simple-page-master master-name=\" simple\" page-height=\" 27.9cm\" page-width=\" 21.6cm\" >\n "
218
+ + " <fo:region-body />\n "
219
+ + " </fo:simple-page-master>\n "
220
+ + " </fo:layout-master-set>\n "
221
+ + " <fo:page-sequence master-reference=\" simple\" >\n "
222
+ + " <fo:flow flow-name=\" xsl-region-body\" >\n "
223
+ + "<fo:block><fo:external-graphic src=\" test/resources/fop/image/logo.jpg\" role=\" artifact\" />"
224
+ + "</fo:block></fo:flow>\n "
225
+ + " </fo:page-sequence>\n "
226
+ + "</fo:root>\n " ;
227
+ compare (fo , "<?xml version=\" 1.0\" encoding=\" UTF-8\" standalone=\" no\" ?><structure-tree-sequence>"
228
+ + "<structure-tree xmlns=\" http://xmlgraphics.apache.org/fop/intermediate\" "
229
+ + "xmlns:foi=\" http://xmlgraphics.apache.org/fop/internal\" "
230
+ + "xmlns:fox=\" http://xmlgraphics.apache.org/fop/extensions\" >"
231
+ + "<fo:flow xmlns:fo=\" http://www.w3.org/1999/XSL/Format\" flow-name=\" xsl-region-body\" >"
232
+ + "<fo:block/></fo:flow></structure-tree></structure-tree-sequence>" );
233
+ }
234
+
213
235
private void compare (final String fo , String tree ) throws Exception {
214
236
foLoader = new FOLoader ("" ) {
215
237
public InputStream getFoInputStream () {
0 commit comments