From de98e0b232509d5f40c135d540a70e415272ff85 Mon Sep 17 00:00:00 2001 From: Florian Dold Date: Wed, 3 May 2017 15:35:00 +0200 Subject: node_modules --- node_modules/domhandler/test/cases/01-basic.json | 41 +++++++++++++++ .../domhandler/test/cases/02-single_tag_1.json | 21 ++++++++ .../domhandler/test/cases/03-single_tag_2.json | 21 ++++++++ .../test/cases/04-unescaped_in_script.json | 27 ++++++++++ .../domhandler/test/cases/05-tags_in_comment.json | 18 +++++++ .../test/cases/06-comment_in_script.json | 18 +++++++ .../test/cases/07-unescaped_in_style.json | 20 ++++++++ .../test/cases/08-extra_spaces_in_tag.json | 20 ++++++++ .../domhandler/test/cases/09-unquoted_attrib.json | 20 ++++++++ .../test/cases/10-singular_attribute.json | 15 ++++++ .../test/cases/11-text_outside_tags.json | 20 ++++++++ .../domhandler/test/cases/12-text_only.json | 11 ++++ .../domhandler/test/cases/13-comment_in_text.json | 19 +++++++ .../test/cases/14-comment_in_text_in_script.json | 18 +++++++ .../domhandler/test/cases/15-non-verbose.json | 22 ++++++++ .../test/cases/16-normalize_whitespace.json | 47 +++++++++++++++++ .../domhandler/test/cases/17-xml_namespace.json | 18 +++++++ .../test/cases/18-enforce_empty_tags.json | 16 ++++++ .../test/cases/19-ignore_empty_tags.json | 20 ++++++++ .../test/cases/20-template_script_tags.json | 20 ++++++++ .../test/cases/21-conditional_comments.json | 15 ++++++ .../domhandler/test/cases/22-lowercase_tags.json | 41 +++++++++++++++ node_modules/domhandler/test/tests.js | 59 ++++++++++++++++++++++ 23 files changed, 547 insertions(+) create mode 100644 node_modules/domhandler/test/cases/01-basic.json create mode 100644 node_modules/domhandler/test/cases/02-single_tag_1.json create mode 100644 node_modules/domhandler/test/cases/03-single_tag_2.json create mode 100644 node_modules/domhandler/test/cases/04-unescaped_in_script.json create mode 100644 node_modules/domhandler/test/cases/05-tags_in_comment.json create mode 100644 node_modules/domhandler/test/cases/06-comment_in_script.json create mode 100644 node_modules/domhandler/test/cases/07-unescaped_in_style.json create mode 100644 node_modules/domhandler/test/cases/08-extra_spaces_in_tag.json create mode 100644 node_modules/domhandler/test/cases/09-unquoted_attrib.json create mode 100644 node_modules/domhandler/test/cases/10-singular_attribute.json create mode 100644 node_modules/domhandler/test/cases/11-text_outside_tags.json create mode 100644 node_modules/domhandler/test/cases/12-text_only.json create mode 100644 node_modules/domhandler/test/cases/13-comment_in_text.json create mode 100644 node_modules/domhandler/test/cases/14-comment_in_text_in_script.json create mode 100644 node_modules/domhandler/test/cases/15-non-verbose.json create mode 100644 node_modules/domhandler/test/cases/16-normalize_whitespace.json create mode 100644 node_modules/domhandler/test/cases/17-xml_namespace.json create mode 100644 node_modules/domhandler/test/cases/18-enforce_empty_tags.json create mode 100644 node_modules/domhandler/test/cases/19-ignore_empty_tags.json create mode 100644 node_modules/domhandler/test/cases/20-template_script_tags.json create mode 100644 node_modules/domhandler/test/cases/21-conditional_comments.json create mode 100644 node_modules/domhandler/test/cases/22-lowercase_tags.json create mode 100644 node_modules/domhandler/test/tests.js (limited to 'node_modules/domhandler/test') diff --git a/node_modules/domhandler/test/cases/01-basic.json b/node_modules/domhandler/test/cases/01-basic.json new file mode 100644 index 000000000..e7952ec9e --- /dev/null +++ b/node_modules/domhandler/test/cases/01-basic.json @@ -0,0 +1,41 @@ +{ + "name": "Basic test", + "options": {}, + "html": "The TitleHello world", + "expected": [ + { + "name": "!doctype", + "data": "!DOCTYPE html", + "type": "directive" + }, + { + "type": "tag", + "name": "html", + "attribs": {}, + "children": [ + { + "type": "tag", + "name": "title", + "attribs": {}, + "children": [ + { + "data": "The Title", + "type": "text" + } + ] + }, + { + "type": "tag", + "name": "body", + "attribs": {}, + "children": [ + { + "data": "Hello world", + "type": "text" + } + ] + } + ] + } + ] +} \ No newline at end of file diff --git a/node_modules/domhandler/test/cases/02-single_tag_1.json b/node_modules/domhandler/test/cases/02-single_tag_1.json new file mode 100644 index 000000000..51ff84577 --- /dev/null +++ b/node_modules/domhandler/test/cases/02-single_tag_1.json @@ -0,0 +1,21 @@ +{ + "name": "Single Tag 1", + "options": {}, + "html": "
text
", + "expected": [ + { + "type": "tag", + "name": "br", + "attribs": {} + }, + { + "data": "text", + "type": "text" + }, + { + "type": "tag", + "name": "br", + "attribs": {} + } + ] +} \ No newline at end of file diff --git a/node_modules/domhandler/test/cases/03-single_tag_2.json b/node_modules/domhandler/test/cases/03-single_tag_2.json new file mode 100644 index 000000000..1c56dc9d9 --- /dev/null +++ b/node_modules/domhandler/test/cases/03-single_tag_2.json @@ -0,0 +1,21 @@ +{ + "name": "Single Tag 2", + "options": {}, + "html": "
text
", + "expected": [ + { + "type": "tag", + "name": "br", + "attribs": {} + }, + { + "data": "text", + "type": "text" + }, + { + "type": "tag", + "name": "br", + "attribs": {} + } + ] +} \ No newline at end of file diff --git a/node_modules/domhandler/test/cases/04-unescaped_in_script.json b/node_modules/domhandler/test/cases/04-unescaped_in_script.json new file mode 100644 index 000000000..f31f5fad6 --- /dev/null +++ b/node_modules/domhandler/test/cases/04-unescaped_in_script.json @@ -0,0 +1,27 @@ +{ + "name": "Unescaped chars in script", + "options": {}, + "html": "", + "expected": [ + { + "type": "tag", + "name": "head", + "attribs": {}, + "children": [ + { + "type": "script", + "name": "script", + "attribs": { + "language": "Javascript" + }, + "children": [ + { + "data": "var foo = \"\"; alert(2 > foo); var baz = 10 << 2; var zip = 10 >> 1; var yap = \"<<>>>><<\";", + "type": "text" + } + ] + } + ] + } + ] +} \ No newline at end of file diff --git a/node_modules/domhandler/test/cases/05-tags_in_comment.json b/node_modules/domhandler/test/cases/05-tags_in_comment.json new file mode 100644 index 000000000..2d22d9e1d --- /dev/null +++ b/node_modules/domhandler/test/cases/05-tags_in_comment.json @@ -0,0 +1,18 @@ +{ + "name": "Special char in comment", + "options": {}, + "html": "", + "expected": [ + { + "type": "tag", + "name": "head", + "attribs": {}, + "children": [ + { + "data": " commented out tags Test", + "type": "comment" + } + ] + } + ] +} \ No newline at end of file diff --git a/node_modules/domhandler/test/cases/06-comment_in_script.json b/node_modules/domhandler/test/cases/06-comment_in_script.json new file mode 100644 index 000000000..9a21cdabf --- /dev/null +++ b/node_modules/domhandler/test/cases/06-comment_in_script.json @@ -0,0 +1,18 @@ +{ + "name": "Script source in comment", + "options": {}, + "html": "", + "expected": [ + { + "type": "script", + "name": "script", + "attribs": {}, + "children": [ + { + "data": "", + "type": "text" + } + ] + } + ] +} \ No newline at end of file diff --git a/node_modules/domhandler/test/cases/07-unescaped_in_style.json b/node_modules/domhandler/test/cases/07-unescaped_in_style.json new file mode 100644 index 000000000..77438fdc1 --- /dev/null +++ b/node_modules/domhandler/test/cases/07-unescaped_in_style.json @@ -0,0 +1,20 @@ +{ + "name": "Unescaped chars in style", + "options": {}, + "html": "", + "expected": [ + { + "type": "style", + "name": "style", + "attribs": { + "type": "text/css" + }, + "children": [ + { + "data": "\n body > p\n\t{ font-weight: bold; }", + "type": "text" + } + ] + } + ] +} \ No newline at end of file diff --git a/node_modules/domhandler/test/cases/08-extra_spaces_in_tag.json b/node_modules/domhandler/test/cases/08-extra_spaces_in_tag.json new file mode 100644 index 000000000..5c2492e22 --- /dev/null +++ b/node_modules/domhandler/test/cases/08-extra_spaces_in_tag.json @@ -0,0 +1,20 @@ +{ + "name": "Extra spaces in tag", + "options": {}, + "html": "the text", + "expected": [ + { + "type": "tag", + "name": "font", + "attribs": { + "size": "14" + }, + "children": [ + { + "data": "the text", + "type": "text" + } + ] + } + ] +} \ No newline at end of file diff --git a/node_modules/domhandler/test/cases/09-unquoted_attrib.json b/node_modules/domhandler/test/cases/09-unquoted_attrib.json new file mode 100644 index 000000000..543cceeed --- /dev/null +++ b/node_modules/domhandler/test/cases/09-unquoted_attrib.json @@ -0,0 +1,20 @@ +{ + "name": "Unquoted attributes", + "options": {}, + "html": "the text", + "expected": [ + { + "type": "tag", + "name": "font", + "attribs": { + "size": "14" + }, + "children": [ + { + "data": "the text", + "type": "text" + } + ] + } + ] +} \ No newline at end of file diff --git a/node_modules/domhandler/test/cases/10-singular_attribute.json b/node_modules/domhandler/test/cases/10-singular_attribute.json new file mode 100644 index 000000000..544636e49 --- /dev/null +++ b/node_modules/domhandler/test/cases/10-singular_attribute.json @@ -0,0 +1,15 @@ +{ + "name": "Singular attribute", + "options": {}, + "html": "