Skip to content

Commit

Permalink
#8986 Test for image before title
Browse files Browse the repository at this point in the history
  • Loading branch information
StephanMeijer committed Oct 31, 2023
1 parent d3d0406 commit 156180b
Show file tree
Hide file tree
Showing 3 changed files with 91 additions and 0 deletions.
4 changes: 4 additions & 0 deletions test/Tests/Readers/Docx.hs
Original file line number Diff line number Diff line change
Expand Up @@ -265,6 +265,10 @@ tests = [ testGroup "document"
"i18n blocks (headers and blockquotes)"
"docx/i18n_blocks.docx"
"docx/i18n_blocks.native"
, testCompare
"Image before Title"
"docx/image-before-title.docx"
"docx/image-before-title.native"
, testCompare
"lists"
"docx/lists.docx"
Expand Down
Binary file added test/docx/image-before-title.docx
Binary file not shown.
87 changes: 87 additions & 0 deletions test/docx/image-before-title.native
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
[ Para
[ Image
( ""
, []
, [ ( "width" , "6.268055555555556in" )
, ( "height" , "6.268055555555556in" )
]
)
[ Str "A"
, Space
, Str "cat"
, Space
, Str "holding"
, Space
, Str "a"
, Space
, Str "rainbow"
, Space
, Str "flag."
]
( "media/image1.jpeg" , "" )
]
, Title
[ Str "This"
, Space
, Str "is"
, Space
, Str "a"
, Space
, Str "title"
]
, Subtitle
[ Str "This"
, Space
, Str "is"
, Space
, Str "a"
, Space
, Str "subtitle"
]
, Header
1
( "this-is-a-heading-1" , [] , [] )
[ Str "This"
, Space
, Str "is"
, Space
, Str "a"
, Space
, Str "heading"
, Space
, Str "1"
]
, Para
[ Str "This"
, Space
, Str "is"
, Space
, Str "some"
, Space
, Str "text."
]
, Header
2
( "this-is-a-heading-2" , [] , [] )
[ Str "This"
, Space
, Str "is"
, Space
, Str "a"
, Space
, Str "heading"
, Space
, Str "2"
]
, Para
[ Str "This"
, Space
, Str "is"
, Space
, Str "also"
, Space
, Str "some"
, Space
, Str "text."
]
]

0 comments on commit 156180b

Please sign in to comment.