summaryrefslogtreecommitdiff
path: root/t/docs-php-markdown
diff options
context:
space:
mode:
Diffstat (limited to 't/docs-php-markdown')
-rw-r--r--t/docs-php-markdown/Backslash_escapes.html9
-rw-r--r--t/docs-php-markdown/Backslash_escapes.text1
-rw-r--r--t/docs-php-markdown/Code_Spans.html6
-rw-r--r--t/docs-php-markdown/Code_Spans.text6
-rw-r--r--t/docs-php-markdown/Code_block_in_a_list_item.html11
-rw-r--r--t/docs-php-markdown/Code_block_in_a_list_item.text8
-rw-r--r--t/docs-php-markdown/Headers.html39
-rw-r--r--t/docs-php-markdown/Headers.text9
-rw-r--r--t/docs-php-markdown/Images_(Untitled).html5
-rw-r--r--t/docs-php-markdown/Images_(Untitled).text7
-rw-r--r--t/docs-php-markdown/Inline_HTML_(Simple).html15
-rw-r--r--t/docs-php-markdown/Inline_HTML_(Simple).text15
-rw-r--r--t/docs-php-markdown/Inline_HTML_comments.html9
-rw-r--r--t/docs-php-markdown/Inline_HTML_comments.text9
-rw-r--r--t/docs-php-markdown/PHP-Specific_Bugs.html17
-rw-r--r--t/docs-php-markdown/PHP-Specific_Bugs.text22
-rw-r--r--t/docs-php-markdown/Tight_blocks.html21
-rw-r--r--t/docs-php-markdown/Tight_blocks.text1
18 files changed, 210 insertions, 0 deletions
diff --git a/t/docs-php-markdown/Backslash_escapes.html b/t/docs-php-markdown/Backslash_escapes.html
new file mode 100644
index 0000000..c5dbcfc
--- /dev/null
+++ b/t/docs-php-markdown/Backslash_escapes.html
@@ -0,0 +1,9 @@
+<p>Tricky combinaisons:</p>
+
+<p>backslash with \-- two dashes</p>
+
+<p>backslash with \> greater than</p>
+
+<p>\[test](not a link)</p>
+
+<p>\*no emphasis*</p>
diff --git a/t/docs-php-markdown/Backslash_escapes.text b/t/docs-php-markdown/Backslash_escapes.text
new file mode 100644
index 0000000..a5e769b
--- /dev/null
+++ b/t/docs-php-markdown/Backslash_escapes.text
@@ -0,0 +1 @@
+Tricky combinaisons: backslash with \\-- two dashes backslash with \\> greater than \\\[test](not a link) \\\*no emphasis* \ No newline at end of file
diff --git a/t/docs-php-markdown/Code_Spans.html b/t/docs-php-markdown/Code_Spans.html
new file mode 100644
index 0000000..9ed0df8
--- /dev/null
+++ b/t/docs-php-markdown/Code_Spans.html
@@ -0,0 +1,6 @@
+<p>From <code>&lt;!--</code> to <code>--&gt;</code>
+on two lines.</p>
+
+<p>From <code>&lt;!--</code>
+to <code>--&gt;</code>
+on three lines.</p>
diff --git a/t/docs-php-markdown/Code_Spans.text b/t/docs-php-markdown/Code_Spans.text
new file mode 100644
index 0000000..43f2bcf
--- /dev/null
+++ b/t/docs-php-markdown/Code_Spans.text
@@ -0,0 +1,6 @@
+From `<!--` to `-->`
+on two lines.
+
+From `<!--`
+to `-->`
+on three lines.
diff --git a/t/docs-php-markdown/Code_block_in_a_list_item.html b/t/docs-php-markdown/Code_block_in_a_list_item.html
new file mode 100644
index 0000000..8ac5d83
--- /dev/null
+++ b/t/docs-php-markdown/Code_block_in_a_list_item.html
@@ -0,0 +1,11 @@
+<ul>
+<li><p>List Item:</p>
+
+<pre><code>code block
+
+
+with a blank line
+</code></pre>
+
+<p>within a list item.</p></li>
+</ul> \ No newline at end of file
diff --git a/t/docs-php-markdown/Code_block_in_a_list_item.text b/t/docs-php-markdown/Code_block_in_a_list_item.text
new file mode 100644
index 0000000..3fa24c3
--- /dev/null
+++ b/t/docs-php-markdown/Code_block_in_a_list_item.text
@@ -0,0 +1,8 @@
+
+* List Item:
+
+ code block
+
+ with a blank line
+
+ within a list item. \ No newline at end of file
diff --git a/t/docs-php-markdown/Headers.html b/t/docs-php-markdown/Headers.html
new file mode 100644
index 0000000..3adb470
--- /dev/null
+++ b/t/docs-php-markdown/Headers.html
@@ -0,0 +1,39 @@
+<h1>Header</h1>
+
+<h2>Header</h2>
+
+<h3>Header</h3>
+
+<hr />
+
+<h1>Header</h1>
+
+<p>Paragraph</p>
+
+<h2>Header</h2>
+
+<p>Paragraph</p>
+
+<h3>Header</h3>
+
+<p>Paragraph</p>
+
+<hr />
+
+<p>Paragraph</p>
+
+<h1>Header</h1>
+
+<p>Paragraph</p>
+
+<p>Paragraph</p>
+
+<h2>Header</h2>
+
+<p>Paragraph</p>
+
+<p>Paragraph</p>
+
+<h3>Header</h3>
+
+<p>Paragraph</p>
diff --git a/t/docs-php-markdown/Headers.text b/t/docs-php-markdown/Headers.text
new file mode 100644
index 0000000..3a39174
--- /dev/null
+++ b/t/docs-php-markdown/Headers.text
@@ -0,0 +1,9 @@
+Header ====== Header ------ ### Header
+
+ - - -
+
+Header ====== Paragraph Header ------ Paragraph ### Header Paragraph
+
+ - - -
+
+Paragraph Header ====== Paragraph Paragraph Header ------ Paragraph Paragraph ### Header Paragraph \ No newline at end of file
diff --git a/t/docs-php-markdown/Images_(Untitled).html b/t/docs-php-markdown/Images_(Untitled).html
new file mode 100644
index 0000000..1b9bc04
--- /dev/null
+++ b/t/docs-php-markdown/Images_(Untitled).html
@@ -0,0 +1,5 @@
+<p><img src="/url/" alt="alt text" /></p>
+
+<p><img src="/url/" alt="alt text" /></p>
+
+<p><img src="/url/" alt="alt text" /></p>
diff --git a/t/docs-php-markdown/Images_(Untitled).text b/t/docs-php-markdown/Images_(Untitled).text
new file mode 100644
index 0000000..cb481de
--- /dev/null
+++ b/t/docs-php-markdown/Images_(Untitled).text
@@ -0,0 +1,7 @@
+![alt text](/url/)
+
+![alt text](</url/>)
+
+![alt text][foo]
+
+ [foo]: /url/ \ No newline at end of file
diff --git a/t/docs-php-markdown/Inline_HTML_(Simple).html b/t/docs-php-markdown/Inline_HTML_(Simple).html
new file mode 100644
index 0000000..facfefb
--- /dev/null
+++ b/t/docs-php-markdown/Inline_HTML_(Simple).html
@@ -0,0 +1,15 @@
+<p>With some attributes:</p>
+
+<div id="test">
+ foo
+</div>
+
+<div id="test"
+ class="nono">
+ foo
+</div>
+
+<p>Hr's:</p>
+
+<hr class="foo"
+ id="bar" > \ No newline at end of file
diff --git a/t/docs-php-markdown/Inline_HTML_(Simple).text b/t/docs-php-markdown/Inline_HTML_(Simple).text
new file mode 100644
index 0000000..9177105
--- /dev/null
+++ b/t/docs-php-markdown/Inline_HTML_(Simple).text
@@ -0,0 +1,15 @@
+With some attributes:
+
+<div id="test">
+ foo
+</div>
+
+<div id="test"
+ class="nono">
+ foo
+</div>
+
+Hr's:
+
+<hr class="foo"
+ id="bar" >
diff --git a/t/docs-php-markdown/Inline_HTML_comments.html b/t/docs-php-markdown/Inline_HTML_comments.html
new file mode 100644
index 0000000..b45f014
--- /dev/null
+++ b/t/docs-php-markdown/Inline_HTML_comments.html
@@ -0,0 +1,9 @@
+<p>Paragraph one.</p>
+
+<!-- double--dash (invalid SGML comment) -->
+
+<p>Paragraph two.</p>
+
+<!-- enclosed tag </div> -->
+
+<p>The end.</p>
diff --git a/t/docs-php-markdown/Inline_HTML_comments.text b/t/docs-php-markdown/Inline_HTML_comments.text
new file mode 100644
index 0000000..d57d00a
--- /dev/null
+++ b/t/docs-php-markdown/Inline_HTML_comments.text
@@ -0,0 +1,9 @@
+Paragraph one.
+
+<!-- double--dash (invalid SGML comment) -->
+
+Paragraph two.
+
+<!-- enclosed tag </div> -->
+
+The end.
diff --git a/t/docs-php-markdown/PHP-Specific_Bugs.html b/t/docs-php-markdown/PHP-Specific_Bugs.html
new file mode 100644
index 0000000..c982417
--- /dev/null
+++ b/t/docs-php-markdown/PHP-Specific_Bugs.html
@@ -0,0 +1,17 @@
+<p>This tests for a bug where quotes escaped by PHP when using
+<code>preg_replace</code> with the <code>/e</code> modifier must be correctly unescaped
+(hence the <code>_UnslashQuotes</code> function found only in PHP Markdown).</p>
+
+<p>Headers below should appear exactly as they are typed (no backslash
+added or removed).</p>
+
+<h1>Header "quoted\" again \""</h1>
+
+<h2>Header "quoted\" again \""</h2>
+
+<h3>Header "quoted\" again \""</h3>
+
+<p>Test with tabs for <code>_Detab</code>:</p>
+
+<pre><code>Code 'block' with some "tabs" and "quotes"
+</code></pre>
diff --git a/t/docs-php-markdown/PHP-Specific_Bugs.text b/t/docs-php-markdown/PHP-Specific_Bugs.text
new file mode 100644
index 0000000..246b60d
--- /dev/null
+++ b/t/docs-php-markdown/PHP-Specific_Bugs.text
@@ -0,0 +1,22 @@
+This tests for a bug where quotes escaped by PHP when using
+`preg_replace` with the `/e` modifier must be correctly unescaped
+(hence the `_UnslashQuotes` function found only in PHP Markdown).
+
+
+
+Headers below should appear exactly as they are typed (no backslash
+added or removed).
+
+Header "quoted\" again \\""
+===========================
+
+Header "quoted\" again \\""
+---------------------------
+
+### Header "quoted\" again \\"" ###
+
+
+
+Test with tabs for `_Detab`:
+
+ Code 'block' with some "tabs" and "quotes"
diff --git a/t/docs-php-markdown/Tight_blocks.html b/t/docs-php-markdown/Tight_blocks.html
new file mode 100644
index 0000000..8655430
--- /dev/null
+++ b/t/docs-php-markdown/Tight_blocks.html
@@ -0,0 +1,21 @@
+<p>Paragraph and no space:
+* ciao</p>
+
+<p>Paragraph and 1 space:
+ * ciao</p>
+
+<p>Paragraph and 3 spaces:
+ * ciao</p>
+
+<p>Paragraph and 4 spaces:
+ * ciao</p>
+
+<p>Paragraph before header:</p>
+
+<h1>Header</h1>
+
+<p>Paragraph before blockquote:</p>
+
+<blockquote>
+ <p>Some quote.</p>
+</blockquote>
diff --git a/t/docs-php-markdown/Tight_blocks.text b/t/docs-php-markdown/Tight_blocks.text
new file mode 100644
index 0000000..ae4cdcb
--- /dev/null
+++ b/t/docs-php-markdown/Tight_blocks.text
@@ -0,0 +1 @@
+Paragraph and no space: * ciao Paragraph and 1 space: * ciao Paragraph and 3 spaces: * ciao Paragraph and 4 spaces: * ciao Paragraph before header: #Header Paragraph before blockquote: >Some quote. \ No newline at end of file