diff options
author | John MacFarlane <jgm@berkeley.edu> | 2014-08-13 11:16:50 -0700 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2014-08-13 11:16:50 -0700 |
commit | 40e67b873735f108dfb17f75f6475219a62278cd (patch) | |
tree | 7814e987155d3b7d196135e2cdbf06deb67d460d /tests/Tests | |
parent | fa71a08ed3cae4ed26d2cb84b1f7a29be94e3ddb (diff) | |
download | pandoc-40e67b873735f108dfb17f75f6475219a62278cd.tar.gz |
Revised tests directory.
Renamed some tests, introducing subsidiary directories
for fb2, docx, epub.
Cleaned up tests in cabal file.
Combined dokuwiki-writer and dokuwiki_inline_formatting tests.
Diffstat (limited to 'tests/Tests')
-rw-r--r-- | tests/Tests/Old.hs | 24 | ||||
-rw-r--r-- | tests/Tests/Readers/Docx.hs | 122 | ||||
-rw-r--r-- | tests/Tests/Readers/EPUB.hs | 2 |
3 files changed, 73 insertions, 75 deletions
diff --git a/tests/Tests/Old.hs b/tests/Tests/Old.hs index 8ecbdbbba..19461f74f 100644 --- a/tests/Tests/Old.hs +++ b/tests/Tests/Old.hs @@ -111,12 +111,12 @@ tests = [ testGroup "markdown" "testsuite.native" "testsuite.native" ] , testGroup "fb2" - [ fb2WriterTest "basic" [] "fb2.basic.markdown" "fb2.basic.fb2" - , fb2WriterTest "titles" [] "fb2.titles.markdown" "fb2.titles.fb2" - , fb2WriterTest "images" [] "fb2.images.markdown" "fb2.images.fb2" - , fb2WriterTest "images-embedded" [] "fb2.images-embedded.html" "fb2.images-embedded.fb2" + [ fb2WriterTest "basic" [] "fb2/basic.markdown" "fb2/basic.fb2" + , fb2WriterTest "titles" [] "fb2/titles.markdown" "fb2/titles.fb2" + , fb2WriterTest "images" [] "fb2/images.markdown" "fb2/images.fb2" + , fb2WriterTest "images-embedded" [] "fb2/images-embedded.html" "fb2/images-embedded.fb2" + , fb2WriterTest "math" [] "fb2/math.markdown" "fb2/math.fb2" , fb2WriterTest "tables" [] "tables.native" "tables.fb2" - , fb2WriterTest "math" [] "fb2.math.markdown" "fb2.math.fb2" , fb2WriterTest "testsuite" [] "testsuite.native" "writer.fb2" ] , testGroup "mediawiki" @@ -126,10 +126,8 @@ tests = [ testGroup "markdown" ] , testGroup "dokuwiki" [ testGroup "writer" $ writerTests "dokuwiki" - , test "writer-more" ["-r", "native", "-w", "dokuwiki", "-s"] - "dokuwiki-writer.native" "dokuwiki-writer.dokuwiki" - , test "writer-inline_formatting" ["-r", "native", "-w", "dokuwiki", "-s"] - "dokuwiki.inline_formatting.native" "dokuwiki.inline_formatting.dokuwiki" + , test "inline_formatting" ["-r", "native", "-w", "dokuwiki", "-s"] + "dokuwiki_inline_formatting.native" "dokuwiki_inline_formatting.dokuwiki" ] , testGroup "opml" [ test "basic" ["-r", "native", "-w", "opml", "--columns=78", "-s"] @@ -147,11 +145,11 @@ tests = [ testGroup "markdown" "txt2tags.t2t" "txt2tags.native" ] , testGroup "epub" [ test "features" ["-r", "epub", "-w", "native"] - "epub.features.epub" "epub.features.native" + "epub/features.epub" "epub/features.native" , test "wasteland" ["-r", "epub", "-w", "native"] - "epub.wasteland.epub" "epub.wasteland.native" + "epub/wasteland.epub" "epub/wasteland.native" , test "formatting" ["-r", "epub", "-w", "native"] - "epub.formatting.epub" "epub.formatting.native" + "epub/formatting.epub" "epub/formatting.native" ] , testGroup "other writers" $ map (\f -> testGroup f $ writerTests f) [ "opendocument" , "context" , "texinfo", "icml" @@ -194,7 +192,7 @@ s5WriterTest :: String -> [String] -> String -> Test s5WriterTest modifier opts format = test (format ++ " writer (" ++ modifier ++ ")") (["-r", "native", "-w", format] ++ opts) - "s5.native" ("s5." ++ modifier <.> "html") + "s5.native" ("s5-" ++ modifier <.> "html") fb2WriterTest :: String -> [String] -> String -> String -> Test fb2WriterTest title opts inputfile normfile = diff --git a/tests/Tests/Readers/Docx.hs b/tests/Tests/Readers/Docx.hs index 65fdd4a55..0e0f6c2c5 100644 --- a/tests/Tests/Readers/Docx.hs +++ b/tests/Tests/Readers/Docx.hs @@ -100,135 +100,135 @@ tests :: [Test] tests = [ testGroup "inlines" [ testCompare "font formatting" - "docx.inline_formatting.docx" - "docx.inline_formatting.native" + "docx/inline_formatting.docx" + "docx/inline_formatting.native" , testCompare "hyperlinks" - "docx.links.docx" - "docx.links.native" + "docx/links.docx" + "docx/links.native" , testCompare "inline image" - "docx.image.docx" - "docx.image_no_embed.native" + "docx/image.docx" + "docx/image_no_embed.native" , testCompare "inline image in links" - "docx.inline_images.docx" - "docx.inline_images.native" + "docx/inline_images.docx" + "docx/inline_images.native" , testCompare "handling unicode input" - "docx.unicode.docx" - "docx.unicode.native" + "docx/unicode.docx" + "docx/unicode.native" , testCompare "literal tabs" - "docx.tabs.docx" - "docx.tabs.native" + "docx/tabs.docx" + "docx/tabs.native" , testCompare "normalizing inlines" - "docx.normalize.docx" - "docx.normalize.native" + "docx/normalize.docx" + "docx/normalize.native" , testCompare "normalizing inlines deep inside blocks" - "docx.deep_normalize.docx" - "docx.deep_normalize.native" + "docx/deep_normalize.docx" + "docx/deep_normalize.native" , testCompare "move trailing spaces outside of formatting" - "docx.trailing_spaces_in_formatting.docx" - "docx.trailing_spaces_in_formatting.native" + "docx/trailing_spaces_in_formatting.docx" + "docx/trailing_spaces_in_formatting.native" , testCompare "inline code (with VerbatimChar style)" - "docx.inline_code.docx" - "docx.inline_code.native" + "docx/inline_code.docx" + "docx/inline_code.native" ] , testGroup "blocks" [ testCompare "headers" - "docx.headers.docx" - "docx.headers.native" + "docx/headers.docx" + "docx/headers.native" , testCompare "headers already having auto identifiers" - "docx.already_auto_ident.docx" - "docx.already_auto_ident.native" + "docx/already_auto_ident.docx" + "docx/already_auto_ident.native" , testCompare "lists" - "docx.lists.docx" - "docx.lists.native" + "docx/lists.docx" + "docx/lists.native" , testCompare "definition lists" - "docx.definition_list.docx" - "docx.definition_list.native" + "docx/definition_list.docx" + "docx/definition_list.native" , testCompare "footnotes and endnotes" - "docx.notes.docx" - "docx.notes.native" + "docx/notes.docx" + "docx/notes.native" , testCompare "blockquotes (parsing indent as blockquote)" - "docx.block_quotes.docx" - "docx.block_quotes_parse_indent.native" + "docx/block_quotes.docx" + "docx/block_quotes_parse_indent.native" , testCompare "hanging indents" - "docx.hanging_indent.docx" - "docx.hanging_indent.native" + "docx/hanging_indent.docx" + "docx/hanging_indent.native" , testCompare "tables" - "docx.tables.docx" - "docx.tables.native" + "docx/tables.docx" + "docx/tables.native" , testCompare "code block" - "docx.codeblock.docx" - "docx.codeblock.native" + "docx/codeblock.docx" + "docx/codeblock.native" , testCompare "dropcap paragraphs" - "docx.drop_cap.docx" - "docx.drop_cap.native" + "docx/drop_cap.docx" + "docx/drop_cap.native" ] , testGroup "track changes" [ testCompare "insertion (default)" - "docx.track_changes_insertion.docx" - "docx.track_changes_insertion_accept.native" + "docx/track_changes_insertion.docx" + "docx/track_changes_insertion_accept.native" , testCompareWithOpts def{readerTrackChanges=AcceptChanges} "insert insertion (accept)" - "docx.track_changes_insertion.docx" - "docx.track_changes_insertion_accept.native" + "docx/track_changes_insertion.docx" + "docx/track_changes_insertion_accept.native" , testCompareWithOpts def{readerTrackChanges=RejectChanges} "remove insertion (reject)" - "docx.track_changes_insertion.docx" - "docx.track_changes_insertion_reject.native" + "docx/track_changes_insertion.docx" + "docx/track_changes_insertion_reject.native" , testCompare "deletion (default)" - "docx.track_changes_deletion.docx" - "docx.track_changes_deletion_accept.native" + "docx/track_changes_deletion.docx" + "docx/track_changes_deletion_accept.native" , testCompareWithOpts def{readerTrackChanges=AcceptChanges} "remove deletion (accept)" - "docx.track_changes_deletion.docx" - "docx.track_changes_deletion_accept.native" + "docx/track_changes_deletion.docx" + "docx/track_changes_deletion_accept.native" , testCompareWithOpts def{readerTrackChanges=RejectChanges} "insert deletion (reject)" - "docx.track_changes_deletion.docx" - "docx.track_changes_deletion_reject.native" + "docx/track_changes_deletion.docx" + "docx/track_changes_deletion_reject.native" , testCompareWithOpts def{readerTrackChanges=AllChanges} "keep insertion (all)" - "docx.track_changes_deletion.docx" - "docx.track_changes_deletion_all.native" + "docx/track_changes_deletion.docx" + "docx/track_changes_deletion_all.native" , testCompareWithOpts def{readerTrackChanges=AllChanges} "keep deletion (all)" - "docx.track_changes_deletion.docx" - "docx.track_changes_deletion_all.native" + "docx/track_changes_deletion.docx" + "docx/track_changes_deletion_all.native" ] , testGroup "media" [ testMediaBag "image extraction" - "docx.image.docx" + "docx/image.docx" ] , testGroup "metadata" [ testCompareWithOpts def{readerStandalone=True} "metadata fields" - "docx.metadata.docx" - "docx.metadata.native" + "docx/metadata.docx" + "docx/metadata.native" , testCompareWithOpts def{readerStandalone=True} "stop recording metadata with normal text" - "docx.metadata_after_normal.docx" - "docx.metadata_after_normal.native" + "docx/metadata_after_normal.docx" + "docx/metadata_after_normal.native" ] ] diff --git a/tests/Tests/Readers/EPUB.hs b/tests/Tests/Readers/EPUB.hs index 01b68082b..f27ea979f 100644 --- a/tests/Tests/Readers/EPUB.hs +++ b/tests/Tests/Readers/EPUB.hs @@ -28,6 +28,6 @@ tests :: [Test] tests = [ testGroup "EPUB Mediabag" [ testCase "features bag" - (testMediaBag "epub.features.epub" featuresBag) + (testMediaBag "epub/features.epub" featuresBag) ] ] |