From 12e8343068b906f8b2afddc5569968a8a91fa5b0 Mon Sep 17 00:00:00 2001
From: Daniel Baumann **Helloworld ![test] ![test](foo bar) an (: </ 123> (hai). foo bar blockquote
+blockquote continuation bar b foo
+bar
+baz foo1
+foo2 quote [link](a\ b) [](<foo [](url (xxx()) a
+?> City:
+
+
+
+.
+
+.
+
+Underscore between punctuation chars should be able to close emphasis.
+
+.
+_(hai)_.
+.
+just a funny little fence
+
+
+
+
+
+
+.
+
+Blockquote should terminate itself after paragraph continuation
+.
+- list
+ > blockquote
+blockquote continuation
+ - next list item
+.
+
+
+.
+
+Regression test (code block + regular paragraph)
+.
+> foo
+> bar
+.
+
+
+
+
+
+
+.
+
+Blockquotes inside indented lists should terminate correctly
+.
+ - a
+ > b
+ ```
+ c
+ ```
+ - d
+.
+
+foo
+
+
+.
+
+Don't output empty class here:
+.
+```
+test
+```
+.
+
+
+
+c
+
+.
+
+Setext header text supports lazy continuations:
+.
+ - foo
+bar
+ ===
+.
+test
+
+
+.
+
+But setext header underline doesn't:
+.
+ - foo
+ bar
+ ===
+.
+foo
+bar
+
+
+.
+
+Tabs should be stripped from the beginning of the line
+.
+ foo
+ bar
+ baz
+.
+
+bar
+
+.
+
+Escaped space is not allowed in link destination, commonmark/CommonMark#493.
+.
+[link](a\ b)
+.
+
+
+
`foo
+. + + +Coverage. Should continue scanning after closing "```" despite cache +. +```aaa``bbb``ccc```ddd``eee`` +. +aaa``bbb``ccc
dddeee
&
++
&
+. + + +Coverage. Escape. +. +*\a* +. +\a
+. + + +Coverage. parseLinkDestination +. +[foo](< +bar>) + +[foo]([foo](<bar)
+. + + +Coverage. parseLinkTitle +. +[foo](bar "ba) + +[foo](bar "ba\ +z") +. +[foo](bar "ba)
+ +. + + +Coverage. Image +. +![test]( x ) +. + +. +. +![test][foo] + +[bar]: 123 +. +![test][foo]
+. +. +![test][[[ + +[bar]: 123 +. +![test][[[
+. +. +![test]( +. +![test](
+. + + +Coverage. Link +. +[test]( +. +[test](
+. + + +Coverage. Reference +. +[ +test\ +]: 123 +foo +bar +. +foo +bar
+. +. +[ +test +] +. +[ +test +]
+. +. +> [foo]: bar +[foo] +. + + +. + +Coverage. Tabs in blockquotes. +. +> test + + > test + + > test + +> --- +> test + + > --- + > test + + > --- + > test + +> test + + > test + + > test + +> --- +> test + + > --- + > test + + > --- + > test +. ++++test +
+++test +
+++test +
++
++test +
++
++test +
++
++test +
+++test +
+++test +
+++test +
++
++test +
++
++test +
++. + +Coverage. Tabs in lists. +. +1. foo + + bar +. +
++test +
foo
+ bar
+
+++foo +- - - -
+
++. + +Coverage, entities with code > 10FFFF. Made this way for compatibility with commonmark.js. +. + + + +. +foo +# not a heading
+
�
+�
+. + +Issue #696. Blockquotes should remember their level. +. +>>> foo +bar +>>> baz +. +++. + +Issue #696. Blockquotes should stop when outdented from a list. +. +1. >>> foo + bar +baz + >>> foo + >>> bar + >>> baz +. +++++foo +bar +baz
+
++++++foo +bar +baz +foo
+
++. + +Newline in image description +. +There is a newline in this image ![here +it is](https://github.com/executablebooks/) +. +++++bar +baz
+
There is a newline in this image
+. + +Issue #772. Header rule should not interfere with html tags. +. + + ++== ++. + +
+== ++. + +Issue #205. Space in link destination generates IndexError +. +[Contact](http:// mail.com) + +[Contact](mailto: mail@mail.com) +. +
[Contact](http:// mail.com)
+[Contact](mailto: mail@mail.com)
+. + +Issue #204. Combination of blockquotes, list and newlines causes an IndexError +. +> QUOTE ++ UNORDERED LIST ITEM + > INDENTED QUOTE + + + +. +++QUOTE
+
++INDENTED QUOTE
+
foo baz bim
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 362
+
+.
+ foo baz bim
+.
+foo baz bim
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 369
+
+.
+ a a
+ ὐ a
+.
+a a
+ὐ a
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 382
+
+.
+ - foo
+
+ bar
+.
+foo
+bar
+foo
+ bar
+
+++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 427 + +. +- foo +. ++foo +
foo
+
+foo
+bar
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 448
+
+.
+ - foo
+ - bar
+ - baz
+.
+!"#$%&'()*+,-./:;<=>?@[\]^_`{|}~
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 499 + +. +\ \A\a\ \3\φ\« +. +\ \A\a\ \3\φ\«
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 509 + +. +\*not emphasized* +\*not emphasized* +<br/> not a tag +[not a link](/foo) +`not code` +1. not a list +* not a list +# not a heading +[foo]: /url "not a reference" +ö not a character entity
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 534 + +. +\\*emphasis* +. +\emphasis
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 543 + +. +foo\ +bar +. +foo
+bar
\[\`
\[\]
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 570
+
+.
+~~~
+\[\]
+~~~
+.
+\[\]
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 580
+
+.
+foo
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 649
+
+.
+ & © Æ Ď
+¾ ℋ ⅆ
+∲ ≧̸
+.
+& © Æ Ď +¾ ℋ ⅆ +∲ ≧̸
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 668 + +. +# Ӓ Ϡ +. +# Ӓ Ϡ �
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 681 + +. +" ആ ಫ +. +" ആ ಫ
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 690 + +. +  &x; + +abcdef0; +&ThisIsNotDefined; &hi?; +. +  &x; &#; &#x; +� +&#abcdef0; +&ThisIsNotDefined; &hi?;
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 707 + +. +© +. +©
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 717 + +. +&MadeUpEntity; +. +&MadeUpEntity;
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 728 + +. + +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 735 + +. +[foo](/föö "föö") +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 742 + +. +[foo] + +[foo]: /föö "föö" +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 751 + +. +``` föö +foo +``` +. +foo
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 764
+
+.
+`föö`
+.
+föö
föfö
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 783
+
+.
+*foo*
+*foo*
+.
+*foo* +foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 791 + +. +* foo + +* foo +. +* foo
+foo + +bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 810 + +. + foo +. +foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 817 + +. +[a](url "tit") +. +[a](url "tit")
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 840 + +. +- `one +- two` +. ++++
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 899 + +. +=== +. +===
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 908 + +. +-- +** +__ +. +-- +** +__
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 921 + +. + *** + *** + *** +. +***
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 942
+
+.
+Foo
+ ***
+.
+Foo +***
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 953 + +. +_____________________________________ +. +_ _ _ _ a
+a------
+---a---
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1010 + +. + *-* +. +-
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1019 + +. +- foo +*** +- bar +. +Foo
+bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1053 + +. +Foo +--- +bar +. +bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1066 + +. +* Foo +* * * +* Bar +. +####### foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1146 + +. +#5 bolt + +#hashtag +. +#5 bolt
+#hashtag
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1158 + +. +\## foo +. +## foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1167 + +. +# foo *bar* \*baz\* +. +# foo
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 1206
+
+.
+foo
+ # bar
+.
+foo +# bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1217 + +. +## foo ## + ### bar ### +. +Foo bar
+Bar foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1307 + +. +## +# +### ### +. + + + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1350 + +. +Foo *bar* +========= + +Foo *bar* +--------- +. +Foo
+---
+
+Foo
+
+Foo +---
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1463 + +. +Foo += = + +Foo +--- - +. +Foo += =
+Foo
+`
+of dashes"/>
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1519 + +. +> Foo +--- +. +++Foo
+
++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1543 + +. +- Foo +--- +. +foo +bar +===
+
Baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1588 + +. + +==== +. +====
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1600 + +. +--- +--- +. +foo
+
+++foo
+
Foo
+baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1691 + +. +Foo +bar + +--- + +baz +. +Foo +bar
+baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1709 + +. +Foo +bar +* * * +baz +. +Foo +bar
+baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1724 + +. +Foo +bar +\--- +baz +. +Foo +bar +--- +baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1752 + +. + a simple + indented code block +. +a simple
+ indented code block
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 1766
+
+.
+ - foo
+
+ bar
+.
+foo
+bar
+foo
+<a/>
+*hi*
+
+- one
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 1816
+
+.
+ chunk1
+
+ chunk2
+
+
+
+ chunk3
+.
+chunk1
+
+chunk2
+
+
+
+chunk3
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 1839
+
+.
+ chunk1
+
+ chunk2
+.
+chunk1
+
+ chunk2
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 1854
+
+.
+Foo
+ bar
+
+.
+Foo +bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1868 + +. + foo +bar +. +foo
+
+bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 1881 + +. +# Heading + foo +Heading +------ + foo +---- +. +foo
+
+foo
+
+ foo
+bar
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 1914
+
+.
+
+
+ foo
+
+
+.
+foo
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 1928
+
+.
+ foo
+.
+foo
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 1983
+
+.
+```
+<
+ >
+```
+.
+<
+ >
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 1997
+
+.
+~~~
+<
+ >
+~~~
+.
+<
+ >
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2010
+
+.
+``
+foo
+``
+.
+foo
aaa
+~~~
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2033
+
+.
+~~~
+aaa
+```
+~~~
+.
+aaa
+```
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2047
+
+.
+````
+aaa
+```
+``````
+.
+aaa
+```
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2059
+
+.
+~~~~
+aaa
+~~~
+~~~~
+.
+aaa
+~~~
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2074
+
+.
+```
+.
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2081
+
+.
+`````
+
+```
+aaa
+.
+
+```
+aaa
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2094
+
+.
+> ```
+> aaa
+
+bbb
+.
++++aaa +
bbb
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 2110 + +. +``` + + +``` +. +
+
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2124
+
+.
+```
+```
+.
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2136
+
+.
+ ```
+ aaa
+aaa
+```
+.
+aaa
+aaa
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2148
+
+.
+ ```
+aaa
+ aaa
+aaa
+ ```
+.
+aaa
+aaa
+aaa
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2162
+
+.
+ ```
+ aaa
+ aaa
+ aaa
+ ```
+.
+aaa
+ aaa
+aaa
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2178
+
+.
+ ```
+ aaa
+ ```
+.
+```
+aaa
+```
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2193
+
+.
+```
+aaa
+ ```
+.
+aaa
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2203
+
+.
+ ```
+aaa
+ ```
+.
+aaa
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2215
+
+.
+```
+aaa
+ ```
+.
+aaa
+ ```
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2229
+
+.
+``` ```
+aaa
+.
+
+aaa
aaa
+~~~ ~~
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2252
+
+.
+foo
+```
+bar
+```
+baz
+.
+foo
+bar
+
+baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 2269 + +. +foo +--- +~~~ +bar +~~~ +# baz +. +bar
+
+def foo(x)
+ return 3
+end
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2305
+
+.
+~~~~ ruby startline=3 $%@#$
+def foo(x)
+ return 3
+end
+~~~~~~~
+.
+def foo(x)
+ return 3
+end
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2319
+
+.
+````;
+````
+.
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2329
+
+.
+``` aa ```
+foo
+.
+aa
+foo
foo
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2352
+
+.
+```
+``` aaa
+```
+.
+``` aaa
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2431
+
+.
+
++**Hello**, + +_world_. ++ |
++**Hello**, ++ |
+ hi + | +
+ hi + | +
okay.
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 2482 + +. +Markdown
+bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 2561 + +. + +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 2601 + +. ++foo + |
+foo + |
foo
+foo
+import Text.HTML.TagSoup
+
+main :: IO ()
+main = print $ parseTags tags
+
+okay
+.
+
+import Text.HTML.TagSoup
+
+main :: IO ()
+main = print $ parseTags tags
+
+okay
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 2755 + +. + +okay +. + +okay
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 2774 + +. + +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 2794 + +. + +okay +. + +okay
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 2817 + +. + +*foo* +. + +foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 2868 + +. +*bar* +*baz* +. +*bar* +baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 2880 + +. +1. *bar* +. +1. *bar* +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 2893 + +. + +okay +. + +okay
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 2911 + +. +'; + +?> +okay +. +'; + +?> +okay
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 2930 + +. + +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 2939 + +. + +okay +. + +okay
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 2973 + +. + + + +. + +<!-- foo -->
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2984
+
+.
+ <div>
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 2998
+
+.
+Foo
+Foo
+Foo + +baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3071 + +. +Emphasized text.
++Hi + | + +
+Hi + | +
+ Hi + | + +
[foo]: /url 'title
+with blank line'
+[foo]
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3258 + +. +[foo]: +/url + +[foo] +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3270 + +. +[foo]: + +[foo] +. +[foo]:
+[foo]
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3282 + +. +[foo]: <> + +[foo] +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3293 + +. +[foo]:[foo]:
[foo]
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3306 + +. +[foo]: /url\bar\*baz "foo\"bar\baz" + +[foo] +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3317 + +. +[foo] + +[foo]: url +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3329 + +. +[foo] + +[foo]: first +[foo]: second +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3342 + +. +[FOO]: /url + +[Foo] +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3351 + +. +[ΑΓΩ]: /φου + +[αγω] +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3366 + +. +[foo]: /url +. +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3374 + +. +[ +foo +]: /url +bar +. +bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3387 + +. +[foo]: /url "title" ok +. +[foo]: /url "title" ok
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3396 + +. +[foo]: /url +"title" ok +. +"title" ok
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3407 + +. + [foo]: /url "title" + +[foo] +. +[foo]: /url "title"
+
+[foo]
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3421 + +. +``` +[foo]: /url +``` + +[foo] +. +[foo]: /url
+
+[foo]
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3436 + +. +Foo +[bar]: /baz + +[bar] +. +Foo +[bar]: /baz
+[bar]
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3451 + +. +# [Foo] +[foo]: /url +> bar +. +++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3462 + +. +[foo]: /url +bar +=== +[foo] +. +bar
+
=== +foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3485 + +. +[foo]: /foo-url "foo" +[bar]: /bar-url + "bar" +[baz]: /baz-url + +[foo], +[bar], +[baz] +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3506 + +. +[foo] + +> [foo]: /url +. + +++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3528 + +. +aaa + +bbb +. +
aaa
+bbb
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3540 + +. +aaa +bbb + +ccc +ddd +. +aaa +bbb
+ccc +ddd
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3556 + +. +aaa + + +bbb +. +aaa
+bbb
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3569 + +. + aaa + bbb +. +aaa +bbb
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3581 + +. +aaa + bbb + ccc +. +aaa +bbb +ccc
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3595 + +. + aaa +bbb +. +aaa +bbb
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3604 + +. + aaa +bbb +. +aaa
+
+bbb
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3618 + +. +aaa +bbb +. +aaa
+bbb
aaa
+++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3718 + +. +># Foo +>bar +> baz +. +Foo
+bar +baz
+
++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3733 + +. + > # Foo + > bar + > baz +. +Foo
+bar +baz
+
++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3748 + +. + > # Foo + > bar + > baz +. +Foo
+bar +baz
+
> # Foo
+> bar
+> baz
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 3763
+
+.
+> # Foo
+> bar
+baz
+.
+++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3779 + +. +> bar +baz +> foo +. +Foo
+bar +baz
+
++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3803 + +. +> foo +--- +. +bar +baz +foo
+
++foo
+
+++
+- foo
+
+++foo +
bar
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 3854
+
+.
+> ```
+foo
+```
+.
++++
foo
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 3870
+
+.
+> foo
+ - bar
+.
+++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3894 + +. +> +. +foo +- bar
+
++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3902 + +. +> +> +> +. +
++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3914 + +. +> +> foo +> +. +
++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3927 + +. +> foo + +> bar +. +foo
+
++foo
+
++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3949 + +. +> foo +> bar +. +bar
+
++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3962 + +. +> foo +> +> bar +. +foo +bar
+
++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3976 + +. +foo +> bar +. +foo
+bar
+
foo
+++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 3990 + +. +> aaa +*** +> bbb +. +bar
+
++aaa
+
++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4008 + +. +> bar +baz +. +bbb
+
++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4019 + +. +> bar + +baz +. +bar +baz
+
++bar
+
baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4031 + +. +> bar +> +baz +. +++bar
+
baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4047 + +. +> > > foo +bar +. +++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4062 + +. +>>> foo +> bar +>>baz +. +++++foo +bar
+
++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4084 + +. +> code + +> not code +. +++++foo +bar +baz
+
+++code +
++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4138 + +. +A paragraph +with two lines. + + indented code + +> A block quote. +. +not code
+
A paragraph +with two lines.
+indented code
+
+++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4160 + +. +1. A paragraph + with two lines. + + indented code + + > A block quote. +. +A block quote.
+
A paragraph +with two lines.
+indented code
+
+++A block quote.
+
two
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4205 + +. +- one + + two +. +one
+two
+ two
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 4232
+
+.
+ - one
+
+ two
+.
+one
+two
+++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4281 + +. +>>- one +>> + > > two +. ++++
+- +
+one
+two
+
++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4300 + +. +-one + +2.two +. ++++
+- one
+two
+
-one
+2.two
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4313 + +. +- foo + + + bar +. +foo
+bar
+foo
+bar
+
+baz
+++bam
+
Foo
+bar
+
+
+baz
+
+1234567890. not ok
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4398 + +. +0. ok +. +-1. not ok
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4441 + +. +- foo + + bar +. +foo
+bar
+
+foo
+bar
+
+indented code
+
+paragraph
+more code
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 4492
+
+.
+1. indented code
+
+ paragraph
+
+ more code
+.
+indented code
+
+paragraph
+more code
+
+ indented code
+
+paragraph
+more code
+
+foo
+bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4551 + +. +- foo + + bar +. +bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4568 + +. +- foo + + bar +. +foo
+bar
+bar
+
+baz
+
+foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4649 + +. +- foo +- +- bar +. +foo +*
+foo +1.
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4726 + +. + 1. A paragraph + with two lines. + + indented code + + > A block quote. +. +A paragraph +with two lines.
+indented code
+
+++A block quote.
+
A paragraph +with two lines.
+indented code
+
+++A block quote.
+
A paragraph +with two lines.
+indented code
+
+++A block quote.
+
1. A paragraph
+ with two lines.
+
+ indented code
+
+ > A block quote.
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 4828
+
+.
+ 1. A paragraph
+with two lines.
+
+ indented code
+
+ > A block quote.
+.
+A paragraph +with two lines.
+indented code
+
+++A block quote.
+
++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4882 + +. +> 1. > Blockquote +> continued here. +. ++
+- +
+++Blockquote +continued here.
+
++. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 4910 + +. +- foo + - bar + - baz + - boo +. ++
+- +
+++Blockquote +continued here.
+
Foo
+The number of windows in my house is +14. The number of doors is 6.
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 5373 + +. +The number of windows in my house is +1. The number of doors is 6. +. +The number of windows in my house is
+foo
+bar
+baz
+baz
+bim
+foo
+notcode
+foo
+code
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 5490
+
+.
+- a
+ - b
+ - c
+ - d
+ - e
+ - f
+- g
+.
+a
+b
+c
+a
+b
+3. c
+
+.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+src line: 5578
+
+.
+- a
+- b
+
+- c
+.
+a
+b
+c
+a
+c
+a
+b
+c
+d
+a
+b
+d
+b
+
+
+
+b
+c
+++b
+
++b
+
c
+
+foo
+
+bar
+foo
+baz
+a
+d
+hi
lo`
foo
foo ` bar
``
``
a
b
+
foo bar baz
foo
foo bar baz
foo\
bar`
foo`bar
foo `` bar
*foo*
[not a link](/foo
)
<a href="
">`
<http://foo.bar.
baz>`
```foo``
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6085 + +. +`foo +. +`foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6094 + +. +`foo``bar`` +. +`foobar
foo bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6321 + +. +a * foo bar* +. +a * foo bar*
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6332 + +. +a*"foo"* +. +a*"foo"*
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6341 + +. +* a * +. +* a *
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6350 + +. +foo*bar* +. +foobar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6357 + +. +5*6*78 +. +5678
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6366 + +. +_foo bar_ +. +foo bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6376 + +. +_ foo bar_ +. +_ foo bar_
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6386 + +. +a_"foo"_ +. +a_"foo"_
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6395 + +. +foo_bar_ +. +foo_bar_
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6402 + +. +5_6_78 +. +5_6_78
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6409 + +. +пристаням_стремятся_ +. +пристаням_стремятся_
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6419 + +. +aa_"bb"_cc +. +aa_"bb"_cc
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6430 + +. +foo-_(bar)_ +. +foo-(bar)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6442 + +. +_foo* +. +_foo*
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6452 + +. +*foo bar * +. +*foo bar *
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6461 + +. +*foo bar +* +. +*foo bar +*
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6474 + +. +*(*foo) +. +*(*foo)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6484 + +. +*(*foo*)* +. +(foo)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6493 + +. +*foo*bar +. +foobar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6506 + +. +_foo bar _ +. +_foo bar _
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6516 + +. +_(_foo) +. +_(_foo)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6525 + +. +_(_foo_)_ +. +(foo)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6534 + +. +_foo_bar +. +_foo_bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6541 + +. +_пристаням_стремятся +. +_пристаням_стремятся
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6548 + +. +_foo_bar_baz_ +. +foo_bar_baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6559 + +. +_(bar)_. +. +(bar).
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6568 + +. +**foo bar** +. +foo bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6578 + +. +** foo bar** +. +** foo bar**
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6589 + +. +a**"foo"** +. +a**"foo"**
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6598 + +. +foo**bar** +. +foobar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6607 + +. +__foo bar__ +. +foo bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6617 + +. +__ foo bar__ +. +__ foo bar__
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6625 + +. +__ +foo bar__ +. +__ +foo bar__
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6637 + +. +a__"foo"__ +. +a__"foo"__
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6646 + +. +foo__bar__ +. +foo__bar__
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6653 + +. +5__6__78 +. +5__6__78
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6660 + +. +пристаням__стремятся__ +. +пристаням__стремятся__
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6667 + +. +__foo, __bar__, baz__ +. +foo, bar, baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6678 + +. +foo-__(bar)__ +. +foo-(bar)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6691 + +. +**foo bar ** +. +**foo bar **
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6704 + +. +**(**foo) +. +**(**foo)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6714 + +. +*(**foo**)* +. +(foo)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6721 + +. +**Gomphocarpus (*Gomphocarpus physocarpus*, syn. +*Asclepias physocarpa*)** +. +Gomphocarpus (Gomphocarpus physocarpus, syn. +Asclepias physocarpa)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6730 + +. +**foo "*bar*" foo** +. +foo "bar" foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6739 + +. +**foo**bar +. +foobar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6751 + +. +__foo bar __ +. +__foo bar __
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6761 + +. +__(__foo) +. +__(__foo)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6771 + +. +_(__foo__)_ +. +(foo)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6780 + +. +__foo__bar +. +__foo__bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6787 + +. +__пристаням__стремятся +. +__пристаням__стремятся
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6794 + +. +__foo__bar__baz__ +. +foo__bar__baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6805 + +. +__(bar)__. +. +(bar).
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6817 + +. +*foo [bar](/url)* +. +foo bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6824 + +. +*foo +bar* +. +foo +bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6836 + +. +_foo __bar__ baz_ +. +foo bar baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6843 + +. +_foo _bar_ baz_ +. +foo bar baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6850 + +. +__foo_ bar_ +. +foo bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6857 + +. +*foo *bar** +. +foo bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6864 + +. +*foo **bar** baz* +. +foo bar baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6870 + +. +*foo**bar**baz* +. +foobarbaz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6894 + +. +*foo**bar* +. +foo**bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6907 + +. +***foo** bar* +. +foo bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6914 + +. +*foo **bar*** +. +foo bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6921 + +. +*foo**bar*** +. +foobar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6932 + +. +foo***bar***baz +. +foobarbaz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6938 + +. +foo******bar*********baz +. +foobar***baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6947 + +. +*foo **bar *baz* bim** bop* +. +foo bar baz bim bop
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6954 + +. +*foo [*bar*](/url)* +. +foo bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6963 + +. +** is not an empty emphasis +. +** is not an empty emphasis
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6970 + +. +**** is not an empty strong emphasis +. +**** is not an empty strong emphasis
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6983 + +. +**foo [bar](/url)** +. +foo bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 6990 + +. +**foo +bar** +. +foo +bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7002 + +. +__foo _bar_ baz__ +. +foo bar baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7009 + +. +__foo __bar__ baz__ +. +foo bar baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7016 + +. +____foo__ bar__ +. +foo bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7023 + +. +**foo **bar**** +. +foo bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7030 + +. +**foo *bar* baz** +. +foo bar baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7037 + +. +**foo*bar*baz** +. +foobarbaz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7044 + +. +***foo* bar** +. +foo bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7051 + +. +**foo *bar*** +. +foo bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7060 + +. +**foo *bar **baz** +bim* bop** +. +foo bar baz +bim bop
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7069 + +. +**foo [*bar*](/url)** +. +foo bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7078 + +. +__ is not an empty emphasis +. +__ is not an empty emphasis
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7085 + +. +____ is not an empty strong emphasis +. +____ is not an empty strong emphasis
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7095 + +. +foo *** +. +foo ***
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7102 + +. +foo *\** +. +foo *
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7109 + +. +foo *_* +. +foo _
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7116 + +. +foo ***** +. +foo *****
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7123 + +. +foo **\*** +. +foo *
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7130 + +. +foo **_** +. +foo _
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7141 + +. +**foo* +. +*foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7148 + +. +*foo** +. +foo*
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7155 + +. +***foo** +. +*foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7162 + +. +****foo* +. +***foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7169 + +. +**foo*** +. +foo*
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7176 + +. +*foo**** +. +foo***
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7186 + +. +foo ___ +. +foo ___
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7193 + +. +foo _\__ +. +foo _
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7200 + +. +foo _*_ +. +foo *
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7207 + +. +foo _____ +. +foo _____
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7214 + +. +foo __\___ +. +foo _
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7221 + +. +foo __*__ +. +foo *
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7228 + +. +__foo_ +. +_foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7239 + +. +_foo__ +. +foo_
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7246 + +. +___foo__ +. +_foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7253 + +. +____foo_ +. +___foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7260 + +. +__foo___ +. +foo_
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7267 + +. +_foo____ +. +foo___
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7277 + +. +**foo** +. +foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7284 + +. +*_foo_* +. +foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7291 + +. +__foo__ +. +foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7298 + +. +_*foo*_ +. +foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7308 + +. +****foo**** +. +foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7315 + +. +____foo____ +. +foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7326 + +. +******foo****** +. +foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7335 + +. +***foo*** +. +foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7342 + +. +_____foo_____ +. +foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7351 + +. +*foo _bar* baz_ +. +foo _bar baz_
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7358 + +. +*foo __bar *baz bim__ bam* +. +foo bar *baz bim bam
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7367 + +. +**foo **bar baz** +. +**foo bar baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7374 + +. +*foo *bar baz* +. +*foo bar baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7383 + +. +*[bar*](/url) +. +*bar*
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7390 + +. +_foo [bar_](/url) +. +_foo bar_
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7397 + +. +* +. +*
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7404 + +. +** +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7411 + +. +__ +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7418 + +. +*a `*`* +. +a *
a _
[link](/my uri)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7579 + +. +[link]([link](foo +bar)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7596 + +. +[link]([link](
[link](<foo>)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7624 + +. +[a]( +[a](c) +. +[a](<b)c +[a](<b)c> +[a](c)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7636 + +. +[link](\(foo\)) +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7645 + +. +[link](foo(and(bar))) +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7654 + +. +[link](foo(and(bar)) +. +[link](foo(and(bar))
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7661 + +. +[link](foo\(and\(bar\)) +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7668 + +. +[link]([link](/url "title "and" title")
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7782 + +. +[link](/url 'title "and" title') +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7807 + +. +[link]( /uri + "title" ) +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7818 + +. +[link] (/uri) +. +[link] (/uri)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7828 + +. +[link [foo [bar]]](/uri) +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7835 + +. +[link] bar](/uri) +. +[link] bar](/uri)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7842 + +. +[link [bar](/uri) +. +[link bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7849 + +. +[link \[bar](/uri) +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7858 + +. +[link *foo **bar** `#`*](/uri) +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7865 + +. +[![moon](moon.jpg)](/uri) +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7874 + +. +[foo [bar](/uri)](/uri) +. +[foo bar](/uri)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7881 + +. +[foo *[bar [baz](/uri)](/uri)*](/uri) +. +[foo [bar baz](/uri)](/uri)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7888 + +. +![[[foo](uri1)](uri2)](uri3) +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7898 + +. +*[foo*](/uri) +. +*foo*
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7905 + +. +[foo *bar](baz*) +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7915 + +. +*foo [bar* baz] +. +foo [bar baz]
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7925 + +. +[foo[foo
[foo](/uri)
[foohttp://example.com/?search=](uri)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7977 + +. +[foo][bar] + +[bar]: /url "title" +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 7992 + +. +[link [foo [bar]]][ref] + +[ref]: /uri +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8001 + +. +[link \[bar][ref] + +[ref]: /uri +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8012 + +. +[link *foo **bar** `#`*][ref] + +[ref]: /uri +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8021 + +. +[![moon](moon.jpg)][ref] + +[ref]: /uri +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8032 + +. +[foo [bar](/uri)][ref] + +[ref]: /uri +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8041 + +. +[foo *bar [baz][ref]*][ref] + +[ref]: /uri +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8056 + +. +*[foo*][ref] + +[ref]: /uri +. +*foo*
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8065 + +. +[foo *bar][ref]* + +[ref]: /uri +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8077 + +. +[foo[foo
[foo][ref]
[foohttp://example.com/?search=][ref]
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8106 + +. +[foo][BaR] + +[bar]: /url "title" +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8117 + +. +[ẞ] + +[SS]: /url +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8129 + +. +[Foo + bar]: /url + +[Baz][Foo bar] +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8142 + +. +[foo] [bar] + +[bar]: /url "title" +. +[foo] bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8151 + +. +[foo] +[bar] + +[bar]: /url "title" +. +[foo] +bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8192 + +. +[foo]: /url1 + +[foo]: /url2 + +[bar][foo] +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8207 + +. +[bar][foo\!] + +[foo!]: /url +. +[bar][foo!]
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8219 + +. +[foo][ref[] + +[ref[]: /uri +. +[foo][ref[]
+[ref[]: /uri
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8229 + +. +[foo][ref[bar]] + +[ref[bar]]: /uri +. +[foo][ref[bar]]
+[ref[bar]]: /uri
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8239 + +. +[[[foo]]] + +[[[foo]]]: /url +. +[[[foo]]]
+[[[foo]]]: /url
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8249 + +. +[foo][ref\[] + +[ref\[]: /uri +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8260 + +. +[bar\\]: /uri + +[bar\\] +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8272 + +. +[] + +[]: /uri +. +[]
+[]: /uri
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8282 + +. +[ + ] + +[ + ]: /uri +. +[ +]
+[ +]: /uri
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8305 + +. +[foo][] + +[foo]: /url "title" +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8314 + +. +[*foo* bar][] + +[*foo* bar]: /url "title" +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8325 + +. +[Foo][] + +[foo]: /url "title" +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8338 + +. +[foo] +[] + +[foo]: /url "title" +. +foo +[]
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8358 + +. +[foo] + +[foo]: /url "title" +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8367 + +. +[*foo* bar] + +[*foo* bar]: /url "title" +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8376 + +. +[[*foo* bar]] + +[*foo* bar]: /url "title" +. +[foo bar]
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8385 + +. +[[bar [foo] + +[foo]: /url +. +[[bar foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8396 + +. +[Foo] + +[foo]: /url "title" +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8407 + +. +[foo] bar + +[foo]: /url +. +foo bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8419 + +. +\[foo] + +[foo]: /url "title" +. +[foo]
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8431 + +. +[foo*]: /url + +*[foo*] +. +*foo*
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8443 + +. +[foo][bar] + +[foo]: /url1 +[bar]: /url2 +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8452 + +. +[foo][] + +[foo]: /url1 +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8462 + +. +[foo]() + +[foo]: /url1 +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8470 + +. +[foo](not a link) + +[foo]: /url1 +. +foo(not a link)
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8481 + +. +[foo][bar][baz] + +[baz]: /url +. +[foo]bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8493 + +. +[foo][bar][baz] + +[baz]: /url1 +[bar]: /url2 +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8506 + +. +[foo][bar][baz] + +[baz]: /url1 +[foo]: /url2 +. +[foo]bar
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8529 + +. +![foo](/url "title") +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8536 + +. +![foo *bar*] + +[foo *bar*]: train.jpg "train & tracks" +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8545 + +. +![foo ![bar](/url)](/url2) +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8552 + +. +![foo [bar](/url)](/url2) +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8566 + +. +![foo *bar*][] + +[foo *bar*]: train.jpg "train & tracks" +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8575 + +. +![foo *bar*][foobar] + +[FOOBAR]: train.jpg "train & tracks" +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8584 + +. +![foo](train.jpg) +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8591 + +. +My ![foo bar](/path/to/train.jpg "title" ) +. +My
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8598 + +. +![foo](+[]
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8679 + +. +![foo] + +[foo]: /url "title" +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8688 + +. +![*foo* bar] + +[*foo* bar]: /url "title" +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8699 + +. +![[foo]] + +[[foo]]: /url "title" +. +![[foo]]
+[[foo]]: /url "title"
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8711 + +. +![Foo] + +[foo]: /url "title" +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8723 + +. +!\[foo] + +[foo]: /url "title" +. +![foo]
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8735 + +. +\![foo] + +[foo]: /url "title" +. +!foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8768 + +. +http://foo.bar.baz/test?q=hello&id=22&boolean
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8782 + +. +<http://foo.bar/baz bim>
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8842 + +. +<foo+@bar.example.com>
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8889 + +. +<> +. +<>
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8896 + +. +< http://foo.bar > +. +< http://foo.bar >
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8903 + +. +<m:abc>
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8910 + +. +<foo.bar.baz>
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8917 + +. +http://example.com +. +http://example.com
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 8924 + +. +foo@bar.example.com +. +foo@bar.example.com
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9005 + +. +Foo
<33> <__>
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9063 + +. + +. +<a h*#ref="hi">
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9072 + +. + +. +</a href="foo">
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9123 + +. +foo +. +foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9132 + +. +foo +. +foo <!-- not a comment -- two hyphens -->
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9141 + +. +foo foo --> + +foo +. +foo <!--> foo -->
+foo <!-- foo--->
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9153 + +. +foo +. +foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9162 + +. +foo +. +foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9171 + +. +foo &<]]> +. +foo &<]]>
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9181 + +. +foo +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9190 + +. +foo +. + +. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9197 + +. + +. +<a href=""">
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9211 + +. +foo +baz +. +foo
+baz
foo
+baz
foo
+baz
foo
+bar
foo
+bar
foo
+bar
foo
+bar
code span
code\ span
foo\
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9333 + +. +foo +. +foo
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9340 + +. +### foo\ +. +foo +baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9374 + +. +foo + baz +. +foo +baz
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9394 + +. +hello $.;'there +. +hello $.;'there
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9401 + +. +Foo χρῆν +. +Foo χρῆν
+. + +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +src line: 9410 + +. +Multiple spaces +. +Multiple spaces
+. + diff --git a/tests/test_port/fixtures/fatal.md b/tests/test_port/fixtures/fatal.md new file mode 100644 index 0000000..7b2afcf --- /dev/null +++ b/tests/test_port/fixtures/fatal.md @@ -0,0 +1,41 @@ +Should not throw exception on invalid chars in URL (`*` not allowed in path) [malformed URI] +. +[foo](<%test>) +. + +. + + +Should not throw exception on broken utf-8 sequence in URL [malformed URI] +. +[foo](%C3) +. + +. + + +Should not throw exception on broken utf-16 surrogates sequence in URL [malformed URI] +. +[foo]() +. + +. + + +Should not hang comments regexp +. +foo +. +foo <!— xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx ->
+foo <!------------------------------------------------------------------->
+. + + +Should not hang cdata regexp +. +foo +. +foo <![CDATA[ xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx ]>
+. diff --git a/tests/test_port/fixtures/issue-fixes.md b/tests/test_port/fixtures/issue-fixes.md new file mode 100644 index 0000000..0c693b0 --- /dev/null +++ b/tests/test_port/fixtures/issue-fixes.md @@ -0,0 +1,38 @@ +#31 empty lines after certain lists raises exception: +. +> a + +- b + + +. +++a
+
++A Block Quote
+
++. + +#80 UnicodeError with codepoints larger than 0xFFFF +. +💬 +. +Another Block Quote
+
💬
+. diff --git a/tests/test_port/fixtures/linkify.md b/tests/test_port/fixtures/linkify.md new file mode 100644 index 0000000..9edb78f --- /dev/null +++ b/tests/test_port/fixtures/linkify.md @@ -0,0 +1,99 @@ +linkify +. +url http://www.youtube.com/watch?v=5Jt5GEr4AYg. +. +url http://www.youtube.com/watch?v=5Jt5GEr4AYg.
+. + + +don't touch text in links +. +[https://example.com](https://example.com) +. + +. + + +don't touch text in autolinks +. +before +github.com
+. + +after line +. +github.com +after +. +github.com +after
+. + +before after lines +. +before +github.com +after +. +before +github.com +after
+. + +before after lines with blank line +. +before + +github.com + +after +. +before
+ +after
+. \ No newline at end of file diff --git a/tests/test_port/fixtures/normalize.md b/tests/test_port/fixtures/normalize.md new file mode 100644 index 0000000..4a00508 --- /dev/null +++ b/tests/test_port/fixtures/normalize.md @@ -0,0 +1,39 @@ + +Encode link destination, decode text inside it: + +. +https://www.google.com/search?q=hello.%252Ehello
+. + + +Don't encode domains in unknown schemas: + +. +[](skype:γγγ) +. + +. + + +Square brackets are allowed +. +[foo](https://bar]baz.org) +. + +. diff --git a/tests/test_port/fixtures/proto.md b/tests/test_port/fixtures/proto.md new file mode 100644 index 0000000..87fdccf --- /dev/null +++ b/tests/test_port/fixtures/proto.md @@ -0,0 +1,16 @@ +. +[__proto__] + +[__proto__]: blah +. + +. + + +. +[hasOwnProperty] + +[hasOwnProperty]: blah +. + +. diff --git a/tests/test_port/fixtures/punycode.md b/tests/test_port/fixtures/punycode.md new file mode 100644 index 0000000..c726e82 --- /dev/null +++ b/tests/test_port/fixtures/punycode.md @@ -0,0 +1,77 @@ +Should decode punycode: + +. +test google.com foo
+. + +Should support IDN in autolinks: + +. +test http://xn--n3h.net/ foo +. +test http://☃.net/ foo
+. + +. +test http://☃.net/ foo +. +test http://☃.net/ foo
+. + +. +test //xn--n3h.net/ foo +. +test //☃.net/ foo
+. + +. +test xn--n3h.net foo +. +test ☃.net foo
+. + +. +test xn--n3h@xn--n3h.net foo +. +test xn--n3h@☃.net foo
+. diff --git a/tests/test_port/fixtures/smartquotes.md b/tests/test_port/fixtures/smartquotes.md new file mode 100644 index 0000000..70378b8 --- /dev/null +++ b/tests/test_port/fixtures/smartquotes.md @@ -0,0 +1,166 @@ +Should parse nested quotes: +. +"foo 'bar' baz" + +'foo 'bar' baz' +. +“foo ‘bar’ baz”
+‘foo ‘bar’ baz’
+. + + +Should not overlap quotes: +. +'foo "bar' baz" +. +‘foo "bar’ baz"
+. + + +Should match quotes on the same level: +. +"foo *bar* baz" +. +“foo bar baz”
+. + + +Should handle adjacent nested quotes: +. +'"double in single"' + +"'single in double'" +. +‘“double in single”’
+“‘single in double’”
+. + + + +Should not match quotes on different levels: +. +*"foo* bar" + +"foo *bar"* + +*"foo* bar *baz"* +. +"foo bar"
+"foo bar"
+"foo bar baz"
+. + +Smartquotes should not overlap with other tags: +. +*foo "bar* *baz" quux* +. +foo "bar baz" quux
+. + + +Should try and find matching quote in this case: +. +"foo "bar 'baz" +. +"foo “bar 'baz”
+. + + +Should not touch 'inches' in quotes: +. +"Monitor 21"" and "Monitor"" +. +“Monitor 21"” and “Monitor”"
+. + + +Should render an apostrophe as a rsquo: +. +This isn't and can't be the best approach to implement this... +. +This isn’t and can’t be the best approach to implement this…
+. + + +Apostrophe could end the word, that's why original smartypants replaces all of them as rsquo: +. +users' stuff +. +users’ stuff
+. + +Quotes between punctuation chars: + +. +"(hai)". +. +“(hai)”.
+. + +Quotes at the start/end of the tokens: +. +"*foo* bar" + +"foo *bar*" + +"*foo bar*" +. +“foo bar”
+“foo bar”
+“foo bar”
+. + +Should treat softbreak as a space: +. +"this" +and "that". + +"this" and +"that". +. +“this” +and “that”.
+“this” and +“that”.
+. + +Should treat hardbreak as a space: +. +"this"\ +and "that". + +"this" and\ +"that". +. +“this”
+and “that”.
“this” and
+“that”.
The dog—“‘man’s’ best friend”
+. + +Should parse quotes adjacent to code block, #677: +. +"test `code`" + +"`code` test" +. +“test code
”
“code
test”
“test
”
“
test”
Strikeout
x foo bar
x foo bar
x foo
x a ~~~foobar b
x a ~~~~foobar b
~~test~~
+**test**
~~link~~
+~~link~~
+. + + +Strikeouts have the same priority as emphases with respect to backticks: +. +~~`code~~` + +`~~code`~~ +. +~~code~~
~~code
~~
foo bar baz
f o o b a r
foo ~~ bar ~~ baz
+. + + +Should parse strikethrough within link tags: +. +[~~foo~~]() +. + +. + + +Newline should be considered a whitespace: +. +~~test +~~ + +~~ +test~~ + +~~ +test +~~ +. +~~test +~~
+~~ +test~~
+~~ +test +~~
+. + +From CommonMark test suite, replacing `**` with our marker: + +. +a~~"foo"~~ +. +a~~"foo"~~
+. + +Coverage: single tilde +. +~a~ +. +~a~
+. + +Regression test for #742: +. +-~~~~;~~~~~~ +. +-~~;
Heading 1 | +Heading 2 | +
---|---|
Cell 1 | +Cell 2 | +
Cell 3 | +Cell 4 | +
Header 1 | +Header 2 | +Header 3 | +Header 4 | +
---|---|---|---|
Cell 1 | +Cell 2 | +Cell 3 | +Cell 4 | +
Cell 5 | +Cell 6 | +Cell 7 | +Cell 8 | +
Header 1 | +Header 2 | +Header 3 | +Header 4 | +
---|---|---|---|
Cell 1 | +Cell 2 | +Cell 3 | +Cell 4 | +
Cell 5 | +Cell 6 | +Cell 7 | +Cell 8 | +
+++ +
++ + + +foo +foo ++ + +bar +bar +
baz|baz
+. + + +Minimal one-column: +. +| foo +|---- +| test2 +. +foo | +
---|
test2 | +
- foo | +foo | +
---|---|
bar | +bar | +
foo|foo +-----|-----s +bar|bar
+. + + +Second line should contain "|" symbol: +. +foo|foo +-----:----- +bar|bar +. +foo|foo +-----:----- +bar|bar
+. + + +Second line should not have empty columns in the middle: +. +foo|foo +-----||----- +bar|bar +. +foo|foo +-----||----- +bar|bar
+. + + +Wrong alignment symbol position: +. +foo|foo +-----|-::- +bar|bar +. +foo|foo +-----|-::- +bar|bar
+. + + +Title line should contain "|" symbol: +. +foo +-----|----- +bar|bar +. +foo +-----|----- +bar|bar
+. + + +Allow tabs as a separator on 2nd line +. +| foo | bar | +| --- | --- | +| baz | quux | +. +foo | +bar | +
---|---|
baz | +quux | +
paragraph
+foo | +foo | +
---|---|
bar | +bar | +
foo | +foo | +
---|---|
paragraph | ++ |
| Heading 1 \\| Heading 2 +| --------- | --------- +| Cell|1|| Cell|2 +| Cell\|3 \| Cell|4
+. + +Pipes inside backticks DO split cells, unless `\` escaped: +. +| Heading 1 | Heading 2 +| --------- | --------- +| `Cell\|1` | Cell 2 +| `Cell|3` | Cell 4 +. +Heading 1 | +Heading 2 | +
---|---|
Cell|1 |
+Cell 2 | +
`Cell | +3` | +
Heading 1 | +Heading 2 | +
---|---|
Cell 1 | +Cell 2 | +
`Cell 3 | +Cell 4 | +
Heading 1 | +Heading 2 | +
---|---|
Cell 1 | +Cell 2 | +
\` | +\` | +
# | +1 | +2 | +
---|---|---|
x | +\ |
+x |
+
# | +1 | +2 | +
---|---|---|
x | +`` | +x |
+
1 | +2 | +
---|---|
3 | +4 | +
1 | +2 | +3 | +4 | +
---|---|---|---|
5 | +6 | ++ | + |
foo | +
---|
bar | +
Col1a | +Col2a | +
---|---|
Col1b | +Col2b | +
| Col1a | Col2a |
+
+| ----- | ----- | +| Col1b | Col2b |
+. + + +Tables should not be indented more than 4 spaces (2nd line): +. + | Col1a | Col2a | + | ----- | ----- | + | Col1b | Col2b | +. +| Col1a | Col2a | +| ----- | ----- | +| Col1b | Col2b |
+. + + +Tables should not be indented more than 4 spaces (3rd line): +. + | Col1a | Col2a | + | ----- | ----- | + | Col1b | Col2b | +. +Col1a | +Col2a | +
---|
| Col1b | Col2b |
+
+.
+
+
+Allow tables with empty body:
+.
+ | Col1a | Col2a |
+ | ----- | ----- |
+.
+Col1a | +Col2a | +
---|
Col1a | Col1b | Col1c +----- | ----- +Col2a | Col2b | Col2c
+. + +Escaped pipes inside backticks don't split cells: +. +| Heading 1 | Heading 2 +| --------- | --------- +| Cell 1 | Cell 2 +| `Cell 3\|` | Cell 4 +. +Heading 1 | +Heading 2 | +
---|---|
Cell 1 | +Cell 2 | +
Cell 3| |
+Cell 4 | +
Heading 1 | +Heading 2 | +
---|---|
Cell 1 | +Cell 2 | +
Cell 3\| |
+Cell 4 | +
Level 1
+Level 2
+Column 1 | +Column 2 | +
---|---|
abcdefgh | +ijklmnop | +
| +| +|
+. + +GFM 4.10 Tables (extension), Example 198 +. +| foo | bar | +| --- | --- | +| baz | bim | +. +foo | +bar | +
---|---|
baz | +bim | +
abc | +defghi | +
---|---|
bar | +baz | +
f|oo | +
---|
b | az |
+
b | im | +
abc | +def | +
---|---|
bar | +baz | +
++. + +GFM 4.10 Tables (extension), Example 202 +. +| abc | def | +| --- | --- | +| bar | baz | +bar + +bar +. +bar
+
abc | +def | +
---|---|
bar | +baz | +
bar | ++ |
bar
+. + +GFM 4.10 Tables (extension), Example 203 +. +| abc | def | +| --- | +| bar | +. +| abc | def | +| --- | +| bar |
+. + +GFM 4.10 Tables (extension), Example 204 +. +| abc | def | +| --- | --- | +| bar | +| bar | baz | boo | +. +abc | +def | +
---|---|
bar | ++ |
bar | +baz | +
abc | +def | +
---|
a | b
+(bad)
+. + +copyright (Lower) +. +(c) +. +©
+. + +copyright (Upper) +. +(C) +. +©
+. + +copyright +. +(c) (C) +. +© ©
+. + + +reserved +. +(r) (R) +. +® ®
+. + + +trademark +. +(tm) (TM) +. +™ ™
+. + + +paragraph +. +(p) (P) +. +§ §
+. + + +plus-minus +. ++-5 +. +±5
+. + + +ellipsis +. +test.. test... test..... test?..... test!.... +. +test… test… test… test?.. test!..
+. + + +dupes +. +!!!!!! ???? ,, +. +!!! ??? ,
+. + + +dupes-ellipsis +. +!... ?... ,... !!!!!!.... ????.... ,,... +. +!.. ?.. ,… !!!.. ???.. ,…
+. + + +dashes +. +---markdownit --- super--- + +markdownit---awesome + +abc ---- + +--markdownit -- super-- + +markdownit--awesome +. +—markdownit — super—
+markdownit—awesome
+abc ----
+–markdownit – super–
+markdownit–awesome
+. + +regression tests for #624 +. +1---2---3 + +1--2--3 + +1 -- -- 3 +. +1—2—3
+1–2–3
+1 – – 3
+. diff --git a/tests/test_port/fixtures/xss.md b/tests/test_port/fixtures/xss.md new file mode 100644 index 0000000..7c0512e --- /dev/null +++ b/tests/test_port/fixtures/xss.md @@ -0,0 +1,128 @@ +. +[normal link](javascript) +. + +. + + +Should not allow some protocols in links and images +. +[xss link](javascript:alert(1)) + +[xss link](JAVASCRIPT:alert(1)) + +[xss link](vbscript:alert(1)) + +[xss link](VBSCRIPT:alert(1)) + +[xss link](file:///123) +. +[xss link](javascript:alert(1))
+[xss link](JAVASCRIPT:alert(1))
+[xss link](vbscript:alert(1))
+[xss link](VBSCRIPT:alert(1))
+[xss link](file:///123)
+. + + +. +[xss link]("><script>alert("xss")</script>) + +[xss link](Javascript:alert(1)) + +[xss link](Javascript:alert(1)) + +[xss link](\Javascript:alert(1)) +. + +[xss link](Javascript:alert(1))
+ + +. + +. +[xss link]([xss link](<javascript:alert(1)>)
+. + +. +[xss link](javascript:alert(1)) +. +[xss link](javascript:alert(1))
+. + + +Should not allow data-uri except some whitelisted mimes +. +![](data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7) +. + +. + +. +[xss link](data:text/html;base64,PHNjcmlwdD5hbGVydCgnWFNTJyk8L3NjcmlwdD4K) +. +[xss link](data:text/html;base64,PHNjcmlwdD5hbGVydCgnWFNTJyk8L3NjcmlwdD4K)
+. + +. +[normal link](/javascript:link) +. + +. + + +Image parser use the same code base as link. +. +![xss link](javascript:alert(1)) +. +![xss link](javascript:alert(1))
+. + + +Autolinks +. +<javascript:alert(1)>
+<javascript:alert(1)>
+. + + +Linkifier +. +javascript:alert(1) + +javascript:alert(1) +. +javascript:alert(1)
+javascript:alert(1)
+. + + +References +. +[test]: javascript:alert(1) +. +[test]: javascript:alert(1)
+. + + +Make sure we decode entities before split: +. +```js custom-class +test1 +``` + +```jscustom-class +test2 +``` +. +test1
+
+test2
+
+.
diff --git a/tests/test_port/test_fixtures.py b/tests/test_port/test_fixtures.py
new file mode 100644
index 0000000..5117c5e
--- /dev/null
+++ b/tests/test_port/test_fixtures.py
@@ -0,0 +1,114 @@
+from pathlib import Path
+
+import pytest
+
+from markdown_it import MarkdownIt
+from markdown_it.utils import read_fixture_file
+
+FIXTURE_PATH = Path(__file__).parent.joinpath("fixtures")
+
+
+@pytest.mark.parametrize(
+ "line,title,input,expected",
+ read_fixture_file(FIXTURE_PATH.joinpath("linkify.md")),
+)
+def test_linkify(line, title, input, expected):
+ md = MarkdownIt().enable("linkify")
+ md.options["linkify"] = True
+ text = md.render(input)
+ assert text.rstrip() == expected.rstrip()
+
+ # if not install linkify-it-py
+ md.linkify = None
+ with pytest.raises(ModuleNotFoundError):
+ md.render(input)
+
+
+@pytest.mark.parametrize(
+ "line,title,input,expected",
+ read_fixture_file(FIXTURE_PATH.joinpath("smartquotes.md")),
+)
+def test_smartquotes(line, title, input, expected):
+ md = MarkdownIt().enable("replacements").enable("smartquotes")
+ md.options["typographer"] = True
+ text = md.render(input)
+ assert text.rstrip() == expected.rstrip()
+
+
+@pytest.mark.parametrize(
+ "line,title,input,expected",
+ read_fixture_file(FIXTURE_PATH.joinpath("typographer.md")),
+)
+def test_typographer(line, title, input, expected):
+ md = MarkdownIt().enable("replacements")
+ md.options["typographer"] = True
+ text = md.render(input)
+ assert text.rstrip() == expected.rstrip()
+
+
+@pytest.mark.parametrize(
+ "line,title,input,expected", read_fixture_file(FIXTURE_PATH.joinpath("tables.md"))
+)
+def test_table(line, title, input, expected):
+ md = MarkdownIt().enable("table")
+ text = md.render(input)
+ try:
+ assert text.rstrip() == expected.rstrip()
+ except AssertionError:
+ print(text)
+ raise
+
+
+@pytest.mark.parametrize(
+ "line,title,input,expected",
+ read_fixture_file(FIXTURE_PATH.joinpath("commonmark_extras.md")),
+)
+def test_commonmark_extras(line, title, input, expected):
+ md = MarkdownIt("commonmark")
+ md.options["langPrefix"] = ""
+ text = md.render(input)
+ if text.rstrip() != expected.rstrip():
+ print(text)
+ assert text.rstrip() == expected.rstrip()
+
+
+@pytest.mark.parametrize(
+ "line,title,input,expected",
+ read_fixture_file(FIXTURE_PATH.joinpath("normalize.md")),
+)
+def test_normalize_url(line, title, input, expected):
+ md = MarkdownIt("commonmark")
+ text = md.render(input)
+ assert text.rstrip() == expected.rstrip()
+
+
+@pytest.mark.parametrize(
+ "line,title,input,expected", read_fixture_file(FIXTURE_PATH.joinpath("fatal.md"))
+)
+def test_fatal(line, title, input, expected):
+ md = MarkdownIt("commonmark").enable("replacements")
+ md.options["typographer"] = True
+ text = md.render(input)
+ if text.rstrip() != expected.rstrip():
+ print(text)
+ assert text.rstrip() == expected.rstrip()
+
+
+@pytest.mark.parametrize(
+ "line,title,input,expected",
+ read_fixture_file(FIXTURE_PATH.joinpath("strikethrough.md")),
+)
+def test_strikethrough(line, title, input, expected):
+ md = MarkdownIt().enable("strikethrough")
+ text = md.render(input)
+ assert text.rstrip() == expected.rstrip()
+
+
+@pytest.mark.parametrize(
+ "line,title,input,expected",
+ read_fixture_file(FIXTURE_PATH.joinpath("issue-fixes.md")),
+)
+def test_issue_fixes(line, title, input, expected):
+ md = MarkdownIt()
+ text = md.render(input)
+ assert text.rstrip() == expected.rstrip()
diff --git a/tests/test_port/test_misc.py b/tests/test_port/test_misc.py
new file mode 100644
index 0000000..62b5bf8
--- /dev/null
+++ b/tests/test_port/test_misc.py
@@ -0,0 +1,44 @@
+from markdown_it import MarkdownIt, presets
+
+
+def test_highlight_arguments():
+ def highlight_func(str_, lang, attrs):
+ assert lang == "a"
+ assert attrs == "b c d"
+ return "==" + str_ + "==
"
+
+ conf = presets.commonmark.make()
+ conf["options"]["highlight"] = highlight_func
+ md = MarkdownIt(config=conf)
+ assert md.render("``` a b c d \nhl\n```") == "==hl\n==
\n"
+
+
+def test_ordered_list_info():
+ def type_filter(tokens, type_):
+ return [t for t in tokens if t.type == type_]
+
+ md = MarkdownIt()
+
+ tokens = md.parse("1. Foo\n2. Bar\n20. Fuzz")
+ assert len(type_filter(tokens, "ordered_list_open")) == 1
+ tokens = type_filter(tokens, "list_item_open")
+ assert len(tokens) == 3
+ assert tokens[0].info == "1"
+ assert tokens[0].markup == "."
+ assert tokens[1].info == "2"
+ assert tokens[1].markup == "."
+ assert tokens[2].info == "20"
+ assert tokens[2].markup == "."
+
+ tokens = md.parse(" 1. Foo\n2. Bar\n 20. Fuzz\n 199. Flp")
+ assert len(type_filter(tokens, "ordered_list_open")) == 1
+ tokens = type_filter(tokens, "list_item_open")
+ assert len(tokens) == 4
+ assert tokens[0].info == "1"
+ assert tokens[0].markup == "."
+ assert tokens[1].info == "2"
+ assert tokens[1].markup == "."
+ assert tokens[2].info == "20"
+ assert tokens[2].markup == "."
+ assert tokens[3].info == "199"
+ assert tokens[3].markup == "."
diff --git a/tests/test_port/test_no_end_newline.py b/tests/test_port/test_no_end_newline.py
new file mode 100644
index 0000000..5e7cf82
--- /dev/null
+++ b/tests/test_port/test_no_end_newline.py
@@ -0,0 +1,27 @@
+import pytest
+
+from markdown_it import MarkdownIt
+
+
+@pytest.mark.parametrize(
+ "input,expected",
+ [
+ ("#", "\n"),
+ ("###", "\n"),
+ ("` `", "
\n"),
+ ("-", "p
\n"), + ("[reference]: /url", ""), + (" indented code block", "indented code block\n
\n"),
+ ("> test\n>", "\n\n"), + ], +) +def test_no_end_newline(input, expected): + md = MarkdownIt() + text = md.render(input) + assert text == expected diff --git a/tests/test_port/test_references.py b/tests/test_port/test_references.py new file mode 100644 index 0000000..32e389d --- /dev/null +++ b/tests/test_port/test_references.py @@ -0,0 +1,53 @@ +from markdown_it import MarkdownIt + + +def test_ref_definitions(): + + md = MarkdownIt() + src = "[a]: abc\n\n[b]: xyz\n\n[b]: ijk" + env = {} + tokens = md.parse(src, env) + assert tokens == [] + assert env == { + "references": { + "A": {"title": "", "href": "abc", "map": [0, 1]}, + "B": {"title": "", "href": "xyz", "map": [2, 3]}, + }, + "duplicate_refs": [{"href": "ijk", "label": "B", "map": [4, 5], "title": ""}], + } + + +def test_use_existing_env(data_regression): + md = MarkdownIt() + src = "[a]\n\n[c]: ijk" + env = { + "references": { + "A": {"title": "", "href": "abc", "map": [0, 1]}, + "B": {"title": "", "href": "xyz", "map": [2, 3]}, + } + } + tokens = md.parse(src, env) + data_regression.check([token.as_dict() for token in tokens]) + assert env == { + "references": { + "A": {"title": "", "href": "abc", "map": [0, 1]}, + "B": {"title": "", "href": "xyz", "map": [2, 3]}, + "C": {"title": "", "href": "ijk", "map": [2, 3]}, + } + } + + +def test_store_labels(data_regression): + md = MarkdownIt() + md.options["store_labels"] = True + src = "[a]\n\n![a]\n\n[a]: ijk" + tokens = md.parse(src) + data_regression.check([token.as_dict() for token in tokens]) + + +def test_inline_definitions(data_regression): + md = MarkdownIt() + md.options["inline_definitions"] = True + src = '[a]: url "title"\n- [a]: url "title"' + tokens = md.parse(src) + data_regression.check([token.as_dict() for token in tokens]) diff --git a/tests/test_port/test_references/test_inline_definitions.yml b/tests/test_port/test_references/test_inline_definitions.yml new file mode 100644 index 0000000..5ec210b --- /dev/null +++ b/tests/test_port/test_references/test_inline_definitions.yml @@ -0,0 +1,94 @@ +- attrs: null + block: true + children: null + content: '' + hidden: false + info: '' + level: 0 + map: + - 0 + - 1 + markup: '' + meta: + id: A + label: a + title: title + url: url + nesting: 0 + tag: '' + type: definition +- attrs: null + block: true + children: null + content: '' + hidden: false + info: '' + level: 0 + map: + - 1 + - 2 + markup: '-' + meta: {} + nesting: 1 + tag: ul + type: bullet_list_open +- attrs: null + block: true + children: null + content: '' + hidden: false + info: '' + level: 1 + map: + - 1 + - 2 + markup: '-' + meta: {} + nesting: 1 + tag: li + type: list_item_open +- attrs: null + block: true + children: null + content: '' + hidden: false + info: '' + level: 2 + map: + - 1 + - 2 + markup: '' + meta: + id: A + label: a + title: title + url: url + nesting: 0 + tag: '' + type: definition +- attrs: null + block: true + children: null + content: '' + hidden: false + info: '' + level: 1 + map: null + markup: '-' + meta: {} + nesting: -1 + tag: li + type: list_item_close +- attrs: null + block: true + children: null + content: '' + hidden: false + info: '' + level: 0 + map: null + markup: '-' + meta: {} + nesting: -1 + tag: ul + type: bullet_list_close diff --git a/tests/test_port/test_references/test_store_labels.yml b/tests/test_port/test_references/test_store_labels.yml new file mode 100644 index 0000000..79f6f74 --- /dev/null +++ b/tests/test_port/test_references/test_store_labels.yml @@ -0,0 +1,159 @@ +- attrs: null + block: true + children: null + content: '' + hidden: false + info: '' + level: 0 + map: + - 0 + - 1 + markup: '' + meta: {} + nesting: 1 + tag: p + type: paragraph_open +- attrs: null + block: true + children: + - attrs: + - - href + - ijk + block: false + children: null + content: '' + hidden: false + info: '' + level: 0 + map: null + markup: '' + meta: + label: A + nesting: 1 + tag: a + type: link_open + - attrs: null + block: false + children: null + content: a + hidden: false + info: '' + level: 1 + map: null + markup: '' + meta: {} + nesting: 0 + tag: '' + type: text + - attrs: null + block: false + children: null + content: '' + hidden: false + info: '' + level: 0 + map: null + markup: '' + meta: {} + nesting: -1 + tag: a + type: link_close + content: '[a]' + hidden: false + info: '' + level: 1 + map: + - 0 + - 1 + markup: '' + meta: {} + nesting: 0 + tag: '' + type: inline +- attrs: null + block: true + children: null + content: '' + hidden: false + info: '' + level: 0 + map: null + markup: '' + meta: {} + nesting: -1 + tag: p + type: paragraph_close +- attrs: null + block: true + children: null + content: '' + hidden: false + info: '' + level: 0 + map: + - 2 + - 3 + markup: '' + meta: {} + nesting: 1 + tag: p + type: paragraph_open +- attrs: null + block: true + children: + - attrs: + - - src + - ijk + - - alt + - '' + block: false + children: + - attrs: null + block: false + children: null + content: a + hidden: false + info: '' + level: 0 + map: null + markup: '' + meta: {} + nesting: 0 + tag: '' + type: text + content: a + hidden: false + info: '' + level: 0 + map: null + markup: '' + meta: + label: A + nesting: 0 + tag: img + type: image + content: '![a]' + hidden: false + info: '' + level: 1 + map: + - 2 + - 3 + markup: '' + meta: {} + nesting: 0 + tag: '' + type: inline +- attrs: null + block: true + children: null + content: '' + hidden: false + info: '' + level: 0 + map: null + markup: '' + meta: {} + nesting: -1 + tag: p + type: paragraph_close diff --git a/tests/test_port/test_references/test_use_existing_env.yml b/tests/test_port/test_references/test_use_existing_env.yml new file mode 100644 index 0000000..1a72337 --- /dev/null +++ b/tests/test_port/test_references/test_use_existing_env.yml @@ -0,0 +1,84 @@ +- attrs: null + block: true + children: null + content: '' + hidden: false + info: '' + level: 0 + map: + - 0 + - 1 + markup: '' + meta: {} + nesting: 1 + tag: p + type: paragraph_open +- attrs: null + block: true + children: + - attrs: + - - href + - abc + block: false + children: null + content: '' + hidden: false + info: '' + level: 0 + map: null + markup: '' + meta: {} + nesting: 1 + tag: a + type: link_open + - attrs: null + block: false + children: null + content: a + hidden: false + info: '' + level: 1 + map: null + markup: '' + meta: {} + nesting: 0 + tag: '' + type: text + - attrs: null + block: false + children: null + content: '' + hidden: false + info: '' + level: 0 + map: null + markup: '' + meta: {} + nesting: -1 + tag: a + type: link_close + content: '[a]' + hidden: false + info: '' + level: 1 + map: + - 0 + - 1 + markup: '' + meta: {} + nesting: 0 + tag: '' + type: inline +- attrs: null + block: true + children: null + content: '' + hidden: false + info: '' + level: 0 + map: null + markup: '' + meta: {} + nesting: -1 + tag: p + type: paragraph_close -- cgit v1.2.3test
\n