diff --git a/Gruntfile.js b/Gruntfile.js index 4c093a4..3eab436 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -95,6 +95,15 @@ module.exports = function (grunt) { reporter: 'spec' } }, + karlcow: { + src: 'test/node/testsuite.karlcow.js', + options: { + globals: ['should'], + timeout: 3000, + ignoreLeaks: false, + reporter: 'spec' + } + }, browser: { src: 'test/browser/**/*.js', options: { diff --git a/dist/showdown.js b/dist/showdown.js index c0ecb71..cf41fdd 100644 Binary files a/dist/showdown.js and b/dist/showdown.js differ diff --git a/dist/showdown.js.map b/dist/showdown.js.map index d5ca435..c511729 100644 Binary files a/dist/showdown.js.map and b/dist/showdown.js.map differ diff --git a/dist/showdown.min.js b/dist/showdown.min.js index 2d54e30..b7a711f 100644 Binary files a/dist/showdown.min.js and b/dist/showdown.min.js differ diff --git a/dist/showdown.min.js.map b/dist/showdown.min.js.map index cb81904..7e23917 100644 Binary files a/dist/showdown.min.js.map and b/dist/showdown.min.js.map differ diff --git a/package.json b/package.json index 910a834..c420360 100644 --- a/package.json +++ b/package.json @@ -45,6 +45,7 @@ "grunt-conventional-changelog": "^1.1.0", "grunt-jscs": "^1.2.0", "grunt-simple-mocha": "^0.4.0", + "js-beautify": "^1.5.6", "jscs": "^1.10.0", "load-grunt-tasks": "^3.2.0", "mocha": "*", diff --git a/src/converter.js b/src/converter.js index ea14051..4b4b208 100644 --- a/src/converter.js +++ b/src/converter.js @@ -24,7 +24,8 @@ showdown.Converter = function (converterOptions) { */ options = { omitExtraWLInCodeBlocks: false, - prefixHeaderId: false + prefixHeaderId: false, + noHeaderId: false }, /** diff --git a/src/showdown.js b/src/showdown.js index 39321cf..949e9f7 100644 --- a/src/showdown.js +++ b/src/showdown.js @@ -8,7 +8,8 @@ var showdown = {}, extensions = {}, defaultOptions = { omitExtraWLInCodeBlocks: false, - prefixHeaderId: false + prefixHeaderId: false, + noHeaderId: false }, globalOptions = JSON.parse(JSON.stringify(defaultOptions)); //clone default options out of laziness =P diff --git a/src/subParsers/headers.js b/src/subParsers/headers.js index e723098..04e4dc3 100644 --- a/src/subParsers/headers.js +++ b/src/subParsers/headers.js @@ -11,14 +11,17 @@ showdown.subParser('headers', function (text, options, globals) { // -------- // text = text.replace(/^(.+)[ \t]*\n=+[ \t]*\n+/gm, function (wholeMatch, m1) { + var spanGamut = showdown.subParser('spanGamut')(m1, options, globals), - hashBlock = '

' + spanGamut + '

'; + hID = (options.noHeaderId) ? '' : ' id="' + headerId(m1) + '"', + hashBlock = '' + spanGamut + ''; return showdown.subParser('hashBlock')(hashBlock, options, globals); }); text = text.replace(/^(.+)[ \t]*\n-+[ \t]*\n+/gm, function (matchFound, m1) { var spanGamut = showdown.subParser('spanGamut')(m1, options, globals), - hashBlock = '

' + spanGamut + '

'; + hID = (options.noHeaderId) ? '' : ' id="' + headerId(m1) + '"', + hashBlock = '' + spanGamut + ''; return showdown.subParser('hashBlock')(hashBlock, options, globals); }); @@ -41,9 +44,10 @@ showdown.subParser('headers', function (text, options, globals) { /gm, function() {...}); */ - text = text.replace(/^(\#{1,6})[ \t]*(.+?)[ \t]*\#*\n+/gm, function (wholeMatch, m1, m2) { + text = text.replace(/^(#{1,6})[ \t]*(.+?)[ \t]*#*\n+/gm, function (wholeMatch, m1, m2) { var span = showdown.subParser('spanGamut')(m2, options, globals), - header = '' + span + ''; + hID = (options.noHeaderId) ? '' : ' id="' + headerId(m2) + '"', + header = '' + span + ''; return showdown.subParser('hashBlock')(header, options, globals); }); diff --git a/src/subParsers/images.js b/src/subParsers/images.js index 1a1d5cc..9e66f11 100644 --- a/src/subParsers/images.js +++ b/src/subParsers/images.js @@ -39,14 +39,11 @@ showdown.subParser('images', function (text, options, globals) { url = showdown.helper.escapeCharacters(url, '*_', false); var result = '' + altText + '?[ \t]*\n?[ \t]*(?:(\n*)["(](.+?)[")][ \t]*)?(?:\n+|(?=~0))/gm; + var regex = /^[ ]{0,3}\[(.+)]:[ \t]*\n?[ \t]*?[ \t]*\n?[ \t]*(?:(\n*)["|'(](.+?)["|')][ \t]*)?(?:\n+|(?=~0))/gm; // attacklab: sentinel workarounds for lack of \A and \Z, safari\khtml bug text += '~0'; @@ -40,7 +40,7 @@ showdown.subParser('stripLinkDefinitions', function (text, options, globals) { return m3 + m4; } else if (m4) { - globals.gTitles[m1] = m4.replace(/"/g, '"'); + globals.gTitles[m1] = m4.replace(/"|'/g, '"'); } // Completely remove the definition from the text diff --git a/test/bootstrap.js b/test/bootstrap.js new file mode 100644 index 0000000..ada87f2 --- /dev/null +++ b/test/bootstrap.js @@ -0,0 +1,89 @@ +/** + * Created by Estevao on 08-06-2015. + */ + +//jscs:disable requireCamelCaseOrUpperCaseIdentifiers +require('source-map-support').install(); +require('chai').should(); +var fs = require('fs'), + os = require('os'), + beautify = require('js-beautify').html_beautify, + beauOptions = { + eol: os.EOL, + indent_size: 2, + preserve_newlines: false + }; + +function getTestSuite(dir) { + return fs.readdirSync(dir) + .filter(filter()) + .map(map(dir)); +} + +function filter() { + return function (file) { + var ext = file.slice(-3); + return (ext === '.md'); + }; +} + +function map(dir) { + return function (file) { + var name = file.replace('.md', ''), + htmlPath = dir + name + '.html', + html = fs.readFileSync(htmlPath, 'utf8'), + mdPath = dir + name + '.md', + md = fs.readFileSync(mdPath, 'utf8'); + + return { + name: name, + input: md, + expected: html + }; + }; +} + +function assertion(testCase, converter) { + return function () { + testCase.actual = converter.makeHtml(testCase.input); + testCase = normalize(testCase); + + // Compare + testCase.actual.should.equal(testCase.expected); + }; +} + +//Normalize input/output +function normalize(testCase) { + + // Normalize line returns + testCase.expected = testCase.expected.replace(/(\r\n)|\n|\r/g, '\n'); + testCase.actual = testCase.actual.replace(/(\r\n)|\n|\r/g, '\n'); + + // Ignore all leading/trailing whitespace + testCase.expected = testCase.expected.split('\n').map(function (x) { + return x.trim(); + }).join('\n'); + testCase.actual = testCase.actual.split('\n').map(function (x) { + return x.trim(); + }).join('\n'); + + // Remove extra lines + testCase.expected = testCase.expected.trim(); + testCase.actual = testCase.actual.trim(); + + //Beautify + testCase.expected = beautify(testCase.expected, beauOptions); + testCase.actual = beautify(testCase.actual, beauOptions); + + // Normalize line returns + testCase.expected = testCase.expected.replace(/(\r\n)|\n|\r/g, os.EOL); + testCase.actual = testCase.actual.replace(/(\r\n)|\n|\r/g, os.EOL); + + return testCase; +} + +module.exports = { + getTestSuite: getTestSuite, + assertion: assertion +}; diff --git a/test/cases/images.html b/test/cases/images.html index 7df5855..d1e0cb3 100644 --- a/test/cases/images.html +++ b/test/cases/images.html @@ -1,4 +1,4 @@ -

Alt text

+

Alt text

Alt text

diff --git a/test/karlcow/2-paragraphs-hard-return-spaces.html b/test/karlcow/2-paragraphs-hard-return-spaces.html new file mode 100644 index 0000000..ed211e1 --- /dev/null +++ b/test/karlcow/2-paragraphs-hard-return-spaces.html @@ -0,0 +1,5 @@ +

This is a first paragraph, +on multiple lines.

+ +

This is a second paragraph. +There are spaces in between the two.

\ No newline at end of file diff --git a/test/karlcow/2-paragraphs-hard-return-spaces.md b/test/karlcow/2-paragraphs-hard-return-spaces.md new file mode 100644 index 0000000..77ecf1e --- /dev/null +++ b/test/karlcow/2-paragraphs-hard-return-spaces.md @@ -0,0 +1,5 @@ +This is a first paragraph, +on multiple lines. + +This is a second paragraph. +There are spaces in between the two. \ No newline at end of file diff --git a/test/karlcow/2-paragraphs-hard-return.html b/test/karlcow/2-paragraphs-hard-return.html new file mode 100644 index 0000000..5da1c69 --- /dev/null +++ b/test/karlcow/2-paragraphs-hard-return.html @@ -0,0 +1,5 @@ +

This is a first paragraph, +on multiple lines.

+ +

This is a second paragraph +which has multiple lines too.

\ No newline at end of file diff --git a/test/karlcow/2-paragraphs-hard-return.md b/test/karlcow/2-paragraphs-hard-return.md new file mode 100644 index 0000000..7e103ad --- /dev/null +++ b/test/karlcow/2-paragraphs-hard-return.md @@ -0,0 +1,5 @@ +This is a first paragraph, +on multiple lines. + +This is a second paragraph +which has multiple lines too. \ No newline at end of file diff --git a/test/karlcow/2-paragraphs-line-returns.html b/test/karlcow/2-paragraphs-line-returns.html new file mode 100644 index 0000000..89f0e94 --- /dev/null +++ b/test/karlcow/2-paragraphs-line-returns.html @@ -0,0 +1,3 @@ +

A first paragraph.

+ +

A second paragraph after 3 CR (carriage return).

\ No newline at end of file diff --git a/test/karlcow/2-paragraphs-line-returns.md b/test/karlcow/2-paragraphs-line-returns.md new file mode 100644 index 0000000..6eefed1 --- /dev/null +++ b/test/karlcow/2-paragraphs-line-returns.md @@ -0,0 +1,5 @@ +A first paragraph. + + + +A second paragraph after 3 CR (carriage return). \ No newline at end of file diff --git a/test/karlcow/2-paragraphs-line-spaces.html b/test/karlcow/2-paragraphs-line-spaces.html new file mode 100644 index 0000000..39270cc --- /dev/null +++ b/test/karlcow/2-paragraphs-line-spaces.html @@ -0,0 +1,3 @@ +

This a very long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long paragraph on 1 line.

+ +

A few spaces and a new long long long long long long long long long long long long long long long long paragraph on 1 line.

\ No newline at end of file diff --git a/test/karlcow/2-paragraphs-line-spaces.md b/test/karlcow/2-paragraphs-line-spaces.md new file mode 100644 index 0000000..59b9c3c --- /dev/null +++ b/test/karlcow/2-paragraphs-line-spaces.md @@ -0,0 +1,3 @@ +This a very long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long paragraph on 1 line. + +A few spaces and a new long long long long long long long long long long long long long long long long paragraph on 1 line. \ No newline at end of file diff --git a/test/karlcow/2-paragraphs-line-tab.html b/test/karlcow/2-paragraphs-line-tab.html new file mode 100644 index 0000000..6ba5a11 --- /dev/null +++ b/test/karlcow/2-paragraphs-line-tab.html @@ -0,0 +1,3 @@ +

This a very long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long paragraph on 1 line.

+ +

1 tab to separate them and a new long long long long long long long long long long long long long long long long paragraph on 1 line.

\ No newline at end of file diff --git a/test/karlcow/2-paragraphs-line-tab.md b/test/karlcow/2-paragraphs-line-tab.md new file mode 100644 index 0000000..9dcc229 --- /dev/null +++ b/test/karlcow/2-paragraphs-line-tab.md @@ -0,0 +1,3 @@ +This a very long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long paragraph on 1 line. + +1 tab to separate them and a new long long long long long long long long long long long long long long long long paragraph on 1 line. \ No newline at end of file diff --git a/test/karlcow/2-paragraphs-line.html b/test/karlcow/2-paragraphs-line.html new file mode 100644 index 0000000..8812518 --- /dev/null +++ b/test/karlcow/2-paragraphs-line.html @@ -0,0 +1,3 @@ +

This a very long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long paragraph on 1 line.

+ +

A new long long long long long long long long long long long long long long long long paragraph on 1 line.

\ No newline at end of file diff --git a/test/karlcow/2-paragraphs-line.md b/test/karlcow/2-paragraphs-line.md new file mode 100644 index 0000000..4cff3ed --- /dev/null +++ b/test/karlcow/2-paragraphs-line.md @@ -0,0 +1,3 @@ +This a very long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long paragraph on 1 line. + +A new long long long long long long long long long long long long long long long long paragraph on 1 line. \ No newline at end of file diff --git a/test/karlcow/EOL-CR+LF.html b/test/karlcow/EOL-CR+LF.html new file mode 100644 index 0000000..c236b1d --- /dev/null +++ b/test/karlcow/EOL-CR+LF.html @@ -0,0 +1,5 @@ +

These lines all end with end of line (EOL) sequences.

+ +

Seriously, they really do.

+ +

If you don't believe me: HEX EDIT!

\ No newline at end of file diff --git a/test/karlcow/EOL-CR+LF.md b/test/karlcow/EOL-CR+LF.md new file mode 100644 index 0000000..15cb86e --- /dev/null +++ b/test/karlcow/EOL-CR+LF.md @@ -0,0 +1,6 @@ +These lines all end with end of line (EOL) sequences. + +Seriously, they really do. + +If you don't believe me: HEX EDIT! + diff --git a/test/karlcow/EOL-CR.html b/test/karlcow/EOL-CR.html new file mode 100644 index 0000000..36a489b --- /dev/null +++ b/test/karlcow/EOL-CR.html @@ -0,0 +1 @@ +

These lines all end with end of line (EOL) sequences.

Seriously, they really do.

If you don't believe me: HEX EDIT!

\ No newline at end of file diff --git a/test/karlcow/EOL-CR.md b/test/karlcow/EOL-CR.md new file mode 100644 index 0000000..f0a17c8 --- /dev/null +++ b/test/karlcow/EOL-CR.md @@ -0,0 +1 @@ +These lines all end with end of line (EOL) sequences. Seriously, they really do. If you don't believe me: HEX EDIT! \ No newline at end of file diff --git a/test/karlcow/EOL-LF.html b/test/karlcow/EOL-LF.html new file mode 100644 index 0000000..c236b1d --- /dev/null +++ b/test/karlcow/EOL-LF.html @@ -0,0 +1,5 @@ +

These lines all end with end of line (EOL) sequences.

+ +

Seriously, they really do.

+ +

If you don't believe me: HEX EDIT!

\ No newline at end of file diff --git a/test/karlcow/EOL-LF.md b/test/karlcow/EOL-LF.md new file mode 100644 index 0000000..15cb86e --- /dev/null +++ b/test/karlcow/EOL-LF.md @@ -0,0 +1,6 @@ +These lines all end with end of line (EOL) sequences. + +Seriously, they really do. + +If you don't believe me: HEX EDIT! + diff --git a/test/karlcow/ampersand-text-flow.html b/test/karlcow/ampersand-text-flow.html new file mode 100644 index 0000000..0f2eaf3 --- /dev/null +++ b/test/karlcow/ampersand-text-flow.html @@ -0,0 +1 @@ +

An ampersand & in the text flow is escaped as an html entity.

\ No newline at end of file diff --git a/test/karlcow/ampersand-text-flow.md b/test/karlcow/ampersand-text-flow.md new file mode 100644 index 0000000..fb83563 --- /dev/null +++ b/test/karlcow/ampersand-text-flow.md @@ -0,0 +1 @@ +An ampersand & in the text flow is escaped as an html entity. \ No newline at end of file diff --git a/test/karlcow/ampersand-uri.html b/test/karlcow/ampersand-uri.html new file mode 100644 index 0000000..de4b210 --- /dev/null +++ b/test/karlcow/ampersand-uri.html @@ -0,0 +1 @@ +

There is an ampersand in the URI.

\ No newline at end of file diff --git a/test/karlcow/ampersand-uri.md b/test/karlcow/ampersand-uri.md new file mode 100644 index 0000000..499635e --- /dev/null +++ b/test/karlcow/ampersand-uri.md @@ -0,0 +1 @@ +There is an [ampersand](http://validator.w3.org/check?uri=http://www.w3.org/&verbose=1) in the URI. \ No newline at end of file diff --git a/test/karlcow/asterisk-near-text.html b/test/karlcow/asterisk-near-text.html new file mode 100644 index 0000000..aa442c3 --- /dev/null +++ b/test/karlcow/asterisk-near-text.html @@ -0,0 +1 @@ +

This is *an asterisk which should stay as is.

\ No newline at end of file diff --git a/test/karlcow/asterisk-near-text.md b/test/karlcow/asterisk-near-text.md new file mode 100644 index 0000000..b27634d --- /dev/null +++ b/test/karlcow/asterisk-near-text.md @@ -0,0 +1 @@ +This is \*an asterisk which should stay as is. \ No newline at end of file diff --git a/test/karlcow/asterisk.html b/test/karlcow/asterisk.html new file mode 100644 index 0000000..b6c93a8 --- /dev/null +++ b/test/karlcow/asterisk.html @@ -0,0 +1 @@ +

This is * an asterisk which should stay as is.

\ No newline at end of file diff --git a/test/karlcow/asterisk.md b/test/karlcow/asterisk.md new file mode 100644 index 0000000..ccbbc23 --- /dev/null +++ b/test/karlcow/asterisk.md @@ -0,0 +1 @@ +This is * an asterisk which should stay as is. \ No newline at end of file diff --git a/test/karlcow/backslash-escape.html b/test/karlcow/backslash-escape.html new file mode 100644 index 0000000..d69d385 --- /dev/null +++ b/test/karlcow/backslash-escape.html @@ -0,0 +1,12 @@ +

\ backslash +` backtick +* asterisk +_ underscore +{} curly braces +[] square brackets +() parentheses +# hash mark ++ plus sign +- minus sign (hyphen) +. dot +! exclamation mark

\ No newline at end of file diff --git a/test/karlcow/backslash-escape.md b/test/karlcow/backslash-escape.md new file mode 100644 index 0000000..306aca2 --- /dev/null +++ b/test/karlcow/backslash-escape.md @@ -0,0 +1,12 @@ +\\ backslash +\` backtick +\* asterisk +\_ underscore +\{\} curly braces +\[\] square brackets +\(\) parentheses +\# hash mark +\+ plus sign +\- minus sign (hyphen) +\. dot +\! exclamation mark \ No newline at end of file diff --git a/test/karlcow/blockquote-added-markup.html b/test/karlcow/blockquote-added-markup.html new file mode 100644 index 0000000..375dbe8 --- /dev/null +++ b/test/karlcow/blockquote-added-markup.html @@ -0,0 +1,5 @@ +
+

heading level 1

+ +

paragraph

+
diff --git a/test/karlcow/blockquote-added-markup.md b/test/karlcow/blockquote-added-markup.md new file mode 100644 index 0000000..b60a049 --- /dev/null +++ b/test/karlcow/blockquote-added-markup.md @@ -0,0 +1,3 @@ +> # heading level 1 +> +> paragraph \ No newline at end of file diff --git a/test/karlcow/blockquote-line-2-paragraphs.html b/test/karlcow/blockquote-line-2-paragraphs.html new file mode 100644 index 0000000..9cb7059 --- /dev/null +++ b/test/karlcow/blockquote-line-2-paragraphs.html @@ -0,0 +1,5 @@ +
+

A blockquote with a very long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long line.

+ +

and a second very long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long line.

+
\ No newline at end of file diff --git a/test/karlcow/blockquote-line-2-paragraphs.md b/test/karlcow/blockquote-line-2-paragraphs.md new file mode 100644 index 0000000..46358c0 --- /dev/null +++ b/test/karlcow/blockquote-line-2-paragraphs.md @@ -0,0 +1,3 @@ +>A blockquote with a very long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long line. + +>and a second very long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long line. \ No newline at end of file diff --git a/test/karlcow/blockquote-line.html b/test/karlcow/blockquote-line.html new file mode 100644 index 0000000..41451af --- /dev/null +++ b/test/karlcow/blockquote-line.html @@ -0,0 +1,3 @@ +
+

This a very long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long paragraph in a blockquote.

+
\ No newline at end of file diff --git a/test/karlcow/blockquote-line.md b/test/karlcow/blockquote-line.md new file mode 100644 index 0000000..23990a3 --- /dev/null +++ b/test/karlcow/blockquote-line.md @@ -0,0 +1 @@ +>This a very long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long paragraph in a blockquote. \ No newline at end of file diff --git a/test/karlcow/blockquote-multiline-1-space-begin.html b/test/karlcow/blockquote-multiline-1-space-begin.html new file mode 100644 index 0000000..6282d21 --- /dev/null +++ b/test/karlcow/blockquote-multiline-1-space-begin.html @@ -0,0 +1,5 @@ +
+

A blockquote +on multiple lines +like this.

+
\ No newline at end of file diff --git a/test/karlcow/blockquote-multiline-1-space-begin.md b/test/karlcow/blockquote-multiline-1-space-begin.md new file mode 100644 index 0000000..eafd549 --- /dev/null +++ b/test/karlcow/blockquote-multiline-1-space-begin.md @@ -0,0 +1,3 @@ +> A blockquote +> on multiple lines +> like this. \ No newline at end of file diff --git a/test/karlcow/blockquote-multiline-1-space-end.html b/test/karlcow/blockquote-multiline-1-space-end.html new file mode 100644 index 0000000..82907e2 --- /dev/null +++ b/test/karlcow/blockquote-multiline-1-space-end.html @@ -0,0 +1,5 @@ +
+

A blockquote +on multiple lines +like this.

+
\ No newline at end of file diff --git a/test/karlcow/blockquote-multiline-1-space-end.md b/test/karlcow/blockquote-multiline-1-space-end.md new file mode 100644 index 0000000..014617a --- /dev/null +++ b/test/karlcow/blockquote-multiline-1-space-end.md @@ -0,0 +1,3 @@ +>A blockquote +>on multiple lines +>like this. \ No newline at end of file diff --git a/test/karlcow/blockquote-multiline-2-paragraphs.html b/test/karlcow/blockquote-multiline-2-paragraphs.html new file mode 100644 index 0000000..1339eee --- /dev/null +++ b/test/karlcow/blockquote-multiline-2-paragraphs.html @@ -0,0 +1,8 @@ +
+

A blockquote +on multiple lines +like this.

+ +

But it has +two paragraphs.

+
\ No newline at end of file diff --git a/test/karlcow/blockquote-multiline-2-paragraphs.md b/test/karlcow/blockquote-multiline-2-paragraphs.md new file mode 100644 index 0000000..0af137d --- /dev/null +++ b/test/karlcow/blockquote-multiline-2-paragraphs.md @@ -0,0 +1,6 @@ +>A blockquote +>on multiple lines +>like this. +> +>But it has +>two paragraphs. \ No newline at end of file diff --git a/test/karlcow/blockquote-multiline.html b/test/karlcow/blockquote-multiline.html new file mode 100644 index 0000000..18126d4 --- /dev/null +++ b/test/karlcow/blockquote-multiline.html @@ -0,0 +1,5 @@ +
+

A blockquote +on multiple lines +like this

+
\ No newline at end of file diff --git a/test/karlcow/blockquote-multiline.md b/test/karlcow/blockquote-multiline.md new file mode 100644 index 0000000..283f95d --- /dev/null +++ b/test/karlcow/blockquote-multiline.md @@ -0,0 +1,3 @@ +>A blockquote +>on multiple lines +>like this \ No newline at end of file diff --git a/test/karlcow/blockquote-nested-multiplereturn-level1.html b/test/karlcow/blockquote-nested-multiplereturn-level1.html new file mode 100644 index 0000000..37d039d --- /dev/null +++ b/test/karlcow/blockquote-nested-multiplereturn-level1.html @@ -0,0 +1,9 @@ +
+

This is the first level of quoting.

+ +
+

This is nested blockquote.

+
+ +

Back to the first level.

+
\ No newline at end of file diff --git a/test/karlcow/blockquote-nested-multiplereturn-level1.md b/test/karlcow/blockquote-nested-multiplereturn-level1.md new file mode 100644 index 0000000..8b2530f --- /dev/null +++ b/test/karlcow/blockquote-nested-multiplereturn-level1.md @@ -0,0 +1,5 @@ +> This is the first level of quoting. +> +> > This is nested blockquote. +> +> Back to the first level. diff --git a/test/karlcow/blockquote-nested-multiplereturn.html b/test/karlcow/blockquote-nested-multiplereturn.html new file mode 100644 index 0000000..5b0d801 --- /dev/null +++ b/test/karlcow/blockquote-nested-multiplereturn.html @@ -0,0 +1,7 @@ +
+

This is the first level of quoting.

+ +
+

This is nested blockquote.

+
+
\ No newline at end of file diff --git a/test/karlcow/blockquote-nested-multiplereturn.md b/test/karlcow/blockquote-nested-multiplereturn.md new file mode 100644 index 0000000..4a8202d --- /dev/null +++ b/test/karlcow/blockquote-nested-multiplereturn.md @@ -0,0 +1,3 @@ +> This is the first level of quoting. +> +> > This is nested blockquote. \ No newline at end of file diff --git a/test/karlcow/blockquote-nested-return-level1.html b/test/karlcow/blockquote-nested-return-level1.html new file mode 100644 index 0000000..d37d55f --- /dev/null +++ b/test/karlcow/blockquote-nested-return-level1.html @@ -0,0 +1,8 @@ +
+

This is the first level of quoting.

+ +
+

This is nested blockquote. +Back to the first level.

+
+
\ No newline at end of file diff --git a/test/karlcow/blockquote-nested-return-level1.md b/test/karlcow/blockquote-nested-return-level1.md new file mode 100644 index 0000000..e01158b --- /dev/null +++ b/test/karlcow/blockquote-nested-return-level1.md @@ -0,0 +1,3 @@ +> This is the first level of quoting. +> > This is nested blockquote. +> Back to the first level. diff --git a/test/karlcow/blockquote-nested.html b/test/karlcow/blockquote-nested.html new file mode 100644 index 0000000..5b0d801 --- /dev/null +++ b/test/karlcow/blockquote-nested.html @@ -0,0 +1,7 @@ +
+

This is the first level of quoting.

+ +
+

This is nested blockquote.

+
+
\ No newline at end of file diff --git a/test/karlcow/blockquote-nested.md b/test/karlcow/blockquote-nested.md new file mode 100644 index 0000000..739ac21 --- /dev/null +++ b/test/karlcow/blockquote-nested.md @@ -0,0 +1,2 @@ +> This is the first level of quoting. +> > This is nested blockquote. diff --git a/test/karlcow/code-1-tab.html b/test/karlcow/code-1-tab.html new file mode 100644 index 0000000..9b8bb7a --- /dev/null +++ b/test/karlcow/code-1-tab.html @@ -0,0 +1,3 @@ +
10 PRINT HELLO INFINITE
+20 GOTO 10
+
\ No newline at end of file diff --git a/test/karlcow/code-1-tab.md b/test/karlcow/code-1-tab.md new file mode 100644 index 0000000..a314307 --- /dev/null +++ b/test/karlcow/code-1-tab.md @@ -0,0 +1,2 @@ + 10 PRINT HELLO INFINITE + 20 GOTO 10 \ No newline at end of file diff --git a/test/karlcow/code-4-spaces-escaping.html b/test/karlcow/code-4-spaces-escaping.html new file mode 100644 index 0000000..6d9fa87 --- /dev/null +++ b/test/karlcow/code-4-spaces-escaping.html @@ -0,0 +1,3 @@ +
10 PRINT < > &
+20 GOTO 10
+
\ No newline at end of file diff --git a/test/karlcow/code-4-spaces-escaping.md b/test/karlcow/code-4-spaces-escaping.md new file mode 100644 index 0000000..2edbd4e --- /dev/null +++ b/test/karlcow/code-4-spaces-escaping.md @@ -0,0 +1,2 @@ + 10 PRINT < > & + 20 GOTO 10 \ No newline at end of file diff --git a/test/karlcow/code-4-spaces.html b/test/karlcow/code-4-spaces.html new file mode 100644 index 0000000..9b8bb7a --- /dev/null +++ b/test/karlcow/code-4-spaces.html @@ -0,0 +1,3 @@ +
10 PRINT HELLO INFINITE
+20 GOTO 10
+
\ No newline at end of file diff --git a/test/karlcow/code-4-spaces.md b/test/karlcow/code-4-spaces.md new file mode 100644 index 0000000..e3b6e6d --- /dev/null +++ b/test/karlcow/code-4-spaces.md @@ -0,0 +1,2 @@ + 10 PRINT HELLO INFINITE + 20 GOTO 10 \ No newline at end of file diff --git a/test/karlcow/em-middle-word.html b/test/karlcow/em-middle-word.html new file mode 100644 index 0000000..74f7f90 --- /dev/null +++ b/test/karlcow/em-middle-word.html @@ -0,0 +1 @@ +

asterisks

\ No newline at end of file diff --git a/test/karlcow/em-middle-word.md b/test/karlcow/em-middle-word.md new file mode 100644 index 0000000..0935359 --- /dev/null +++ b/test/karlcow/em-middle-word.md @@ -0,0 +1 @@ +as*te*risks \ No newline at end of file diff --git a/test/karlcow/em-star.html b/test/karlcow/em-star.html new file mode 100644 index 0000000..d35dd53 --- /dev/null +++ b/test/karlcow/em-star.html @@ -0,0 +1 @@ +

single asterisks

\ No newline at end of file diff --git a/test/karlcow/em-star.md b/test/karlcow/em-star.md new file mode 100644 index 0000000..ddd8676 --- /dev/null +++ b/test/karlcow/em-star.md @@ -0,0 +1 @@ +*single asterisks* \ No newline at end of file diff --git a/test/karlcow/em-underscore.html b/test/karlcow/em-underscore.html new file mode 100644 index 0000000..2627bde --- /dev/null +++ b/test/karlcow/em-underscore.html @@ -0,0 +1 @@ +

single underscores

\ No newline at end of file diff --git a/test/karlcow/em-underscore.md b/test/karlcow/em-underscore.md new file mode 100644 index 0000000..155bb0e --- /dev/null +++ b/test/karlcow/em-underscore.md @@ -0,0 +1 @@ +_single underscores_ \ No newline at end of file diff --git a/test/karlcow/entities-text-flow.html b/test/karlcow/entities-text-flow.html new file mode 100644 index 0000000..6924fea --- /dev/null +++ b/test/karlcow/entities-text-flow.html @@ -0,0 +1 @@ +

HTML entities are written using ampersand notation: ©

\ No newline at end of file diff --git a/test/karlcow/entities-text-flow.md b/test/karlcow/entities-text-flow.md new file mode 100644 index 0000000..7e685ea --- /dev/null +++ b/test/karlcow/entities-text-flow.md @@ -0,0 +1 @@ +HTML entities are written using ampersand notation: © \ No newline at end of file diff --git a/test/karlcow/header-level1-equal-underlined.html b/test/karlcow/header-level1-equal-underlined.html new file mode 100644 index 0000000..af0c276 --- /dev/null +++ b/test/karlcow/header-level1-equal-underlined.html @@ -0,0 +1 @@ +

This is an H1

\ No newline at end of file diff --git a/test/karlcow/header-level1-equal-underlined.md b/test/karlcow/header-level1-equal-underlined.md new file mode 100644 index 0000000..f18b949 --- /dev/null +++ b/test/karlcow/header-level1-equal-underlined.md @@ -0,0 +1,2 @@ +This is an H1 +============= \ No newline at end of file diff --git a/test/karlcow/header-level1-hash-sign-closed.html b/test/karlcow/header-level1-hash-sign-closed.html new file mode 100644 index 0000000..af0c276 --- /dev/null +++ b/test/karlcow/header-level1-hash-sign-closed.html @@ -0,0 +1 @@ +

This is an H1

\ No newline at end of file diff --git a/test/karlcow/header-level1-hash-sign-closed.md b/test/karlcow/header-level1-hash-sign-closed.md new file mode 100644 index 0000000..147d59b --- /dev/null +++ b/test/karlcow/header-level1-hash-sign-closed.md @@ -0,0 +1 @@ +# This is an H1 # \ No newline at end of file diff --git a/test/karlcow/header-level1-hash-sign-trailing-1-space.html b/test/karlcow/header-level1-hash-sign-trailing-1-space.html new file mode 100644 index 0000000..1b48fc2 --- /dev/null +++ b/test/karlcow/header-level1-hash-sign-trailing-1-space.html @@ -0,0 +1 @@ +

# This is an H1

\ No newline at end of file diff --git a/test/karlcow/header-level1-hash-sign-trailing-1-space.md b/test/karlcow/header-level1-hash-sign-trailing-1-space.md new file mode 100644 index 0000000..b999b38 --- /dev/null +++ b/test/karlcow/header-level1-hash-sign-trailing-1-space.md @@ -0,0 +1 @@ + # This is an H1 \ No newline at end of file diff --git a/test/karlcow/header-level1-hash-sign-trailing-2-spaces.html b/test/karlcow/header-level1-hash-sign-trailing-2-spaces.html new file mode 100644 index 0000000..797d31c --- /dev/null +++ b/test/karlcow/header-level1-hash-sign-trailing-2-spaces.html @@ -0,0 +1,3 @@ +

this is an h1 with two trailing spaces

+ +

A new paragraph.

\ No newline at end of file diff --git a/test/karlcow/header-level1-hash-sign-trailing-2-spaces.md b/test/karlcow/header-level1-hash-sign-trailing-2-spaces.md new file mode 100644 index 0000000..9cdcedf --- /dev/null +++ b/test/karlcow/header-level1-hash-sign-trailing-2-spaces.md @@ -0,0 +1,2 @@ +# this is an h1 with two trailing spaces +A new paragraph. \ No newline at end of file diff --git a/test/karlcow/header-level1-hash-sign.html b/test/karlcow/header-level1-hash-sign.html new file mode 100644 index 0000000..af0c276 --- /dev/null +++ b/test/karlcow/header-level1-hash-sign.html @@ -0,0 +1 @@ +

This is an H1

\ No newline at end of file diff --git a/test/karlcow/header-level1-hash-sign.md b/test/karlcow/header-level1-hash-sign.md new file mode 100644 index 0000000..f6a39e1 --- /dev/null +++ b/test/karlcow/header-level1-hash-sign.md @@ -0,0 +1 @@ +# This is an H1 \ No newline at end of file diff --git a/test/karlcow/header-level2-dash-underlined.html b/test/karlcow/header-level2-dash-underlined.html new file mode 100644 index 0000000..2f4138b --- /dev/null +++ b/test/karlcow/header-level2-dash-underlined.html @@ -0,0 +1 @@ +

This is an H2

\ No newline at end of file diff --git a/test/karlcow/header-level2-dash-underlined.md b/test/karlcow/header-level2-dash-underlined.md new file mode 100644 index 0000000..4564336 --- /dev/null +++ b/test/karlcow/header-level2-dash-underlined.md @@ -0,0 +1,2 @@ +This is an H2 +------------- \ No newline at end of file diff --git a/test/karlcow/header-level2-hash-sign-closed.html b/test/karlcow/header-level2-hash-sign-closed.html new file mode 100644 index 0000000..2f4138b --- /dev/null +++ b/test/karlcow/header-level2-hash-sign-closed.html @@ -0,0 +1 @@ +

This is an H2

\ No newline at end of file diff --git a/test/karlcow/header-level2-hash-sign-closed.md b/test/karlcow/header-level2-hash-sign-closed.md new file mode 100644 index 0000000..b84a1de --- /dev/null +++ b/test/karlcow/header-level2-hash-sign-closed.md @@ -0,0 +1 @@ +## This is an H2 ## \ No newline at end of file diff --git a/test/karlcow/header-level2-hash-sign.html b/test/karlcow/header-level2-hash-sign.html new file mode 100644 index 0000000..2f4138b --- /dev/null +++ b/test/karlcow/header-level2-hash-sign.html @@ -0,0 +1 @@ +

This is an H2

\ No newline at end of file diff --git a/test/karlcow/header-level2-hash-sign.md b/test/karlcow/header-level2-hash-sign.md new file mode 100644 index 0000000..6a93c6b --- /dev/null +++ b/test/karlcow/header-level2-hash-sign.md @@ -0,0 +1 @@ +## This is an H2 \ No newline at end of file diff --git a/test/karlcow/header-level3-hash-sign-closed.html b/test/karlcow/header-level3-hash-sign-closed.html new file mode 100644 index 0000000..a9d3ba9 --- /dev/null +++ b/test/karlcow/header-level3-hash-sign-closed.html @@ -0,0 +1 @@ +

This is an H3

\ No newline at end of file diff --git a/test/karlcow/header-level3-hash-sign-closed.md b/test/karlcow/header-level3-hash-sign-closed.md new file mode 100644 index 0000000..7d790cf --- /dev/null +++ b/test/karlcow/header-level3-hash-sign-closed.md @@ -0,0 +1 @@ +### This is an H3 ### \ No newline at end of file diff --git a/test/karlcow/header-level3-hash-sign.html b/test/karlcow/header-level3-hash-sign.html new file mode 100644 index 0000000..a9d3ba9 --- /dev/null +++ b/test/karlcow/header-level3-hash-sign.html @@ -0,0 +1 @@ +

This is an H3

\ No newline at end of file diff --git a/test/karlcow/header-level3-hash-sign.md b/test/karlcow/header-level3-hash-sign.md new file mode 100644 index 0000000..70c6d10 --- /dev/null +++ b/test/karlcow/header-level3-hash-sign.md @@ -0,0 +1 @@ +### This is an H3 \ No newline at end of file diff --git a/test/karlcow/header-level4-hash-sign-closed.html b/test/karlcow/header-level4-hash-sign-closed.html new file mode 100644 index 0000000..1c0f3d6 --- /dev/null +++ b/test/karlcow/header-level4-hash-sign-closed.html @@ -0,0 +1 @@ +

This is an H4

\ No newline at end of file diff --git a/test/karlcow/header-level4-hash-sign-closed.md b/test/karlcow/header-level4-hash-sign-closed.md new file mode 100644 index 0000000..716cf64 --- /dev/null +++ b/test/karlcow/header-level4-hash-sign-closed.md @@ -0,0 +1 @@ +#### This is an H4 #### \ No newline at end of file diff --git a/test/karlcow/header-level4-hash-sign.html b/test/karlcow/header-level4-hash-sign.html new file mode 100644 index 0000000..1c0f3d6 --- /dev/null +++ b/test/karlcow/header-level4-hash-sign.html @@ -0,0 +1 @@ +

This is an H4

\ No newline at end of file diff --git a/test/karlcow/header-level4-hash-sign.md b/test/karlcow/header-level4-hash-sign.md new file mode 100644 index 0000000..8283f11 --- /dev/null +++ b/test/karlcow/header-level4-hash-sign.md @@ -0,0 +1 @@ +#### This is an H4 \ No newline at end of file diff --git a/test/karlcow/header-level5-hash-sign-closed.html b/test/karlcow/header-level5-hash-sign-closed.html new file mode 100644 index 0000000..aa43910 --- /dev/null +++ b/test/karlcow/header-level5-hash-sign-closed.html @@ -0,0 +1 @@ +
This is an H5
\ No newline at end of file diff --git a/test/karlcow/header-level5-hash-sign-closed.md b/test/karlcow/header-level5-hash-sign-closed.md new file mode 100644 index 0000000..4294de6 --- /dev/null +++ b/test/karlcow/header-level5-hash-sign-closed.md @@ -0,0 +1 @@ +##### This is an H5 ##### \ No newline at end of file diff --git a/test/karlcow/header-level5-hash-sign.html b/test/karlcow/header-level5-hash-sign.html new file mode 100644 index 0000000..aa43910 --- /dev/null +++ b/test/karlcow/header-level5-hash-sign.html @@ -0,0 +1 @@ +
This is an H5
\ No newline at end of file diff --git a/test/karlcow/header-level5-hash-sign.md b/test/karlcow/header-level5-hash-sign.md new file mode 100644 index 0000000..abcdd91 --- /dev/null +++ b/test/karlcow/header-level5-hash-sign.md @@ -0,0 +1 @@ +##### This is an H5 \ No newline at end of file diff --git a/test/karlcow/header-level6-hash-sign-closed.html b/test/karlcow/header-level6-hash-sign-closed.html new file mode 100644 index 0000000..2cbc7b1 --- /dev/null +++ b/test/karlcow/header-level6-hash-sign-closed.html @@ -0,0 +1 @@ +
This is an H6
\ No newline at end of file diff --git a/test/karlcow/header-level6-hash-sign-closed.md b/test/karlcow/header-level6-hash-sign-closed.md new file mode 100644 index 0000000..dca50d6 --- /dev/null +++ b/test/karlcow/header-level6-hash-sign-closed.md @@ -0,0 +1 @@ +###### This is an H6 ###### \ No newline at end of file diff --git a/test/karlcow/header-level6-hash-sign.html b/test/karlcow/header-level6-hash-sign.html new file mode 100644 index 0000000..2cbc7b1 --- /dev/null +++ b/test/karlcow/header-level6-hash-sign.html @@ -0,0 +1 @@ +
This is an H6
\ No newline at end of file diff --git a/test/karlcow/header-level6-hash-sign.md b/test/karlcow/header-level6-hash-sign.md new file mode 100644 index 0000000..df2ff4c --- /dev/null +++ b/test/karlcow/header-level6-hash-sign.md @@ -0,0 +1 @@ +###### This is an H6 \ No newline at end of file diff --git a/test/karlcow/horizontal-rule-3-dashes-spaces.html b/test/karlcow/horizontal-rule-3-dashes-spaces.html new file mode 100644 index 0000000..1d6667d --- /dev/null +++ b/test/karlcow/horizontal-rule-3-dashes-spaces.html @@ -0,0 +1 @@ +
\ No newline at end of file diff --git a/test/karlcow/horizontal-rule-3-dashes-spaces.md b/test/karlcow/horizontal-rule-3-dashes-spaces.md new file mode 100644 index 0000000..4587849 --- /dev/null +++ b/test/karlcow/horizontal-rule-3-dashes-spaces.md @@ -0,0 +1 @@ +- - - \ No newline at end of file diff --git a/test/karlcow/horizontal-rule-3-dashes.html b/test/karlcow/horizontal-rule-3-dashes.html new file mode 100644 index 0000000..1d6667d --- /dev/null +++ b/test/karlcow/horizontal-rule-3-dashes.html @@ -0,0 +1 @@ +
\ No newline at end of file diff --git a/test/karlcow/horizontal-rule-3-dashes.md b/test/karlcow/horizontal-rule-3-dashes.md new file mode 100644 index 0000000..73b314f --- /dev/null +++ b/test/karlcow/horizontal-rule-3-dashes.md @@ -0,0 +1 @@ +--- \ No newline at end of file diff --git a/test/karlcow/horizontal-rule-3-stars.html b/test/karlcow/horizontal-rule-3-stars.html new file mode 100644 index 0000000..1d6667d --- /dev/null +++ b/test/karlcow/horizontal-rule-3-stars.html @@ -0,0 +1 @@ +
\ No newline at end of file diff --git a/test/karlcow/horizontal-rule-3-stars.md b/test/karlcow/horizontal-rule-3-stars.md new file mode 100644 index 0000000..93a5273 --- /dev/null +++ b/test/karlcow/horizontal-rule-3-stars.md @@ -0,0 +1 @@ +*** \ No newline at end of file diff --git a/test/karlcow/horizontal-rule-3-underscores.html b/test/karlcow/horizontal-rule-3-underscores.html new file mode 100644 index 0000000..1d6667d --- /dev/null +++ b/test/karlcow/horizontal-rule-3-underscores.html @@ -0,0 +1 @@ +
\ No newline at end of file diff --git a/test/karlcow/horizontal-rule-3-underscores.md b/test/karlcow/horizontal-rule-3-underscores.md new file mode 100644 index 0000000..da706a0 --- /dev/null +++ b/test/karlcow/horizontal-rule-3-underscores.md @@ -0,0 +1 @@ +___ \ No newline at end of file diff --git a/test/karlcow/horizontal-rule-7-dashes.html b/test/karlcow/horizontal-rule-7-dashes.html new file mode 100644 index 0000000..1d6667d --- /dev/null +++ b/test/karlcow/horizontal-rule-7-dashes.html @@ -0,0 +1 @@ +
\ No newline at end of file diff --git a/test/karlcow/horizontal-rule-7-dashes.md b/test/karlcow/horizontal-rule-7-dashes.md new file mode 100644 index 0000000..f88adb6 --- /dev/null +++ b/test/karlcow/horizontal-rule-7-dashes.md @@ -0,0 +1 @@ +------- \ No newline at end of file diff --git a/test/karlcow/img-idref-title.html b/test/karlcow/img-idref-title.html new file mode 100644 index 0000000..f9b1715 --- /dev/null +++ b/test/karlcow/img-idref-title.html @@ -0,0 +1 @@ +

HTML5

\ No newline at end of file diff --git a/test/karlcow/img-idref-title.md b/test/karlcow/img-idref-title.md new file mode 100644 index 0000000..151b1e8 --- /dev/null +++ b/test/karlcow/img-idref-title.md @@ -0,0 +1,3 @@ +![HTML5][h5] + +[h5]: http://www.w3.org/html/logo/img/mark-word-icon.png "HTML5 for everyone" \ No newline at end of file diff --git a/test/karlcow/img-idref.html b/test/karlcow/img-idref.html new file mode 100644 index 0000000..79103a8 --- /dev/null +++ b/test/karlcow/img-idref.html @@ -0,0 +1 @@ +

HTML5

\ No newline at end of file diff --git a/test/karlcow/img-idref.md b/test/karlcow/img-idref.md new file mode 100644 index 0000000..4db1bcc --- /dev/null +++ b/test/karlcow/img-idref.md @@ -0,0 +1,3 @@ +![HTML5][h5] + +[h5]: http://www.w3.org/html/logo/img/mark-word-icon.png \ No newline at end of file diff --git a/test/karlcow/img-title.html b/test/karlcow/img-title.html new file mode 100644 index 0000000..cc0e195 --- /dev/null +++ b/test/karlcow/img-title.html @@ -0,0 +1 @@ +

HTML5

\ No newline at end of file diff --git a/test/karlcow/img-title.md b/test/karlcow/img-title.md new file mode 100644 index 0000000..2c8e6ff --- /dev/null +++ b/test/karlcow/img-title.md @@ -0,0 +1 @@ +![HTML5](http://www.w3.org/html/logo/img/mark-word-icon.png "HTML5 logo for everyone") \ No newline at end of file diff --git a/test/karlcow/img.html b/test/karlcow/img.html new file mode 100644 index 0000000..79103a8 --- /dev/null +++ b/test/karlcow/img.html @@ -0,0 +1 @@ +

HTML5

\ No newline at end of file diff --git a/test/karlcow/img.md b/test/karlcow/img.md new file mode 100644 index 0000000..3b3ca15 --- /dev/null +++ b/test/karlcow/img.md @@ -0,0 +1 @@ +![HTML5](http://www.w3.org/html/logo/img/mark-word-icon.png) \ No newline at end of file diff --git a/test/karlcow/inline-code-escaping-entities.html b/test/karlcow/inline-code-escaping-entities.html new file mode 100644 index 0000000..726e8a8 --- /dev/null +++ b/test/karlcow/inline-code-escaping-entities.html @@ -0,0 +1 @@ +

We love <code> and & for everything

\ No newline at end of file diff --git a/test/karlcow/inline-code-escaping-entities.md b/test/karlcow/inline-code-escaping-entities.md new file mode 100644 index 0000000..3821a9b --- /dev/null +++ b/test/karlcow/inline-code-escaping-entities.md @@ -0,0 +1 @@ +We love ` and &` for everything \ No newline at end of file diff --git a/test/karlcow/inline-code-with-visible-backtick.html b/test/karlcow/inline-code-with-visible-backtick.html new file mode 100644 index 0000000..bc92165 --- /dev/null +++ b/test/karlcow/inline-code-with-visible-backtick.html @@ -0,0 +1 @@ +

We love `code` for everything

\ No newline at end of file diff --git a/test/karlcow/inline-code-with-visible-backtick.md b/test/karlcow/inline-code-with-visible-backtick.md new file mode 100644 index 0000000..ecc9408 --- /dev/null +++ b/test/karlcow/inline-code-with-visible-backtick.md @@ -0,0 +1 @@ +``We love `code` for everything`` \ No newline at end of file diff --git a/test/karlcow/inline-code.html b/test/karlcow/inline-code.html new file mode 100644 index 0000000..bc92165 --- /dev/null +++ b/test/karlcow/inline-code.html @@ -0,0 +1 @@ +

We love `code` for everything

\ No newline at end of file diff --git a/test/karlcow/inline-code.md b/test/karlcow/inline-code.md new file mode 100644 index 0000000..ecc9408 --- /dev/null +++ b/test/karlcow/inline-code.md @@ -0,0 +1 @@ +``We love `code` for everything`` \ No newline at end of file diff --git a/test/karlcow/line-break-2-spaces.html b/test/karlcow/line-break-2-spaces.html new file mode 100644 index 0000000..cb75f09 --- /dev/null +++ b/test/karlcow/line-break-2-spaces.html @@ -0,0 +1,2 @@ +

A first sentence
+and a line break.

\ No newline at end of file diff --git a/test/karlcow/line-break-2-spaces.md b/test/karlcow/line-break-2-spaces.md new file mode 100644 index 0000000..2b330a5 --- /dev/null +++ b/test/karlcow/line-break-2-spaces.md @@ -0,0 +1,2 @@ +A first sentence +and a line break. \ No newline at end of file diff --git a/test/karlcow/line-break-5-spaces.html b/test/karlcow/line-break-5-spaces.html new file mode 100644 index 0000000..cb75f09 --- /dev/null +++ b/test/karlcow/line-break-5-spaces.html @@ -0,0 +1,2 @@ +

A first sentence
+and a line break.

\ No newline at end of file diff --git a/test/karlcow/line-break-5-spaces.md b/test/karlcow/line-break-5-spaces.md new file mode 100644 index 0000000..f2e3e37 --- /dev/null +++ b/test/karlcow/line-break-5-spaces.md @@ -0,0 +1,2 @@ +A first sentence +and a line break. \ No newline at end of file diff --git a/test/karlcow/link-automatic.html b/test/karlcow/link-automatic.html new file mode 100644 index 0000000..604cbdc --- /dev/null +++ b/test/karlcow/link-automatic.html @@ -0,0 +1 @@ +

This is an automatic link http://www.w3.org/

\ No newline at end of file diff --git a/test/karlcow/link-automatic.md b/test/karlcow/link-automatic.md new file mode 100644 index 0000000..bf5987d --- /dev/null +++ b/test/karlcow/link-automatic.md @@ -0,0 +1 @@ +This is an automatic link \ No newline at end of file diff --git a/test/karlcow/link-bracket-paranthesis-title.html b/test/karlcow/link-bracket-paranthesis-title.html new file mode 100644 index 0000000..5e568ba --- /dev/null +++ b/test/karlcow/link-bracket-paranthesis-title.html @@ -0,0 +1 @@ +

W3C

\ No newline at end of file diff --git a/test/karlcow/link-bracket-paranthesis-title.md b/test/karlcow/link-bracket-paranthesis-title.md new file mode 100644 index 0000000..c61641c --- /dev/null +++ b/test/karlcow/link-bracket-paranthesis-title.md @@ -0,0 +1 @@ +[W3C](http://www.w3.org/ "Discover w3c") \ No newline at end of file diff --git a/test/karlcow/link-bracket-paranthesis.html b/test/karlcow/link-bracket-paranthesis.html new file mode 100644 index 0000000..ba65be8 --- /dev/null +++ b/test/karlcow/link-bracket-paranthesis.html @@ -0,0 +1 @@ +

W3C

\ No newline at end of file diff --git a/test/karlcow/link-bracket-paranthesis.md b/test/karlcow/link-bracket-paranthesis.md new file mode 100644 index 0000000..8fd5195 --- /dev/null +++ b/test/karlcow/link-bracket-paranthesis.md @@ -0,0 +1 @@ +[W3C](http://www.w3.org/) \ No newline at end of file diff --git a/test/karlcow/link-idref-angle-bracket.html b/test/karlcow/link-idref-angle-bracket.html new file mode 100644 index 0000000..dbee9a9 --- /dev/null +++ b/test/karlcow/link-idref-angle-bracket.html @@ -0,0 +1 @@ +

World Wide Web Consortium

\ No newline at end of file diff --git a/test/karlcow/link-idref-angle-bracket.md b/test/karlcow/link-idref-angle-bracket.md new file mode 100644 index 0000000..0f96c3c --- /dev/null +++ b/test/karlcow/link-idref-angle-bracket.md @@ -0,0 +1,3 @@ +[World Wide Web Consortium][w3c] + +[w3c]: \ No newline at end of file diff --git a/test/karlcow/link-idref-implicit-spaces.html b/test/karlcow/link-idref-implicit-spaces.html new file mode 100644 index 0000000..dbee9a9 --- /dev/null +++ b/test/karlcow/link-idref-implicit-spaces.html @@ -0,0 +1 @@ +

World Wide Web Consortium

\ No newline at end of file diff --git a/test/karlcow/link-idref-implicit-spaces.md b/test/karlcow/link-idref-implicit-spaces.md new file mode 100644 index 0000000..f49e289 --- /dev/null +++ b/test/karlcow/link-idref-implicit-spaces.md @@ -0,0 +1,3 @@ +[World Wide Web Consortium][] + +[World Wide Web Consortium]: http://www.w3.org/ \ No newline at end of file diff --git a/test/karlcow/link-idref-implicit.html b/test/karlcow/link-idref-implicit.html new file mode 100644 index 0000000..9ba2da6 --- /dev/null +++ b/test/karlcow/link-idref-implicit.html @@ -0,0 +1 @@ +

w3c

\ No newline at end of file diff --git a/test/karlcow/link-idref-implicit.md b/test/karlcow/link-idref-implicit.md new file mode 100644 index 0000000..65483c2 --- /dev/null +++ b/test/karlcow/link-idref-implicit.md @@ -0,0 +1,3 @@ +[w3c][] + +[w3c]: http://www.w3.org/ \ No newline at end of file diff --git a/test/karlcow/link-idref-space.html b/test/karlcow/link-idref-space.html new file mode 100644 index 0000000..dbee9a9 --- /dev/null +++ b/test/karlcow/link-idref-space.html @@ -0,0 +1 @@ +

World Wide Web Consortium

\ No newline at end of file diff --git a/test/karlcow/link-idref-space.md b/test/karlcow/link-idref-space.md new file mode 100644 index 0000000..9b13c6f --- /dev/null +++ b/test/karlcow/link-idref-space.md @@ -0,0 +1,3 @@ +[World Wide Web Consortium] [w3c] + +[w3c]: http://www.w3.org/ \ No newline at end of file diff --git a/test/karlcow/link-idref-title-next-line.html b/test/karlcow/link-idref-title-next-line.html new file mode 100644 index 0000000..9c2dda6 --- /dev/null +++ b/test/karlcow/link-idref-title-next-line.html @@ -0,0 +1 @@ +

World Wide Web Consortium

\ No newline at end of file diff --git a/test/karlcow/link-idref-title-next-line.md b/test/karlcow/link-idref-title-next-line.md new file mode 100644 index 0000000..310e80b --- /dev/null +++ b/test/karlcow/link-idref-title-next-line.md @@ -0,0 +1,4 @@ +[World Wide Web Consortium][w3c] + +[w3c]: http://www.w3.org/ + "Discover W3C" \ No newline at end of file diff --git a/test/karlcow/link-idref-title-paranthesis.html b/test/karlcow/link-idref-title-paranthesis.html new file mode 100644 index 0000000..f80f8ce --- /dev/null +++ b/test/karlcow/link-idref-title-paranthesis.html @@ -0,0 +1 @@ +

World Wide Web Consortium

\ No newline at end of file diff --git a/test/karlcow/link-idref-title-paranthesis.md b/test/karlcow/link-idref-title-paranthesis.md new file mode 100644 index 0000000..9bb11ed --- /dev/null +++ b/test/karlcow/link-idref-title-paranthesis.md @@ -0,0 +1,3 @@ +[World Wide Web Consortium][w3c] + +[w3c]: http://www.w3.org/ (Discover w3c) \ No newline at end of file diff --git a/test/karlcow/link-idref-title-single-quote.html b/test/karlcow/link-idref-title-single-quote.html new file mode 100644 index 0000000..f80f8ce --- /dev/null +++ b/test/karlcow/link-idref-title-single-quote.html @@ -0,0 +1 @@ +

World Wide Web Consortium

\ No newline at end of file diff --git a/test/karlcow/link-idref-title-single-quote.md b/test/karlcow/link-idref-title-single-quote.md new file mode 100644 index 0000000..a6a81b9 --- /dev/null +++ b/test/karlcow/link-idref-title-single-quote.md @@ -0,0 +1,3 @@ +[World Wide Web Consortium][w3c] + +[w3c]: http://www.w3.org/ 'Discover w3c' \ No newline at end of file diff --git a/test/karlcow/link-idref-title.html b/test/karlcow/link-idref-title.html new file mode 100644 index 0000000..f80f8ce --- /dev/null +++ b/test/karlcow/link-idref-title.html @@ -0,0 +1 @@ +

World Wide Web Consortium

\ No newline at end of file diff --git a/test/karlcow/link-idref-title.md b/test/karlcow/link-idref-title.md new file mode 100644 index 0000000..bee4294 --- /dev/null +++ b/test/karlcow/link-idref-title.md @@ -0,0 +1,3 @@ +[World Wide Web Consortium][w3c] + +[w3c]: http://www.w3.org/ "Discover w3c" \ No newline at end of file diff --git a/test/karlcow/link-idref.html b/test/karlcow/link-idref.html new file mode 100644 index 0000000..dbee9a9 --- /dev/null +++ b/test/karlcow/link-idref.html @@ -0,0 +1 @@ +

World Wide Web Consortium

\ No newline at end of file diff --git a/test/karlcow/link-idref.md b/test/karlcow/link-idref.md new file mode 100644 index 0000000..2d45629 --- /dev/null +++ b/test/karlcow/link-idref.md @@ -0,0 +1,3 @@ +[World Wide Web Consortium][w3c] + +[w3c]: http://www.w3.org/ \ No newline at end of file diff --git a/test/karlcow/list-blockquote.html b/test/karlcow/list-blockquote.html new file mode 100644 index 0000000..1d99d17 --- /dev/null +++ b/test/karlcow/list-blockquote.html @@ -0,0 +1,7 @@ +
    +
  • a list containing a blockquote

    + +
    +

    this the blockquote in the list

    +
  • +
diff --git a/test/karlcow/list-blockquote.md b/test/karlcow/list-blockquote.md new file mode 100644 index 0000000..37c0762 --- /dev/null +++ b/test/karlcow/list-blockquote.md @@ -0,0 +1,3 @@ +* a list containing a blockquote + + > this the blockquote in the list \ No newline at end of file diff --git a/test/karlcow/list-code.html b/test/karlcow/list-code.html new file mode 100644 index 0000000..53b3c22 --- /dev/null +++ b/test/karlcow/list-code.html @@ -0,0 +1,7 @@ +
    +
  • a list containing a block of code

    + +
    10 PRINT HELLO INFINITE
    +20 GOTO 10
    +
  • +
\ No newline at end of file diff --git a/test/karlcow/list-code.md b/test/karlcow/list-code.md new file mode 100644 index 0000000..ed774d2 --- /dev/null +++ b/test/karlcow/list-code.md @@ -0,0 +1,4 @@ +* a list containing a block of code + + 10 PRINT HELLO INFINITE + 20 GOTO 10 \ No newline at end of file diff --git a/test/karlcow/list-multiparagraphs-tab.html b/test/karlcow/list-multiparagraphs-tab.html new file mode 100644 index 0000000..a90759e --- /dev/null +++ b/test/karlcow/list-multiparagraphs-tab.html @@ -0,0 +1,10 @@ +
    +
  • This is a list item with two paragraphs. Lorem ipsum dolor +sit amet, consectetuer adipiscing elit. Aliquam hendrerit +mi posuere lectus.

    + +

    Vestibulum enim wisi, viverra nec, fringilla in, laoreet +vitae, risus. Donec sit amet nisl. Aliquam semper ipsum +sit amet velit.

  • +
  • Suspendisse id sem consectetuer libero luctus adipiscing.

  • +
\ No newline at end of file diff --git a/test/karlcow/list-multiparagraphs-tab.md b/test/karlcow/list-multiparagraphs-tab.md new file mode 100644 index 0000000..8c50d42 --- /dev/null +++ b/test/karlcow/list-multiparagraphs-tab.md @@ -0,0 +1,9 @@ +* This is a list item with two paragraphs. Lorem ipsum dolor + sit amet, consectetuer adipiscing elit. Aliquam hendrerit + mi posuere lectus. + + Vestibulum enim wisi, viverra nec, fringilla in, laoreet + vitae, risus. Donec sit amet nisl. Aliquam semper ipsum + sit amet velit. + +* Suspendisse id sem consectetuer libero luctus adipiscing. \ No newline at end of file diff --git a/test/karlcow/list-multiparagraphs.html b/test/karlcow/list-multiparagraphs.html new file mode 100644 index 0000000..a90759e --- /dev/null +++ b/test/karlcow/list-multiparagraphs.html @@ -0,0 +1,10 @@ +
    +
  • This is a list item with two paragraphs. Lorem ipsum dolor +sit amet, consectetuer adipiscing elit. Aliquam hendrerit +mi posuere lectus.

    + +

    Vestibulum enim wisi, viverra nec, fringilla in, laoreet +vitae, risus. Donec sit amet nisl. Aliquam semper ipsum +sit amet velit.

  • +
  • Suspendisse id sem consectetuer libero luctus adipiscing.

  • +
\ No newline at end of file diff --git a/test/karlcow/list-multiparagraphs.md b/test/karlcow/list-multiparagraphs.md new file mode 100644 index 0000000..58d4820 --- /dev/null +++ b/test/karlcow/list-multiparagraphs.md @@ -0,0 +1,9 @@ +* This is a list item with two paragraphs. Lorem ipsum dolor + sit amet, consectetuer adipiscing elit. Aliquam hendrerit + mi posuere lectus. + + Vestibulum enim wisi, viverra nec, fringilla in, laoreet + vitae, risus. Donec sit amet nisl. Aliquam semper ipsum + sit amet velit. + +* Suspendisse id sem consectetuer libero luctus adipiscing. \ No newline at end of file diff --git a/test/karlcow/ordered-list-escaped.html b/test/karlcow/ordered-list-escaped.html new file mode 100644 index 0000000..f6c477d --- /dev/null +++ b/test/karlcow/ordered-list-escaped.html @@ -0,0 +1 @@ +

1. ordered list escape

\ No newline at end of file diff --git a/test/karlcow/ordered-list-escaped.md b/test/karlcow/ordered-list-escaped.md new file mode 100644 index 0000000..ec71a7e --- /dev/null +++ b/test/karlcow/ordered-list-escaped.md @@ -0,0 +1 @@ +1\. ordered list escape \ No newline at end of file diff --git a/test/karlcow/ordered-list-inner-par-list.html b/test/karlcow/ordered-list-inner-par-list.html new file mode 100644 index 0000000..3e7796c --- /dev/null +++ b/test/karlcow/ordered-list-inner-par-list.html @@ -0,0 +1,9 @@ +
    +
  1. +

    1

    +
      +
    • inner par list
    • +
    +
  2. +
  3. 2

  4. +
diff --git a/test/karlcow/ordered-list-inner-par-list.md b/test/karlcow/ordered-list-inner-par-list.md new file mode 100644 index 0000000..05c6490 --- /dev/null +++ b/test/karlcow/ordered-list-inner-par-list.md @@ -0,0 +1,5 @@ +1. 1 + + - inner par list + +2. 2 diff --git a/test/karlcow/ordered-list-items-random-number.html b/test/karlcow/ordered-list-items-random-number.html new file mode 100644 index 0000000..6113b3a --- /dev/null +++ b/test/karlcow/ordered-list-items-random-number.html @@ -0,0 +1,5 @@ +
    +
  1. list item 1
  2. +
  3. list item 2
  4. +
  5. list item 3
  6. +
\ No newline at end of file diff --git a/test/karlcow/ordered-list-items-random-number.md b/test/karlcow/ordered-list-items-random-number.md new file mode 100644 index 0000000..8f4d9bb --- /dev/null +++ b/test/karlcow/ordered-list-items-random-number.md @@ -0,0 +1,3 @@ +1. list item 1 +8. list item 2 +1. list item 3 \ No newline at end of file diff --git a/test/karlcow/ordered-list-items.html b/test/karlcow/ordered-list-items.html new file mode 100644 index 0000000..6113b3a --- /dev/null +++ b/test/karlcow/ordered-list-items.html @@ -0,0 +1,5 @@ +
    +
  1. list item 1
  2. +
  3. list item 2
  4. +
  5. list item 3
  6. +
\ No newline at end of file diff --git a/test/karlcow/ordered-list-items.md b/test/karlcow/ordered-list-items.md new file mode 100644 index 0000000..6ba5e88 --- /dev/null +++ b/test/karlcow/ordered-list-items.md @@ -0,0 +1,3 @@ +1. list item 1 +2. list item 2 +3. list item 3 \ No newline at end of file diff --git a/test/karlcow/paragraph-hard-return.html b/test/karlcow/paragraph-hard-return.html new file mode 100644 index 0000000..7915e29 --- /dev/null +++ b/test/karlcow/paragraph-hard-return.html @@ -0,0 +1,3 @@ +

This is a paragraph +on multiple lines +with hard return.

\ No newline at end of file diff --git a/test/karlcow/paragraph-hard-return.md b/test/karlcow/paragraph-hard-return.md new file mode 100644 index 0000000..3e4dfbd --- /dev/null +++ b/test/karlcow/paragraph-hard-return.md @@ -0,0 +1,3 @@ +This is a paragraph +on multiple lines +with hard return. \ No newline at end of file diff --git a/test/karlcow/paragraph-line.html b/test/karlcow/paragraph-line.html new file mode 100644 index 0000000..5fc0e44 --- /dev/null +++ b/test/karlcow/paragraph-line.html @@ -0,0 +1 @@ +

This a very long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long paragraph on 1 line.

\ No newline at end of file diff --git a/test/karlcow/paragraph-line.md b/test/karlcow/paragraph-line.md new file mode 100644 index 0000000..edcdead --- /dev/null +++ b/test/karlcow/paragraph-line.md @@ -0,0 +1 @@ +This a very long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long paragraph on 1 line. \ No newline at end of file diff --git a/test/karlcow/paragraph-trailing-leading-spaces.html b/test/karlcow/paragraph-trailing-leading-spaces.html new file mode 100644 index 0000000..d99afcd --- /dev/null +++ b/test/karlcow/paragraph-trailing-leading-spaces.html @@ -0,0 +1 @@ +

This is a paragraph with a trailing and leading space.

\ No newline at end of file diff --git a/test/karlcow/paragraph-trailing-leading-spaces.md b/test/karlcow/paragraph-trailing-leading-spaces.md new file mode 100644 index 0000000..3b3353d --- /dev/null +++ b/test/karlcow/paragraph-trailing-leading-spaces.md @@ -0,0 +1 @@ + This is a paragraph with a trailing and leading space. \ No newline at end of file diff --git a/test/karlcow/paragraph-trailing-tab.html b/test/karlcow/paragraph-trailing-tab.html new file mode 100644 index 0000000..f4bcd7c --- /dev/null +++ b/test/karlcow/paragraph-trailing-tab.html @@ -0,0 +1 @@ +

This is a paragraph with 1 trailing tab.

\ No newline at end of file diff --git a/test/karlcow/paragraph-trailing-tab.md b/test/karlcow/paragraph-trailing-tab.md new file mode 100644 index 0000000..7b345c2 --- /dev/null +++ b/test/karlcow/paragraph-trailing-tab.md @@ -0,0 +1 @@ +This is a paragraph with 1 trailing tab. \ No newline at end of file diff --git a/test/karlcow/paragraphs-2-leading-spaces.html b/test/karlcow/paragraphs-2-leading-spaces.html new file mode 100644 index 0000000..bd08e95 --- /dev/null +++ b/test/karlcow/paragraphs-2-leading-spaces.html @@ -0,0 +1 @@ +

This is a paragraph with 2 leading spaces.

\ No newline at end of file diff --git a/test/karlcow/paragraphs-2-leading-spaces.md b/test/karlcow/paragraphs-2-leading-spaces.md new file mode 100644 index 0000000..1a618de --- /dev/null +++ b/test/karlcow/paragraphs-2-leading-spaces.md @@ -0,0 +1 @@ + This is a paragraph with 2 leading spaces. \ No newline at end of file diff --git a/test/karlcow/paragraphs-3-leading-spaces.html b/test/karlcow/paragraphs-3-leading-spaces.html new file mode 100644 index 0000000..9c91f46 --- /dev/null +++ b/test/karlcow/paragraphs-3-leading-spaces.html @@ -0,0 +1 @@ +

This is a paragraph with 3 leading spaces.

\ No newline at end of file diff --git a/test/karlcow/paragraphs-3-leading-spaces.md b/test/karlcow/paragraphs-3-leading-spaces.md new file mode 100644 index 0000000..a38428f --- /dev/null +++ b/test/karlcow/paragraphs-3-leading-spaces.md @@ -0,0 +1 @@ + This is a paragraph with 3 leading spaces. \ No newline at end of file diff --git a/test/karlcow/paragraphs-leading-space.html b/test/karlcow/paragraphs-leading-space.html new file mode 100644 index 0000000..917426d --- /dev/null +++ b/test/karlcow/paragraphs-leading-space.html @@ -0,0 +1 @@ +

This is a paragraph with 1 leading space.

\ No newline at end of file diff --git a/test/karlcow/paragraphs-leading-space.md b/test/karlcow/paragraphs-leading-space.md new file mode 100644 index 0000000..0d95f8b --- /dev/null +++ b/test/karlcow/paragraphs-leading-space.md @@ -0,0 +1 @@ + This is a paragraph with 1 leading space. \ No newline at end of file diff --git a/test/karlcow/paragraphs-trailing-spaces.html b/test/karlcow/paragraphs-trailing-spaces.html new file mode 100644 index 0000000..7636c46 --- /dev/null +++ b/test/karlcow/paragraphs-trailing-spaces.html @@ -0,0 +1 @@ +

This is a paragraph with a trailing space.

\ No newline at end of file diff --git a/test/karlcow/paragraphs-trailing-spaces.md b/test/karlcow/paragraphs-trailing-spaces.md new file mode 100644 index 0000000..6809b73 --- /dev/null +++ b/test/karlcow/paragraphs-trailing-spaces.md @@ -0,0 +1 @@ +This is a paragraph with a trailing space. \ No newline at end of file diff --git a/test/karlcow/strong-middle-word.html b/test/karlcow/strong-middle-word.html new file mode 100644 index 0000000..4550f32 --- /dev/null +++ b/test/karlcow/strong-middle-word.html @@ -0,0 +1 @@ +

asterisks

\ No newline at end of file diff --git a/test/karlcow/strong-middle-word.md b/test/karlcow/strong-middle-word.md new file mode 100644 index 0000000..44651a4 --- /dev/null +++ b/test/karlcow/strong-middle-word.md @@ -0,0 +1 @@ +as**te**risks \ No newline at end of file diff --git a/test/karlcow/strong-star.html b/test/karlcow/strong-star.html new file mode 100644 index 0000000..3181aea --- /dev/null +++ b/test/karlcow/strong-star.html @@ -0,0 +1 @@ +

double asterisks

\ No newline at end of file diff --git a/test/karlcow/strong-star.md b/test/karlcow/strong-star.md new file mode 100644 index 0000000..566125c --- /dev/null +++ b/test/karlcow/strong-star.md @@ -0,0 +1 @@ +**double asterisks** \ No newline at end of file diff --git a/test/karlcow/strong-underscore.html b/test/karlcow/strong-underscore.html new file mode 100644 index 0000000..ef613bb --- /dev/null +++ b/test/karlcow/strong-underscore.html @@ -0,0 +1 @@ +

double underscores

\ No newline at end of file diff --git a/test/karlcow/strong-underscore.md b/test/karlcow/strong-underscore.md new file mode 100644 index 0000000..69cc179 --- /dev/null +++ b/test/karlcow/strong-underscore.md @@ -0,0 +1 @@ +__double underscores__ \ No newline at end of file diff --git a/test/karlcow/unordered-list-items-asterisk.html b/test/karlcow/unordered-list-items-asterisk.html new file mode 100644 index 0000000..a5d2dfc --- /dev/null +++ b/test/karlcow/unordered-list-items-asterisk.html @@ -0,0 +1,5 @@ +
    +
  • list item 1
  • +
  • list item 2
  • +
  • list item 3
  • +
\ No newline at end of file diff --git a/test/karlcow/unordered-list-items-asterisk.md b/test/karlcow/unordered-list-items-asterisk.md new file mode 100644 index 0000000..01e3e61 --- /dev/null +++ b/test/karlcow/unordered-list-items-asterisk.md @@ -0,0 +1,3 @@ +* list item 1 +* list item 2 +* list item 3 diff --git a/test/karlcow/unordered-list-items-dashsign.html b/test/karlcow/unordered-list-items-dashsign.html new file mode 100644 index 0000000..a5d2dfc --- /dev/null +++ b/test/karlcow/unordered-list-items-dashsign.html @@ -0,0 +1,5 @@ +
    +
  • list item 1
  • +
  • list item 2
  • +
  • list item 3
  • +
\ No newline at end of file diff --git a/test/karlcow/unordered-list-items-dashsign.md b/test/karlcow/unordered-list-items-dashsign.md new file mode 100644 index 0000000..bf057f8 --- /dev/null +++ b/test/karlcow/unordered-list-items-dashsign.md @@ -0,0 +1,3 @@ +- list item 1 +- list item 2 +- list item 3 \ No newline at end of file diff --git a/test/karlcow/unordered-list-items-leading-1space.html b/test/karlcow/unordered-list-items-leading-1space.html new file mode 100644 index 0000000..99cec2f --- /dev/null +++ b/test/karlcow/unordered-list-items-leading-1space.html @@ -0,0 +1,5 @@ +
    +
  • list item 1
  • +
  • list item 2
  • +
  • list item 3
  • +
diff --git a/test/karlcow/unordered-list-items-leading-1space.md b/test/karlcow/unordered-list-items-leading-1space.md new file mode 100644 index 0000000..ec95bb7 --- /dev/null +++ b/test/karlcow/unordered-list-items-leading-1space.md @@ -0,0 +1,3 @@ + * list item 1 + * list item 2 + * list item 3 \ No newline at end of file diff --git a/test/karlcow/unordered-list-items-leading-2spaces.html b/test/karlcow/unordered-list-items-leading-2spaces.html new file mode 100644 index 0000000..a5d2dfc --- /dev/null +++ b/test/karlcow/unordered-list-items-leading-2spaces.html @@ -0,0 +1,5 @@ +
    +
  • list item 1
  • +
  • list item 2
  • +
  • list item 3
  • +
\ No newline at end of file diff --git a/test/karlcow/unordered-list-items-leading-2spaces.md b/test/karlcow/unordered-list-items-leading-2spaces.md new file mode 100644 index 0000000..0d724cd --- /dev/null +++ b/test/karlcow/unordered-list-items-leading-2spaces.md @@ -0,0 +1,3 @@ + * list item 1 + * list item 2 + * list item 3 \ No newline at end of file diff --git a/test/karlcow/unordered-list-items-leading-3spaces.html b/test/karlcow/unordered-list-items-leading-3spaces.html new file mode 100644 index 0000000..a5d2dfc --- /dev/null +++ b/test/karlcow/unordered-list-items-leading-3spaces.html @@ -0,0 +1,5 @@ +
    +
  • list item 1
  • +
  • list item 2
  • +
  • list item 3
  • +
\ No newline at end of file diff --git a/test/karlcow/unordered-list-items-leading-3spaces.md b/test/karlcow/unordered-list-items-leading-3spaces.md new file mode 100644 index 0000000..c858766 --- /dev/null +++ b/test/karlcow/unordered-list-items-leading-3spaces.md @@ -0,0 +1,3 @@ + * list item 1 + * list item 2 + * list item 3 \ No newline at end of file diff --git a/test/karlcow/unordered-list-items-plussign.html b/test/karlcow/unordered-list-items-plussign.html new file mode 100644 index 0000000..a5d2dfc --- /dev/null +++ b/test/karlcow/unordered-list-items-plussign.html @@ -0,0 +1,5 @@ +
    +
  • list item 1
  • +
  • list item 2
  • +
  • list item 3
  • +
\ No newline at end of file diff --git a/test/karlcow/unordered-list-items-plussign.md b/test/karlcow/unordered-list-items-plussign.md new file mode 100644 index 0000000..c91561e --- /dev/null +++ b/test/karlcow/unordered-list-items-plussign.md @@ -0,0 +1,3 @@ ++ list item 1 ++ list item 2 ++ list item 3 \ No newline at end of file diff --git a/test/karlcow/unordered-list-paragraphs.html b/test/karlcow/unordered-list-paragraphs.html new file mode 100644 index 0000000..e78215e --- /dev/null +++ b/test/karlcow/unordered-list-paragraphs.html @@ -0,0 +1,4 @@ +
    +
  • list item in paragraph

  • +
  • another list item in paragraph

  • +
\ No newline at end of file diff --git a/test/karlcow/unordered-list-paragraphs.md b/test/karlcow/unordered-list-paragraphs.md new file mode 100644 index 0000000..c94b4db --- /dev/null +++ b/test/karlcow/unordered-list-paragraphs.md @@ -0,0 +1,3 @@ +* list item in paragraph + +* another list item in paragraph \ No newline at end of file diff --git a/test/karlcow/unordered-list-unindented-content.html b/test/karlcow/unordered-list-unindented-content.html new file mode 100644 index 0000000..44d07b8 --- /dev/null +++ b/test/karlcow/unordered-list-unindented-content.html @@ -0,0 +1,4 @@ +
    +
  • This a very long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long paragraph in a list.
  • +
  • and yet another long long long long long long long long long long long long long long long long long long long long long long line.
  • +
\ No newline at end of file diff --git a/test/karlcow/unordered-list-unindented-content.md b/test/karlcow/unordered-list-unindented-content.md new file mode 100644 index 0000000..f564c02 --- /dev/null +++ b/test/karlcow/unordered-list-unindented-content.md @@ -0,0 +1,2 @@ +* This a very long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long paragraph in a list. +* and yet another long long long long long long long long long long long long long long long long long long long long long long line. \ No newline at end of file diff --git a/test/karlcow/unordered-list-with-indented-content.html b/test/karlcow/unordered-list-with-indented-content.html new file mode 100644 index 0000000..003d8ce --- /dev/null +++ b/test/karlcow/unordered-list-with-indented-content.html @@ -0,0 +1,7 @@ +
    +
  • This is a list item +with the content on +multiline and indented.
  • +
  • And this another list item +with the same principle.
  • +
\ No newline at end of file diff --git a/test/karlcow/unordered-list-with-indented-content.md b/test/karlcow/unordered-list-with-indented-content.md new file mode 100644 index 0000000..5fcc8e0 --- /dev/null +++ b/test/karlcow/unordered-list-with-indented-content.md @@ -0,0 +1,5 @@ +* This is a list item + with the content on + multiline and indented. +* And this another list item + with the same principle. \ No newline at end of file diff --git a/test/node/showdown.Converter.makeHtml.js b/test/node/showdown.Converter.makeHtml.js index f687753..5cfabf9 100644 --- a/test/node/showdown.Converter.makeHtml.js +++ b/test/node/showdown.Converter.makeHtml.js @@ -8,14 +8,7 @@ describe('showdown.Converter', function () { require('source-map-support').install(); require('chai').should(); - var fs = require('fs'), - showdown = require('../../dist/showdown.js'), - cases = fs.readdirSync('test/cases/') - .filter(filter()) - .map(map('test/cases/')), - issues = fs.readdirSync('test/issues/') - .filter(filter()) - .map(map('test/issues/')); + var showdown = require('../../dist/showdown.js'); describe('Converter.options extensions', function () { showdown.extensions.testext = function () { @@ -28,7 +21,7 @@ describe('showdown.Converter', function () { }]; }; var runCount, - converter = new showdown.Converter({extensions: ['testext']}); + converter = new showdown.Converter({extensions: ['testext']}); it('output extensions should run once', function () { runCount = 0; @@ -37,82 +30,6 @@ describe('showdown.Converter', function () { }); }); - function filter() { - return function (file) { - var ext = file.slice(-3); - return (ext === '.md'); - }; - } - - function map(dir) { - return function (file) { - var name = file.replace('.md', ''), - htmlPath = dir + name + '.html', - html = fs.readFileSync(htmlPath, 'utf8'), - mdPath = dir + name + '.md', - md = fs.readFileSync(mdPath, 'utf8'); - - return { - name: name, - input: md, - expected: html - }; - }; - } - - function assertion(testCase, converter) { - return function () { - testCase.actual = converter.makeHtml(testCase.input); - testCase = normalize(testCase); - - // Compare - testCase.actual.should.equal(testCase.expected); - }; - } - - //Normalize input/output - function normalize(testCase) { - - // Normalize line returns - testCase.expected = testCase.expected.replace(/\r/g, ''); - testCase.actual = testCase.actual.replace(/\r/g, ''); - - // Ignore all leading/trailing whitespace - testCase.expected = testCase.expected.split('\n').map(function (x) { - return x.trim(); - }).join('\n'); - testCase.actual = testCase.actual.split('\n').map(function (x) { - return x.trim(); - }).join('\n'); - - // Remove extra lines - testCase.expected = testCase.expected.trim(); - - // Convert whitespace to a visible character so that it shows up on error reports - testCase.expected = testCase.expected.replace(/ /g, '·'); - testCase.expected = testCase.expected.replace(/\n/g, '•\n'); - testCase.actual = testCase.actual.replace(/ /g, '·'); - testCase.actual = testCase.actual.replace(/\n/g, '•\n'); - - return testCase; - - } - - //Tests - describe('makeHtml() output testcase', function () { - var converter = new showdown.Converter(); - for (var i = 0; i < cases.length; ++i) { - it(cases[i].name, assertion(cases[i], converter)); - } - }); - - describe('makeHtml() issues testcase', function () { - var converter = new showdown.Converter(); - for (var i = 0; i < issues.length; ++i) { - it(issues[i].name, assertion(issues[i], converter)); - } - }); - describe('makeHtml() with option omitExtraWLInCodeBlocks', function () { var converter = new showdown.Converter({omitExtraWLInCodeBlocks: true}), text = 'var foo = bar;', diff --git a/test/node/testsuite.issues.js b/test/node/testsuite.issues.js new file mode 100644 index 0000000..7623dd6 --- /dev/null +++ b/test/node/testsuite.issues.js @@ -0,0 +1,15 @@ +/** + * Created by Estevao on 08-06-2015. + */ +var showdown = require('../../dist/showdown.js'), + converter = new showdown.Converter(), + bootstrap = require('../bootstrap.js'), + assertion = bootstrap.assertion, + testsuite = bootstrap.getTestSuite('test/issues/'); + +//MD-Testsuite (borrowed from karlcow/markdown-testsuite) +describe('makeHtml() issues testsuite', function () { + for (var i = 0; i < testsuite.length; ++i) { + it(testsuite[i].name, assertion(testsuite[i], converter)); + } +}); diff --git a/test/node/testsuite.karlcow.js b/test/node/testsuite.karlcow.js new file mode 100644 index 0000000..22f4cb6 --- /dev/null +++ b/test/node/testsuite.karlcow.js @@ -0,0 +1,12 @@ +var showdown = require('../../dist/showdown.js'), + converter = new showdown.Converter({noHeaderId: true}), + bootstrap = require('../bootstrap.js'), + assertion = bootstrap.assertion, + testsuite = bootstrap.getTestSuite('test/karlcow/'); + +//MD-Testsuite (borrowed from karlcow/markdown-testsuite) +describe('makeHtml() karlcow testsuite', function () { + for (var i = 0; i < testsuite.length; ++i) { + it(testsuite[i].name, assertion(testsuite[i], converter)); + } +}); diff --git a/test/node/testsuite.standard.js b/test/node/testsuite.standard.js new file mode 100644 index 0000000..2648d3c --- /dev/null +++ b/test/node/testsuite.standard.js @@ -0,0 +1,12 @@ +var showdown = require('../../dist/showdown.js'), + converter = new showdown.Converter(), + bootstrap = require('../bootstrap.js'), + assertion = bootstrap.assertion, + testsuite = bootstrap.getTestSuite('test/cases/'); + +//MD-Testsuite (borrowed from karlcow/markdown-testsuite) +describe('makeHtml() standard testsuite', function () { + for (var i = 0; i < testsuite.length; ++i) { + it(testsuite[i].name, assertion(testsuite[i], converter)); + } +});