Revamped tests, using markdown output instead of HTML.

This is easier to inspect.
This commit is contained in:
John MacFarlane 2010-11-28 10:02:40 -08:00
parent 61b16116ce
commit 68d38db194
8 changed files with 136 additions and 257 deletions

View file

@ -107,7 +107,7 @@ main = do
"latex-reader.latex" "latex-reader.native"
r11 <- runTest "native reader" ["-r", "native", "-w", "native", "-s"]
"testsuite.native" "testsuite.native"
r14s <- mapM (\style -> runTest ("markdown reader (citations) (" ++ style ++ ")") ["-r", "markdown", "-w", "html", "--bibliography", "biblio.bib", "--csl", style ++ ".csl"] "markdown-citations.txt" ("markdown-citations." ++ style ++ ".html")) ["chicago-author-date","ieee","mhra"]
r14s <- mapM (\style -> runTest ("markdown reader (citations) (" ++ style ++ ")") ["-r", "markdown", "-w", "markdown", "--bibliography", "biblio.bib", "--csl", style ++ ".csl", "--no-wrap"] "markdown-citations.txt" ("markdown-citations." ++ style ++ ".txt")) ["chicago-author-date","ieee","mhra"]
r12s <- if runLhsTests
then mapM runLhsWriterTest lhsWriterFormats
else putStrLn "Skipping lhs writer tests because they presuppose highlighting support" >> return []

View file

@ -1,56 +0,0 @@
<h1 id="pandoc-with-citeproc-hs"
>Pandoc with citeproc-hs</h1
><p
>[@nonexistent]</p
><p
>@nonexistent</p
><p
>Doe (2005) says blah. Doe (2005, 30) says blah. Doe (2005, 30, with suffix) says blah. Doe (2005; 2006, 30; see also Doe and Roe 2007) says blah.</p
><p
>In a note.<sup
><a href="#fn1" class="footnoteRef" id="fnref1"
>1</a
></sup
> A citation group (see Doe 2005, 3435; also Doe and Roe 2007, chap. 3). Another one (see Doe 2005, 3435). And another one in a note.<sup
><a href="#fn2" class="footnoteRef" id="fnref2"
>2</a
></sup
> Citation with a suffix and locator (Doe 2005, 33, 3537, and nowhere else). Citation with suffix only (Doe 2005, and nowhere else).</p
><p
>Now some modifiers.<sup
><a href="#fn3" class="footnoteRef" id="fnref3"
>3</a
></sup
></p
><h1 id="references"
>References</h1
><p
>Doe, John. 2005. <em
>First Book</em
>. Cambridge: Cambridge University Press.</p
><p
>---. 2006. Article. <em
>Journal of Generic Studies</em
> 6: 3334.</p
><p
>Doe, John, and Jenny Roe. 2007. Why Water Is Wet. In <em
>Third Book</em
>, ed. Sam Smith. Oxford: Oxford University Press.</p
><div class="footnotes"
><hr
/><ol
><li id="fn1"
><p
>A citation without locators (Doe and Roe 2007). <a href="#fnref1" class="footnoteBackLink" title="Jump back to footnote 1"></a></p
></li
><li id="fn2"
><p
>Some citations (see Doe 2006, chap. 3; Doe and Roe 2007; Doe 2005). <a href="#fnref2" class="footnoteBackLink" title="Jump back to footnote 2"></a></p
></li
><li id="fn3"
><p
>Like a citation without author: (2005), and now Doe with a locator (2006, 44). <a href="#fnref3" class="footnoteBackLink" title="Jump back to footnote 3"></a></p
></li
></ol
></div
>

View file

@ -0,0 +1,32 @@
# Pandoc with citeproc-hs
- [@nonexistent]
- @nonexistent
- Doe (2005) says blah.
- Doe (2005, 30) says blah.
- Doe (2005, 30, with suffix) says blah.
- Doe (2005; 2006, 30; see also Doe and Roe 2007) says blah.
- In a note.[^1]
- A citation group (see Doe 2005, 3435; also Doe and Roe 2007, chap. 3).
- Another one (see Doe 2005, 3435).
- And another one in a note.[^2]
- Citation with a suffix and locator (Doe 2005, 33, 3537, and nowhere else).
- Citation with suffix only (Doe 2005, and nowhere else).
- Now some modifiers.[^3]
# References
Doe, John. 2005. *First Book*. Cambridge: Cambridge University Press.
---. 2006. Article. *Journal of Generic Studies* 6: 3334.
Doe, John, and Jenny Roe. 2007. Why Water Is Wet. In *Third Book*, ed. Sam Smith. Oxford: Oxford University Press.
[^1]:
A citation without locators (Doe and Roe 2007).
[^2]:
Some citations (see Doe 2006, chap. 3; Doe and Roe 2007; Doe 2005).
[^3]:
Like a citation without author: (2005), and now Doe with a locator (2006, 44).

View file

@ -1,56 +0,0 @@
<h1 id="pandoc-with-citeproc-hs"
>Pandoc with citeproc-hs</h1
><p
>[@nonexistent]</p
><p
>@nonexistent</p
><p
>Reference [1] says blah. Reference [1] says blah. Reference [1] says blah. Reference [1] says blah.</p
><p
>In a note.<sup
><a href="#fn1" class="footnoteRef" id="fnref1"
>1</a
></sup
> A citation group [1],[3]. Another one [1]. And another one in a note.<sup
><a href="#fn2" class="footnoteRef" id="fnref2"
>2</a
></sup
> Citation with a suffix and locator [1]. Citation with suffix only [1].</p
><p
>Now some modifiers.<sup
><a href="#fn3" class="footnoteRef" id="fnref3"
>3</a
></sup
></p
><h1 id="references"
>References</h1
><p
>[1] J. Doe, <em
>First Book</em
>, Cambridge: Cambridge University Press, 2005.</p
><p
>[2] J. Doe, “Article”, <em
>Journal of Generic Studies</em
>, vol. 6, 2006, pp. 3334.</p
><p
>[3] J. Doe and J. Roe, “Why Water Is Wet”, <em
>Third Book</em
>, Smith, S., Ed., Oxford: Oxford University Press, 2007.</p
><div class="footnotes"
><hr
/><ol
><li id="fn1"
><p
>A citation without locators [3]. <a href="#fnref1" class="footnoteBackLink" title="Jump back to footnote 1"></a></p
></li
><li id="fn2"
><p
>Some citations [1]-[3]. <a href="#fnref2" class="footnoteBackLink" title="Jump back to footnote 2"></a></p
></li
><li id="fn3"
><p
>Like a citation without author: [1], and now Doe with a locator [2]. <a href="#fnref3" class="footnoteBackLink" title="Jump back to footnote 3"></a></p
></li
></ol
></div
>

View file

@ -0,0 +1,32 @@
# Pandoc with citeproc-hs
- [@nonexistent]
- @nonexistent
- Reference [1] says blah.
- Reference [1] says blah.
- Reference [1] says blah.
- Reference [1] says blah.
- In a note.[^1]
- A citation group [1],[3].
- Another one [1].
- And another one in a note.[^2]
- Citation with a suffix and locator [1].
- Citation with suffix only [1].
- Now some modifiers.[^3]
# References
[1] J. Doe, *First Book*, Cambridge: Cambridge University Press, 2005.
[2] J. Doe, “Article”, *Journal of Generic Studies*, vol. 6, 2006, pp. 33-34.
[3] J. Doe and J. Roe, “Why Water Is Wet”, *Third Book*, Smith, S., Ed., Oxford: Oxford University Press, 2007.
[^1]:
A citation without locators [3].
[^2]:
Some citations [1]-[3].
[^3]:
Like a citation without author: [1], and now Doe with a locator [2].

View file

@ -1,126 +0,0 @@
<h1 id="pandoc-with-citeproc-hs"
>Pandoc with citeproc-hs</h1
><p
>[@nonexistent]</p
><p
>@nonexistent</p
><p
>John Doe<sup
><a href="#fn1" class="footnoteRef" id="fnref1"
>1</a
></sup
> says blah. Doe<sup
><a href="#fn2" class="footnoteRef" id="fnref2"
>2</a
></sup
> says blah. Doe<sup
><a href="#fn3" class="footnoteRef" id="fnref3"
>3</a
></sup
> says blah. Doe<sup
><a href="#fn4" class="footnoteRef" id="fnref4"
>4</a
></sup
> says blah.</p
><p
>In a note.<sup
><a href="#fn5" class="footnoteRef" id="fnref5"
>5</a
></sup
> A citation group.<sup
><a href="#fn6" class="footnoteRef" id="fnref6"
>6</a
></sup
> Another one.<sup
><a href="#fn7" class="footnoteRef" id="fnref7"
>7</a
></sup
> And another one in a note.<sup
><a href="#fn8" class="footnoteRef" id="fnref8"
>8</a
></sup
> Citation with a suffix and locator.<sup
><a href="#fn9" class="footnoteRef" id="fnref9"
>9</a
></sup
> Citation with suffix only.<sup
><a href="#fn10" class="footnoteRef" id="fnref10"
>10</a
></sup
></p
><p
>Now some modifiers.<sup
><a href="#fn11" class="footnoteRef" id="fnref11"
>11</a
></sup
></p
><h1 id="references"
>References</h1
><p
>Doe, John, Article, <em
>Journal of Generic Studies</em
>, 6 (2006), 3334.</p
><p
>---, <em
>First Book</em
> (Cambridge: Cambridge University Press, 2005).</p
><p
>Doe, John, and Jenny Roe, Why Water Is Wet, in <em
>Third Book</em
>, ed by Sam Smith (Oxford: Oxford University Press, 2007).</p
><div class="footnotes"
><hr
/><ol
><li id="fn1"
><p
><em
>First Book</em
> (Cambridge: Cambridge University Press, 2005). <a href="#fnref1" class="footnoteBackLink" title="Jump back to footnote 1"></a></p
></li
><li id="fn2"
><p
>First Book, p. 30. <a href="#fnref2" class="footnoteBackLink" title="Jump back to footnote 2"></a></p
></li
><li id="fn3"
><p
>First Book, p. 30, with suffix. <a href="#fnref3" class="footnoteBackLink" title="Jump back to footnote 3"></a></p
></li
><li id="fn4"
><p
>First Book; Article, <em
>Journal of Generic Studies</em
>, 6 (2006), 3334 (p. 30); see also John Doe and Jenny Roe, Why Water Is Wet, in <em
>Third Book</em
>, ed by Sam Smith (Oxford: Oxford University Press, 2007). <a href="#fnref4" class="footnoteBackLink" title="Jump back to footnote 4"></a></p
></li
><li id="fn5"
><p
>A citation without locators Doe and Roe. <a href="#fnref5" class="footnoteBackLink" title="Jump back to footnote 5"></a></p
></li
><li id="fn6"
><p
>See Doe, First Book, pp. 3435; also Doe and Roe, chap. 3. <a href="#fnref6" class="footnoteBackLink" title="Jump back to footnote 6"></a></p
></li
><li id="fn7"
><p
>See Doe, First Book, pp. 3435. <a href="#fnref7" class="footnoteBackLink" title="Jump back to footnote 7"></a></p
></li
><li id="fn8"
><p
>Some citations see Doe, Article, 3334 (chap. 3); Doe and Roe; Doe, First Book. <a href="#fnref8" class="footnoteBackLink" title="Jump back to footnote 8"></a></p
></li
><li id="fn9"
><p
>Doe, First Book, pp. 33, 3537, and nowhere else. <a href="#fnref9" class="footnoteBackLink" title="Jump back to footnote 9"></a></p
></li
><li id="fn10"
><p
>Doe, First Book, and nowhere else. <a href="#fnref10" class="footnoteBackLink" title="Jump back to footnote 10"></a></p
></li
><li id="fn11"
><p
>Like a citation without author: First Book, and now Doe with a locator Article, 3334 (p. 44). <a href="#fnref11" class="footnoteBackLink" title="Jump back to footnote 11"></a></p
></li
></ol
></div
>

View file

@ -0,0 +1,56 @@
# Pandoc with citeproc-hs
- [@nonexistent]
- @nonexistent
- John Doe[^1] says blah.
- Doe[^2] says blah.
- Doe[^3] says blah.
- Doe[^4] says blah.
- In a note.[^5]
- A citation group.[^6]
- Another one.[^7]
- And another one in a note.[^8]
- Citation with a suffix and locator.[^9]
- Citation with suffix only.[^10]
- Now some modifiers.[^11]
# References
Doe, John, Article, *Journal of Generic Studies*, 6 (2006), 33-34.
---, *First Book* (Cambridge: Cambridge University Press, 2005).
Doe, John, and Jenny Roe, Why Water Is Wet, in *Third Book*, ed by Sam Smith (Oxford: Oxford University Press, 2007).
[^1]:
*First Book* (Cambridge: Cambridge University Press, 2005).
[^2]:
First Book, p. 30.
[^3]:
First Book, p. 30, with suffix.
[^4]:
First Book; Article, *Journal of Generic Studies*, 6 (2006), 33-34 (p. 30); see also John Doe and Jenny Roe, Why Water Is Wet, in *Third Book*, ed by Sam Smith (Oxford: Oxford University Press, 2007).
[^5]:
A citation without locators Doe and Roe.
[^6]:
See Doe, First Book, pp. 34-35; also Doe and Roe, chap. 3.
[^7]:
See Doe, First Book, pp. 34-35.
[^8]:
Some citations see Doe, Article, 33-34 (chap. 3); Doe and Roe; Doe, First Book.
[^9]:
Doe, First Book, pp. 33, 35-37, and nowhere else.
[^10]:
Doe, First Book, and nowhere else.
[^11]:
Like a citation without author: First Book, and now Doe with a locator Article, 33-34 (p. 44).

View file

@ -1,22 +1,19 @@
# Pandoc with citeproc-hs
[@nonexistent]
@nonexistent
@item1 says blah.
@item1 [p. 30] says blah.
@item1 [p. 30, with suffix] says blah.
@item1 [-@item2 p. 30; see also @item3] says blah.
In a note.[^1] A citation group [see
@item1 p. 34-35; also @item3 chap. 3]. Another one [see
@item1 p. 34-35]. And another one in a note.[^2]
Citation with a suffix and locator [@item1 pp. 33, 35-37,
and nowhere else]. Citation with suffix only
[@item1, and nowhere else].
Now some modifiers.[^3]
- [@nonexistent]
- @nonexistent
- @item1 says blah.
- @item1 [p. 30] says blah.
- @item1 [p. 30, with suffix] says blah.
- @item1 [-@item2 p. 30; see also @item3] says blah.
- In a note.[^1]
- A citation group [see @item1, p. 34-35; also @item3 chap. 3].
- Another one [see
@item1 p. 34-35].
- And another one in a note.[^2]
- Citation with a suffix and locator [@item1, pp. 33, 35-37, and nowhere else].
- Citation with suffix only [@item1, and nowhere else].
- Now some modifiers.[^3]
[^1]:
A citation without locators [@item3].
@ -26,7 +23,7 @@ Now some modifiers.[^3]
[^3]:
Like a citation without author: [-@item1], and now Doe with a
locator [-@item2 p. 44].
locator [-@item2, p. 44].
# References