Skip to content

Commit

Permalink
Muse writer: add regressions tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexander Krotov committed Mar 7, 2017
1 parent 1ae1d56 commit 27f70c5
Show file tree
Hide file tree
Showing 4 changed files with 823 additions and 0 deletions.
2 changes: 2 additions & 0 deletions pandoc.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,7 @@ Extra-Source-Files:
test/tables.rtf
test/tables.txt
test/tables.fb2
test/tables.muse
test/testsuite.txt
test/writer.latex
test/writer.context
Expand All @@ -195,6 +196,7 @@ Extra-Source-Files:
test/writer.opml
test/writer.dokuwiki
test/writer.zimwiki
test/writer.muse
test/writers-lang-and-dir.latex
test/writers-lang-and-dir.context
test/dokuwiki_inline_formatting.dokuwiki
Expand Down
3 changes: 3 additions & 0 deletions test/Tests/Old.hs
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,9 @@ tests = [ testGroup "markdown"
, test "context" ["-f", "native", "-t", "context", "-s"]
"writers-lang-and-dir.native" "writers-lang-and-dir.context"
]
, testGroup "muse"
[ testGroup "writer" $ writerTests "muse"
]
]

-- makes sure file is fully closed after reading
Expand Down
46 changes: 46 additions & 0 deletions test/tables.muse
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
Simple table with caption:

Right || Left || Center || Default
12 | 12 | 12 | 12
123 | 123 | 123 | 123
1 | 1 | 1 | 1
|+ Demonstration of simple table syntax. +|

Simple table without caption:

Right || Left || Center || Default
12 | 12 | 12 | 12
123 | 123 | 123 | 123
1 | 1 | 1 | 1

Simple table indented two spaces:

Right || Left || Center || Default
12 | 12 | 12 | 12
123 | 123 | 123 | 123
1 | 1 | 1 | 1
|+ Demonstration of simple table syntax. +|

Multiline table with caption:

Centered Header || Left Aligned || Right Aligned || Default aligned
First | row | 12.0 | Example of a row that spans multiple lines.
Second | row | 5.0 | Here’s another one. Note the blank line between rows.
|+ Here’s the caption. It may span multiple lines. +|

Multiline table without caption:

Centered Header || Left Aligned || Right Aligned || Default aligned
First | row | 12.0 | Example of a row that spans multiple lines.
Second | row | 5.0 | Here’s another one. Note the blank line between rows.

Table without column headers:

12 | 12 | 12 | 12
123 | 123 | 123 | 123
1 | 1 | 1 | 1

Multiline table without column headers:

First | row | 12.0 | Example of a row that spans multiple lines.
Second | row | 5.0 | Here’s another one. Note the blank line between rows.
Loading

0 comments on commit 27f70c5

Please sign in to comment.