diff --git a/app/controllers/wiki_controller.rb b/app/controllers/wiki_controller.rb
index 37e0c822..8c71047c 100644
--- a/app/controllers/wiki_controller.rb
+++ b/app/controllers/wiki_controller.rb
@@ -227,13 +227,13 @@ class WikiController < ApplicationController
def save
render(:status => 404, :text => 'Undefined page name') and return if @page_name.nil?
- author_name = params['author'].delete("\x01-\x08\x0B\x0C\x0E-\x1F")
+ author_name = params['author']
author_name = 'AnonymousCoward' if author_name =~ /^\s*$/
raise "Your name was not valid utf-8" if !author_name.is_utf8?
cookies['author'] = { :value => author_name, :expires => Time.utc(2030) }
begin
- the_content = params['content'].delete("\x01-\x08\x0B\x0C\x0E-\x1F")
+ the_content = params['content']
raise "Your content was not valid utf-8" if !the_content.is_utf8?
filter_spam(the_content)
if @page
@@ -294,15 +294,20 @@ class WikiController < ApplicationController
def s5
if @web.markup == :markdownMML
- @s5_content = sanitize_xhtml(Maruku.new(@page.content.delete("\r\x01-\x08\x0B\x0C\x0E-\x1F"),
+ my_content = Maruku.new(@page.content.delete("\r"),
{:math_enabled => true, :math_numbered => ['\\[','\\begin{equation}'], :content_only => true,
- :author => @page.author, :title => @page.plain_name}).to_s5.to_ncr)
+ :author => @page.author, :title => @page.plain_name})
+ @s5_content = sanitize_xhtml(my_content.to_s5)
+ @s5_theme = my_content.s5_theme
elsif @web.markup == :markdown
- @s5_content = sanitize_xhtml(Maruku.new(@page.content.delete("\r\x01-\x08\x0B\x0C\x0E-\x1F"),
+ my_content = Maruku.new(@page.content.delete("\r"),
{:math_enabled => false, :content_only => true,
- :author => @page.author, :title => @page.plain_name}).to_s5.to_ncr)
+ :author => @page.author, :title => @page.plain_name})
+ @s5_content = sanitize_xhtml(my_content.to_s5)
+ @s5_theme = my_content.s5_theme
else
@s5_content = "S5 not supported with this text filter"
+ @s5_theme = "default"
end
end
diff --git a/app/views/wiki/s5.rhtml b/app/views/wiki/s5.rhtml
index 37e2eb86..a0ad6397 100644
--- a/app/views/wiki/s5.rhtml
+++ b/app/views/wiki/s5.rhtml
@@ -13,15 +13,14 @@
-
-
-
-
-
-
+
+
+
+
+
-
+
diff --git a/lib/chunks/category.rb b/lib/chunks/category.rb
index 33e51bc9..f008c85a 100644
--- a/lib/chunks/category.rb
+++ b/lib/chunks/category.rb
@@ -1,4 +1,5 @@
require 'chunks/chunk'
+require 'sanitize'
# The category chunk looks for "category: news" on a line by
# itself and parses the terms after the ':' as categories.
@@ -8,6 +9,7 @@ require 'chunks/chunk'
#
# Category lines can be hidden using ':category: news', for example
class Category < Chunk::Abstract
+
CATEGORY_PATTERN = /^(:)?category\s*:(.*)$/i
def self.pattern() CATEGORY_PATTERN end
@@ -16,7 +18,8 @@ class Category < Chunk::Abstract
def initialize(match_data, content)
super(match_data, content)
@hidden = match_data[1]
- @list = match_data[2].split(',').map { |c| html_escape(c.strip) }
+ @list = match_data[2].split(',').map { |c| c.to_s.is_utf8? ? html_escape(c.strip) : nil }
+ @list.compact!
@unmask_text = ''
if @hidden
@unmask_text = ''
@@ -28,6 +31,6 @@ def initialize(match_data, content)
# TODO move presentation of page metadata to controller/view
def url(category)
- %{#{category} }
+ %{#{category} }
end
end
diff --git a/lib/chunks/chunk.rb b/lib/chunks/chunk.rb
index f3384943..46382c76 100644
--- a/lib/chunks/chunk.rb
+++ b/lib/chunks/chunk.rb
@@ -78,6 +78,7 @@ module Chunk
string.gsub( /&/, "&" ).
gsub( /, "<" ).
gsub( />/, ">" ).
+ gsub( /'/, "'" ).
gsub( /"/, """ )
end
diff --git a/lib/chunks/nowiki.rb b/lib/chunks/nowiki.rb
index ef99ec0b..dc1f1109 100644
--- a/lib/chunks/nowiki.rb
+++ b/lib/chunks/nowiki.rb
@@ -13,6 +13,10 @@ require 'chunks/chunk'
#
# Author: Mark Reid
# Created: 8th June 2004
+
+require 'sanitize'
+include Sanitize
+
class NoWiki < Chunk::Abstract
NOWIKI_PATTERN = Regexp.new('(.*?) ', Regexp::MULTILINE)
@@ -22,7 +26,7 @@ class NoWiki < Chunk::Abstract
def initialize(match_data, content)
super
- @plain_text = @unmask_text = match_data[1]
+ @plain_text = @unmask_text = sanitize_xhtml(match_data[1])
end
end
diff --git a/public/s5/themes/blue/bodybg.gif b/public/s5/themes/blue/bodybg.gif
new file mode 100644
index 00000000..9f1c257b
Binary files /dev/null and b/public/s5/themes/blue/bodybg.gif differ
diff --git a/public/s5/themes/blue/footbg.gif b/public/s5/themes/blue/footbg.gif
new file mode 100644
index 00000000..6fe83f2c
Binary files /dev/null and b/public/s5/themes/blue/footbg.gif differ
diff --git a/public/s5/themes/blue/pretty.css b/public/s5/themes/blue/pretty.css
new file mode 100644
index 00000000..fcf068a4
--- /dev/null
+++ b/public/s5/themes/blue/pretty.css
@@ -0,0 +1,99 @@
+/* Blue Theme 2004 by Martin Hense :::www.lounge7.de */
+
+html {background:#000294 url(splash.gif) right bottom no-repeat;}
+body {color:#FFF;font-size:1.6em}
+a {text-decoration:none;color:#336;border-bottom:1px dotted}
+:link, :visited {text-decoration:none;color:#F8B73E}
+h1, h2, h3, h4 {font-size:100%;margin:0;padding:0;font-weight:inherit}
+h1 abbr {font-variant:small-caps}
+ul, pre {margin:0;line-height:1em}
+em {color:#c60}
+strong {font-weight:bold}
+html, body {margin:0;padding:0}
+
+blockquote, q {font-style:italic}
+blockquote {padding:0 2em 0.5em;margin:0 1.5em 0.5em;
+ text-align:center;font-size:1em}
+blockquote p {margin:0}
+blockquote i {font-style:normal}
+blockquote b {display:block;margin-top:0.5em;font-weight:normal;
+ font-size:smaller;font-style:normal}
+blockquote b i {font-style:italic}
+
+kbd {font-weight:bold;font-size:1em}
+sup {font-size:smaller;line-height:1px}
+
+.slide code {padding:2px 0.25em;font-weight:bold;color:#AAABF8}
+.slide code.bad, code del {color:red}
+.slide code.old {color:silver}
+.slide pre {padding:0;margin:0.25em 0 0.5em 0.5em;color:#533;font-size:90%}
+.slide pre code {display:block}
+.slide ul {margin-left:5%;margin-right:7%;list-style:disc}
+.slide li {margin-top:0.75em;margin-right:0}
+.slide ul ul {line-height:1}
+.slide ul ul li {margin:.2em;font-size:85%;list-style:square}
+.slide img.leader {display:block;margin:0 auto}
+
+div#header, div#footer {width:100%;top:0;left:0}
+div#header, div#footer {background:#005;color:#9183BF;
+ font-family:Verdana, Helvetica, sans-serif}
+div#header {background:#005 url(bodybg.gif) -16px 0 no-repeat;}
+div#footer {font-size:0.5em;font-weight:bold;padding:.75em 0;top:auto;
+ bottom:0px;border-top:1px solid #08093F;
+ background:#000136 url(footbg.gif) top right no-repeat}
+#footer h1, #footer h2 {display:block;padding:0 1em}
+#footer h2 {font-style:italic}
+
+div.slide {top:0px;width:92%;padding:32px 4% 4%;overflow:visible;
+ font-family:georgia, Times, 'Times New Roman', serif;
+ background:transparent url(bodybg.gif) -16px 0 repeat-x}
+div.slide h1 {position:absolute;left:87px;z-index:1;
+ white-space:nowrap;text-transform:capitalize;top:0;width:80%;
+ margin:0px auto;text-align:center;padding:0px;
+ font:36px georgia, Times, 'Times New Roman', serif;
+ color:#fff;background:transparent}
+div.slide h3 {font-size:130%}
+div.long {font-size:0.75em}
+
+div#controls {position: absolute; left: 60%; bottom: 0;
+ width: 40%;
+ text-align: right; font: bold 0.9em Verdana, Helvetica, sans-serif;}
+html>body div#controls {position: fixed; padding: 0; top: auto;}
+#controls :active {color:#88A !important}
+#controls :focus {outline:1px dotted #227}
+#controls #navLinks a {padding: 0; margin: 0 0.5em;
+ border: none; color: #779;
+ cursor: pointer;}
+#controls #navList #jumplist {background: #DDD; color: #227;}
+
+
+#currentSlide {font-size:0.5em;font-family:Verdana,Helvetica,sans-serif;
+ text-align:center;color:#9183BF}
+#currentSlide span {font-size:13px;color:#fff}
+#currentSlide #csSep {display:none}
+#currentSlide #csHere {font-weight:bold}
+#currentSlide #csHere:before {content:"#";font-weight:normal}
+#currentSlide #csTotal:before {content:" of "}
+
+#slide0 {padding:3.5em 0 0.5em 0;font-size:90%;width:100%}
+#slide0 h1 {color:#fff;background:transparent;width:75%;text-align:center;
+ position:static;margin:1em auto;padding:0px;white-space:normal;
+ font:2em Georgia, Times, 'Times New Roman', serif;}
+#slide0 h2 {margin:1em 0 2em 0;text-align:center;color:#fff}
+#slide0 h3, #slide0 h4, #slide0 p {margin:0.25em;text-align:center;color:#fff}
+#slide0 p {margin-top:0.7em}
+
+ul.urls {list-style:none;display:inline;margin:0}
+.urls li {display:inline;margin:0}
+.note {display:none}
+
+.incremental, .incremental *, .incremental *:after, .incremental code
+ {color:#000295;visibility:visible}
+img.incremental {visibility:hidden}
+.slide .current {color:#B02}
+.flushtop {margin-top:0px}
+.slide .plaintable td {border:1px solid #FFF!important}
+
+/* diagnostics
+li:after {content:" [" attr(class) "]";color:#F88}
+*/
diff --git a/public/s5/themes/blue/slides.css b/public/s5/themes/blue/slides.css
new file mode 100644
index 00000000..3637d728
--- /dev/null
+++ b/public/s5/themes/blue/slides.css
@@ -0,0 +1,3 @@
+@import url(../../ui/core/s5-core.css); /* required to make the slide show run at all */
+@import url(../../ui/core/framing.css); /* sets basic placement and size of slide components */
+@import url(pretty.css); /* stuff that makes the slides look better than blah */
diff --git a/public/s5/themes/blue/splash.gif b/public/s5/themes/blue/splash.gif
new file mode 100644
index 00000000..938a0795
Binary files /dev/null and b/public/s5/themes/blue/splash.gif differ
diff --git a/public/s5/ui/default/pretty.css b/public/s5/themes/default/pretty.css
similarity index 100%
rename from public/s5/ui/default/pretty.css
rename to public/s5/themes/default/pretty.css
diff --git a/public/s5/themes/default/slides.css b/public/s5/themes/default/slides.css
new file mode 100644
index 00000000..3637d728
--- /dev/null
+++ b/public/s5/themes/default/slides.css
@@ -0,0 +1,3 @@
+@import url(../../ui/core/s5-core.css); /* required to make the slide show run at all */
+@import url(../../ui/core/framing.css); /* sets basic placement and size of slide components */
+@import url(pretty.css); /* stuff that makes the slides look better than blah */
diff --git a/public/s5/themes/flower/bodybg.jpg b/public/s5/themes/flower/bodybg.jpg
new file mode 100644
index 00000000..248743c9
Binary files /dev/null and b/public/s5/themes/flower/bodybg.jpg differ
diff --git a/public/s5/themes/flower/pretty.css b/public/s5/themes/flower/pretty.css
new file mode 100644
index 00000000..ceb865ba
--- /dev/null
+++ b/public/s5/themes/flower/pretty.css
@@ -0,0 +1,95 @@
+/* Flower Theme 2004 by Martin Hense :::www.lounge7.de */
+
+html {background:#fff url(bodybg.jpg) no-repeat;}
+body {color:#222;font-size:1.6em}
+a {text-decoration:none;color:#c60;border-bottom:1px dotted}
+:link, :visited {text-decoration:none}
+html, body {margin:0;padding:0}
+h1,h2,h3,h4 {font-size:100%;margin:0;padding:0;font-weight:inherit}
+h1 abbr {font-variant:small-caps}
+em {color:#c60;font-weight:bold}
+strong {font-weight:bold}
+ul, pre {margin:0;line-height:1em}
+li {margin-bottom:0.66em}
+li li {margin:0.33em 0;font-size:smaller}
+
+blockquote, q {font-style:italic}
+blockquote {padding:0 2em 0.5em;margin:0 1.5em 0.5em;
+ text-align:center;font-size:1em}
+blockquote p {margin:0}
+blockquote i {font-style:normal}
+blockquote b {display:block;margin-top:0.5em;font-weight:normal;
+ font-size:smaller;font-style:normal}
+blockquote b i {font-style:italic}
+
+kbd {font-weight:bold;font-size:1em}
+sup {font-size:smaller;line-height:1px}
+
+.slide code {padding:2px 0.25em;font-weight:bold;color:#533}
+.slide code.bad, code del {color:red}
+.slide code.old {color:silver}
+.slide pre {padding:0;margin:0.25em 0 0.5em 0.5em;color:#533;font-size:90%}
+.slide pre code {display:block}
+.slide ul {margin-left:5%;margin-right:7%;padding:0;list-style:circle}
+.slide li {margin-top:0.75em;margin-right:0}
+.slide ul ul {line-height:1}
+.slide ul ul li {margin:.2em;font-size:85%;list-style:disc}
+.slide img.leader {display:block;margin:0 auto}
+
+div#header, div#footer {width:100%;top:0px;left:0px}
+div#header, div#footer {color:#BA9384;font-family:Verdana,Helvetica,sans-serif}
+div#header {background:transparent;height:10px}
+div#footer {background:#fff0cf;top:auto;bottom:0px;
+ font-size:0.5em;font-weight:bold;padding:.75em 0;border-top:1px solid #999}
+#footer h1, #footer h2 {display:block;padding:0 1em}
+#footer h2 {font-style:italic}
+
+div.slide {top:0px;left:0px;padding:48px 4% 4%;height:100%;width:92%;
+ background:transparent url(rightbg.jpg) right top no-repeat;overflow:visible;
+ font-family:georgia,times,'Times New Roman',serif}
+div.slide h1 {position:absolute;z-index:1;background:transparent;
+ margin:0;padding:0.3em 0 0 50px;white-space:nowrap;
+ text-transform:capitalize;top:0;left:60px;color:#4A040A;
+ font:150%/1em georgia, times, 'Times New Roman', serif}
+div.slide h3 {font-size:130%}
+div.long {font-size:0.75em}
+
+#controls :active {color:#88A !important}
+#controls :focus {outline:1px dotted #227}
+div#controls {position: absolute; left: 60%; bottom: 0;
+ width: 40%;
+ text-align: right; font: bold 0.9em Verdana, Helvetica, sans-serif;}
+html>body div#controls {position: fixed; padding: 0; top: auto;}
+#controls :active {color:#88A !important}
+#controls :focus {outline:1px dotted #227}
+#controls #navLinks a {padding: 0; margin: 0 0.5em;
+ border: none; color: #BA9384;
+ cursor: pointer;}
+#controls #navList #jumplist {background: #DDD; color: #227;}
+
+#currentSlide {text-align:center;font-size:0.5em;
+ color:#646587;font-family:Verdana,Helvetica,sans-serif;font-weight:bold}
+
+#slide0 {padding-top:3.5em;font-size:90%}
+#slide0 h1 {position:static;margin:1em 0 1.33em;padding:0;
+ white-space:normal;color:#000;background:transparent;
+ font:2em georgia, times, 'Times New Roman', serif}
+#slide0 h3 {margin-top:0.5em;font-size:1.5em}
+#slide0 h4 {margin-top:0;font-size:1em}
+
+ul.urls {list-style:none;display:inline;margin:0}
+.urls li {display:inline;margin:0}
+.note {display:none}
+.external {border-bottom:1px dotted gray}
+html>body .external {border-bottom:none}
+.external:after {content:" \274F";font-size:smaller;color:#77B}
+
+.incremental, .incremental *, .incremental *:after, .incremental code
+ {color:#DDE;visibility:visible}
+img.incremental {visibility:hidden}
+.slide .current {color:#B02}
+.flushtop {margin-top:0px}
+
+/* diagnostics
+li:after {content:" [" attr(class) "]";color:#F88}
+*/
diff --git a/public/s5/themes/flower/rightbg.jpg b/public/s5/themes/flower/rightbg.jpg
new file mode 100644
index 00000000..430d2117
Binary files /dev/null and b/public/s5/themes/flower/rightbg.jpg differ
diff --git a/public/s5/themes/flower/slides.css b/public/s5/themes/flower/slides.css
new file mode 100644
index 00000000..3637d728
--- /dev/null
+++ b/public/s5/themes/flower/slides.css
@@ -0,0 +1,3 @@
+@import url(../../ui/core/s5-core.css); /* required to make the slide show run at all */
+@import url(../../ui/core/framing.css); /* sets basic placement and size of slide components */
+@import url(pretty.css); /* stuff that makes the slides look better than blah */
diff --git a/public/s5/themes/i18n/bodybg.jpg b/public/s5/themes/i18n/bodybg.jpg
new file mode 100644
index 00000000..6be0296d
Binary files /dev/null and b/public/s5/themes/i18n/bodybg.jpg differ
diff --git a/public/s5/themes/i18n/pretty.css b/public/s5/themes/i18n/pretty.css
new file mode 100644
index 00000000..ac0b7e27
--- /dev/null
+++ b/public/s5/themes/i18n/pretty.css
@@ -0,0 +1,97 @@
+/* Following is i18n theme -- edit away! */
+
+html {background:#95A7D4 url(bodybg.jpg) no-repeat;}
+body {color:#210;font:25px Arial, sans-serif}
+a {text-decoration:none;color:#336;border-bottom:1px dotted}
+:link, :visited {text-decoration:none;color:#00C}
+html, body {margin:0;padding:0}
+h1, h2, h3, h4, h5, h6 {font-size:1em;margin:0}
+h1 abbr {font-variant:small-caps}
+em {color:#c60}
+strong {font-weight:bold}
+ul {margin-left:1em;padding-left:0}
+li {margin-bottom:0.66em}
+li li {margin:0.33em 0;font-size:smaller}
+
+blockquote, q {font-style:italic}
+blockquote {padding:0 2em 0.5em;margin:0 1.5em 0.5em;
+ text-align:center;font-size:1em}
+blockquote p {margin:0}
+blockquote i {font-style:normal}
+blockquote b {display:block;margin-top:0.5em;font-weight:normal;
+ font-size:smaller;font-style:normal}
+blockquote b i {font-style:italic}
+
+kbd {font-weight:bold;font-size:1em}
+sup {font-size:0.75em;font-weight:normal;vertical-align:0.5em;line-height:1px}
+
+.slide code {padding:2px 0.25em;font-weight:bold;color:#533}
+.slide code.bad, code del {color:red}
+.slide code.old {color:silver}
+.slide pre {padding:0;margin:0.25em 0 0.5em 0.5em;color:#533;font-size:90%}
+.slide pre code {display:block}
+.slide ul {margin-left:5%;margin-right:7%;list-style:disc}
+.slide li {margin-top:0.75em;margin-right:0}
+.slide ul ul {line-height:1}
+.slide ul ul li {margin:.2em;font-size:85%;list-style:square}
+.slide img.leader {display:block;margin:0 auto}
+
+div#header, div#footer, div.slide {width:100%;top:0px;left:0px}
+div#header, div#footer {color:#AAB;font-size:0.5em}
+div#header {background:#666;color:#BBB;height:1em;padding-bottom:.5em}
+div#footer {background:#666;color:#BBB;height:3.25em;top:auto;bottom:0px;}
+#footer h1, #footer h2 {display:block;padding:0.5em 0.75em;
+ font-weight:normal;font-style:italic}
+#footer h1 {left:0;font-size:1em;letter-spacing:1px}
+#footer h2 {position:absolute;bottom:0;left:0}
+
+div.slide {top:0px;width:92%;padding:.5em 4% 4%}
+div.slide h1 {font-size:1.66em;line-height:1;letter-spacing:-1px;
+ margin:0px;padding:0.25em 0px;border-bottom:2px solid rgb(90,94,120)}
+div.slide h3 {font-size:130%}
+div.long {font-size:0.75em}
+
+#controls :active {color:#88A !important}
+#controls :focus {outline:1px dotted #227}
+div#controls {position:absolute;left:50%;bottom:0;width:50%;
+ text-align:right;font:bold 0.7em Verdana, Helvetica, sans-serif}
+html>body div#controls {position:fixed;padding:0 0 1em 0;top:auto}
+div#controls form {position:absolute;bottom:0;right:0;width:100%;
+ margin:0;padding:0}
+#controls #navLinks a {padding:0;margin:0 0.5em 0;background:#666;
+ border:none;color:#AAC;cursor:pointer}
+#controls #navList {height:1em}
+#controls #navList #jumplist {position:absolute;bottom:0;right:0;
+ background:#DDD;color:#227}
+
+#currentSlide {font-size:0.5em}
+#currentSlide span {font-size:13px;color:#fff}
+#currentSlide #csSep {display:none}
+#currentSlide #csHere {font-weight:bold}
+#currentSlide #csHere:before {content:"#";font-weight:normal}
+#currentSlide #csTotal:before {content:" of "}
+
+#slide0 {padding-top:3.5em;font-size:90%}
+#slide0 h1 {position:static;margin:1em 0 0;padding:0;
+ font:bold 2em Helvetica, sans-serif;white-space:normal;
+ color:#000;background:transparent}
+#slide0 h2 {font:bold italic 1em Helvetica, sans-serif;margin:0.25em}
+#slide0 h3 {margin-top:1.5em;font-size:1.5em}
+#slide0 h4 {margin-top:0;font-size:1em}
+
+ul.urls {list-style:none;display:inline;margin:0}
+.urls li {display:inline;margin:0}
+.note {display:none}
+.external {border-bottom:1px dotted gray}
+html>body .external {border-bottom:none}
+.external:after {content:" \274F";font-size:smaller;color:#77B}
+
+.incremental, .incremental *, .incremental *:after, .incremental code
+ {color:#95A7D8;visibility:visible}
+img.incremental {visibility:hidden}
+.slide .current {color:#B02}
+.flushtop {margin-top:0px}
+
+/* diagnostics
+li:after {content:" [" attr(class) "]";color:#F88}
+*/
diff --git a/public/s5/themes/i18n/slides.css b/public/s5/themes/i18n/slides.css
new file mode 100644
index 00000000..3637d728
--- /dev/null
+++ b/public/s5/themes/i18n/slides.css
@@ -0,0 +1,3 @@
+@import url(../../ui/core/s5-core.css); /* required to make the slide show run at all */
+@import url(../../ui/core/framing.css); /* sets basic placement and size of slide components */
+@import url(pretty.css); /* stuff that makes the slides look better than blah */
diff --git a/public/s5/ui/default/bodybg.gif b/public/s5/themes/nautilus/bodybg.gif
old mode 100755
new mode 100644
similarity index 100%
rename from public/s5/ui/default/bodybg.gif
rename to public/s5/themes/nautilus/bodybg.gif
diff --git a/public/s5/themes/nautilus/pretty.css b/public/s5/themes/nautilus/pretty.css
new file mode 100644
index 00000000..2e64d5c7
--- /dev/null
+++ b/public/s5/themes/nautilus/pretty.css
@@ -0,0 +1,92 @@
+/* Following is the default theme -- edit away! */
+
+html {background:#FFF url(bodybg.gif) -16px 0 no-repeat;}
+body {color:#000;font-size:1.6em}
+a {text-decoration:none;color:#c60;border-bottom:1px dotted}
+:link, :visited {text-decoration:none;color:#00C}
+html, body {margin:0;padding:0}
+h1,h2,h3,h4 {font-size:100%;margin:0;padding:0;font-weight:inherit}
+h1 abbr {font-variant:small-caps}
+em {color:#c60}
+strong {font-weight:bold}
+ul, pre {margin:0;line-height:1em}
+li {margin-bottom:0.66em}
+li li {margin:0.33em 0;font-size:smaller}
+
+blockquote, q {font-style:italic}
+blockquote {padding:0 2em 0.5em;margin:0 1.5em 0.5em;
+ text-align:center;font-size:1em}
+blockquote p {margin:0}
+blockquote i {font-style:normal}
+blockquote b {display:block;margin-top:0.5em;font-weight:normal;
+ font-size:smaller;font-style:normal}
+blockquote b i {font-style:italic}
+
+kbd {font-weight:bold;font-size:1em}
+sup {font-size:smaller;line-height:1px}
+
+.slide code {padding:2px 0.25em;font-weight:bold;color:#533}
+.slide code.bad, code del {color:red}
+.slide code.old {color:silver}
+.slide pre {padding:0;margin:0.25em 0 0.5em 0.5em;color:#533;font-size:90%}
+.slide pre code {display:block}
+.slide ul {margin-left:5%;margin-right:7%;list-style:disc}
+.slide li {margin-top:0.75em;margin-right:0}
+.slide ul ul {line-height:1}
+.slide ul ul li {margin:.2em;font-size:85%;list-style:square}
+.slide img.leader {display:block;margin:0 auto}
+
+div#header, div#footer, div.slide {width:100%;top:0px;left:0px}
+div#header, div#footer {color:#AAB;font-family:Verdana,Helvetica,sans-serif}
+div#header {background:#005 url(bodybg.gif) -16px 0 no-repeat;height:2.5em}
+div#footer {background:#005;height:2.5em;top:auto;bottom:0px;
+ font-size:0.5em;font-weight:bold;padding:1em 0}
+#footer h1, #footer h2 {display:block;padding:0 1em}
+#footer h2 {font-style:italic}
+
+div.slide {top:0px;width:92%;padding:2.5em 4% 4%}
+div.slide h1 {position:absolute;top:0;left:135px;z-index:1;color:#DDE;
+ text-align:left;white-space:nowrap;text-transform:capitalize;
+ margin:0px;padding:0.3em 0 0 50px;font:bold 150%/1em Helvetica,sans-serif}
+div.slide h3 {font-size:130%}
+div.long {font-size:0.75em}
+
+div#controls {position: absolute; left: 60%; bottom: 0;
+ width: 40%;
+ text-align: right; font: bold 0.9em Verdana, Helvetica, sans-serif;}
+html>body div#controls {position: fixed; padding: 0; top: auto;}
+#controls :active {color:#88A !important}
+#controls :focus {outline:1px dotted #227}
+#controls #navLinks a {padding: 0; margin: 0 0.5em;
+ border: none; color: #779;
+ cursor: pointer;}
+#controls #navList #jumplist {background: #DDD; color: #227;}
+
+#currentSlide {text-align:center;font-size:0.5em;
+ color:#fff;font-family:Verdana,Helvetica,sans-serif;font-weight:bold}
+#currentSlide span {color:#AAB}
+
+#slide0 {padding-top:3.5em;font-size:90%}
+#slide0 h1 {position:static;white-space:normal;
+ margin:1em 0 0;padding:0;font:bold 2em Helvetica,sans-serif;
+ color:#000;background:transparent}
+#slide0 h2 {font:bold italic 1em Helvetica, sans-serif;margin:0.25em}
+#slide0 h3 {margin-top:1.5em;font-size:1.5em}
+#slide0 h4 {margin-top:0;font-size:1em}
+
+ul.urls {list-style:none;display:inline;margin:0}
+.urls li {display:inline;margin:0}
+.note {display:none}
+.external {border-bottom:1px dotted gray}
+html>body .external {border-bottom:none}
+.external:after {content:" \274F";font-size:smaller;color:#77B}
+
+.incremental, .incremental *, .incremental *:after, .incremental code
+ {color:#DDE;visibility:visible}
+img.incremental {visibility:hidden}
+.slide .current {color:#B02}
+.flushtop {margin-top:0px}
+
+/* diagnostics
+li:after {content:" [" attr(class) "]";color:#F88}
+*/
diff --git a/public/s5/themes/nautilus/slides.css b/public/s5/themes/nautilus/slides.css
new file mode 100644
index 00000000..3637d728
--- /dev/null
+++ b/public/s5/themes/nautilus/slides.css
@@ -0,0 +1,3 @@
+@import url(../../ui/core/s5-core.css); /* required to make the slide show run at all */
+@import url(../../ui/core/framing.css); /* sets basic placement and size of slide components */
+@import url(pretty.css); /* stuff that makes the slides look better than blah */
diff --git a/public/s5/themes/pixel/bodybg.gif b/public/s5/themes/pixel/bodybg.gif
new file mode 100644
index 00000000..a57ccb10
Binary files /dev/null and b/public/s5/themes/pixel/bodybg.gif differ
diff --git a/public/s5/themes/pixel/headbg.jpg b/public/s5/themes/pixel/headbg.jpg
new file mode 100644
index 00000000..3c0f13b1
Binary files /dev/null and b/public/s5/themes/pixel/headbg.jpg differ
diff --git a/public/s5/themes/pixel/pretty.css b/public/s5/themes/pixel/pretty.css
new file mode 100644
index 00000000..f627134a
--- /dev/null
+++ b/public/s5/themes/pixel/pretty.css
@@ -0,0 +1,114 @@
+/* Pixel Theme 2004 by Martin Hense :::www.lounge7.de */
+
+html {background:transparent url(bodybg.gif) repeat-y;}
+body {color:#08093F;font-size:1.5em}
+a {text-decoration:none;color:#336;border-bottom:1px dotted}
+:link, :visited {text-decoration:none}
+html, body {margin:0;padding:0}
+h1, h2, h3, h4 {font-size:100%;margin:0;padding:0;font-weight:inherit}
+h1 abbr {font-variant:small-caps}
+em {color:#c60}
+strong {font-weight:bold}
+ul, pre {margin:0;line-height:1em}
+li {margin-bottom:0.66em}
+li li {margin:0.33em 0;font-size:smaller}
+
+blockquote, q {font-style:italic}
+blockquote {padding:0 2em 0.5em;margin:0 1.5em 0.5em;
+ text-align:center;font-size:1em}
+blockquote p {margin:0}
+blockquote i {font-style:normal}
+blockquote b {display:block;margin-top:0.5em;font-weight:normal;
+ font-size:smaller;font-style:normal}
+blockquote b i {font-style:italic}
+
+kbd {font-weight:bold;font-size:1em}
+sup {font-size:smaller;line-height:1px}
+
+.slide code {padding:2px 0.25em;font-weight:bold;color:#533}
+.slide code.bad, code del {color:red}
+.slide code.old {color:silver}
+.slide pre {padding:0;margin:0.25em 0 0.5em 0.5em;color:#533;font-size:90%}
+.slide pre code {display:block}
+.slide ul {margin-left:50px;margin-right:7%;list-style:square}
+.slide li {margin-top:0.75em;margin-right:0}
+.slide ul ul {line-height:1}
+.slide ul ul li {margin:.2em;font-size:85%;list-style:square}
+.slide img.leader {display:block;margin:0 auto}
+
+div#header, div#footer, div.slide {width:100%;top:0px;left:0px}
+div#header, div#footer {color:#646587;font-family:Verdana, Helvetica, sans-serif}
+div#header {background:transparent url(headbg.jpg) 0 0 no-repeat;height:80px}
+div#footer {background:#fff;font-size:0.5em;font-weight:bold;padding:.5em 0;
+ top:auto;bottom:0px;height:2em;border-top:1px solid #08093F}
+#footer h1, #footer h2 {display:block;padding:0 1em}
+#footer h2 {font-style:italic}
+
+div.slide {top:0px;width:92%;padding:48px 4% 4%;
+ font-family:Verdana, Helvetica, Arial, sans-serif}
+div.slide h1 {position:absolute;top:24px;left:64px;z-index:1;color:#FFF;
+ background:transparent;margin:0px;padding:0 0 0 50px;white-space:nowrap;
+ font:bold 30px Helvetica, sans-serif;text-transform:capitalize}
+div.slide h3 {font-size:130%}
+div.long {font-size:0.75em}
+/*
+#controls :active {color:#88A !important}
+#controls :focus {outline:1px dotted #227}
+div#controls {left:50%;bottom:0;z-index:1;width:50%;text-align:right;
+ height:100%}
+html>body div#controls {position:fixed;padding:0 0 1em 0;top:auto}
+div#controls form {position:absolute;bottom:0;right:0;width:100%;
+ margin:0;padding:0}
+div#controls #navLinks a {padding:0;margin:0 0.5em;color:#779;
+ border:none;cursor:pointer}
+div#controls #navList {height:1em}
+div#controls #navList #jumplist {position:absolute;bottom:0;right:0;
+ background:#DDD;color:#227}
+div#controls select {visibility:hidden;background:#DDD;color:#227}
+div#controls div:hover select {visibility:visible}
+*/
+div#controls {position: absolute; left: 60%; bottom: 0;
+ width: 40%;
+ text-align: right; font: bold 0.7em Verdana, Helvetica, sans-serif;}
+html>body div#controls {position: fixed; padding: 0; top: auto;}
+#controls :active {color:#88A !important}
+#controls :focus {outline:1px dotted #227}
+#controls #navLinks a {padding: 0; margin: 0 0.5em;
+ border: none; color: #779;
+ cursor: pointer;}
+#controls #navList #jumplist {background: #DDD; color: #227;}
+
+#currentSlide {color:#646587;text-align:center;font-size:0.5em;
+ font-family:Verdana, Helvetica, sans-serif;font-weight:bold}
+#currentSlide span {font-size:13px;color:#08093F}
+#currentSlide #csSep {display:none}
+#currentSlide #csHere {font-weight:bold}
+#currentSlide #csHere:before {content:"#";font-weight:normal}
+#currentSlide #csTotal:before {content:" of "}
+
+#slide0 {padding-top:3.5em;font-size:90%}
+#slide0 h1 {position:static;white-space:normal;
+ margin:0;padding:60px 60px 0 150px;text-align:right;
+ font:bold 2em Helvetica,sans-serif;white-space:normal;height:281px;
+ color:#fff;background:transparent url(slide0bg.gif) no-repeat}
+#slide0 h3 {margin-bottom:20px;margin-top:0.5em;font-size:1.5em}
+#slide0 h4 {margin-bottom:4px;margin-top:0;font-size:1em}
+
+ul.urls {list-style:none;display:inline;margin:0}
+.urls li {display:inline;margin:0}
+.note {display:none}
+.urls li {display:inline;margin:0}
+.note {display:none}
+.external {border-bottom:1px dotted gray}
+html>body .external {border-bottom:none}
+.external:after {content:" \274F";font-size:smaller;color:#77B}
+
+.incremental, .incremental *, .incremental *:after, .incremental code
+ {color:#DDE;visibility:visible}
+img.incremental {visibility:hidden}
+.slide .current {color:#B02}
+.flushtop {margin-top:0px}
+
+/* diagnostics
+li:after {content:" [" attr(class) "]";color:#F88}
+*/
diff --git a/public/s5/themes/pixel/slide0bg.gif b/public/s5/themes/pixel/slide0bg.gif
new file mode 100644
index 00000000..fffb08a2
Binary files /dev/null and b/public/s5/themes/pixel/slide0bg.gif differ
diff --git a/public/s5/themes/pixel/slides.css b/public/s5/themes/pixel/slides.css
new file mode 100644
index 00000000..3637d728
--- /dev/null
+++ b/public/s5/themes/pixel/slides.css
@@ -0,0 +1,3 @@
+@import url(../../ui/core/s5-core.css); /* required to make the slide show run at all */
+@import url(../../ui/core/framing.css); /* sets basic placement and size of slide components */
+@import url(pretty.css); /* stuff that makes the slides look better than blah */
diff --git a/public/s5/ui/default/blank.gif b/public/s5/ui/core/blank.gif
similarity index 100%
rename from public/s5/ui/default/blank.gif
rename to public/s5/ui/core/blank.gif
diff --git a/public/s5/ui/core/bodybg.gif b/public/s5/ui/core/bodybg.gif
new file mode 100755
index 00000000..5f448a16
Binary files /dev/null and b/public/s5/ui/core/bodybg.gif differ
diff --git a/public/s5/ui/default/framing.css b/public/s5/ui/core/framing.css
similarity index 100%
rename from public/s5/ui/default/framing.css
rename to public/s5/ui/core/framing.css
diff --git a/public/s5/ui/default/iepngfix.htc b/public/s5/ui/core/iepngfix.htc
similarity index 100%
rename from public/s5/ui/default/iepngfix.htc
rename to public/s5/ui/core/iepngfix.htc
diff --git a/public/s5/ui/default/math.css b/public/s5/ui/core/math.css
similarity index 100%
rename from public/s5/ui/default/math.css
rename to public/s5/ui/core/math.css
diff --git a/public/s5/ui/default/notes.css b/public/s5/ui/core/notes.css
similarity index 100%
rename from public/s5/ui/default/notes.css
rename to public/s5/ui/core/notes.css
diff --git a/public/s5/ui/default/opera.css b/public/s5/ui/core/opera.css
similarity index 100%
rename from public/s5/ui/default/opera.css
rename to public/s5/ui/core/opera.css
diff --git a/public/s5/ui/default/outline.css b/public/s5/ui/core/outline.css
similarity index 100%
rename from public/s5/ui/default/outline.css
rename to public/s5/ui/core/outline.css
diff --git a/public/s5/ui/default/print.css b/public/s5/ui/core/print.css
similarity index 100%
rename from public/s5/ui/default/print.css
rename to public/s5/ui/core/print.css
diff --git a/public/s5/ui/default/s5-core.css b/public/s5/ui/core/s5-core.css
similarity index 100%
rename from public/s5/ui/default/s5-core.css
rename to public/s5/ui/core/s5-core.css
diff --git a/public/s5/ui/default/slides.js b/public/s5/ui/core/slides.js
similarity index 100%
rename from public/s5/ui/default/slides.js
rename to public/s5/ui/core/slides.js
diff --git a/public/s5/ui/default/slides.css b/public/s5/ui/default/slides.css
deleted file mode 100644
index 0786d7db..00000000
--- a/public/s5/ui/default/slides.css
+++ /dev/null
@@ -1,3 +0,0 @@
-@import url(s5-core.css); /* required to make the slide show run at all */
-@import url(framing.css); /* sets basic placement and size of slide components */
-@import url(pretty.css); /* stuff that makes the slides look better than blah */
\ No newline at end of file
diff --git a/test/fixtures/webs.yml b/test/fixtures/webs.yml
index 05437295..c847d96f 100644
--- a/test/fixtures/webs.yml
+++ b/test/fixtures/webs.yml
@@ -4,7 +4,7 @@ test_wiki:
updated_at: 2005-08-01
name: wiki1
address: wiki1
- markup: textile
+ markup: markdownMML
instiki:
id: 2
@@ -12,4 +12,4 @@ instiki:
updated_at: 2005-08-01
name: Instiki
address: instiki
- markup: textile
\ No newline at end of file
+ markup: markdownMML
diff --git a/test/functional/wiki_controller_test.rb b/test/functional/wiki_controller_test.rb
index 8e8590c3..44cfb458 100755
--- a/test/functional/wiki_controller_test.rb
+++ b/test/functional/wiki_controller_test.rb
@@ -151,7 +151,7 @@ class WikiControllerTest < Test::Unit::TestCase
assert_response(:success, bypass_body_parsing = true)
assert_equal 'application/zip', r.headers['Content-Type']
- assert_match /attachment; filename="wiki1-textile-\d\d\d\d-\d\d-\d\d-\d\d-\d\d-\d\d.zip"/,
+ assert_match /attachment; filename="wiki1-markdownMML-\d\d\d\d-\d\d-\d\d-\d\d-\d\d-\d\d.zip"/,
r.headers['Content-Disposition']
assert_equal 'PK', r.body[0..1], 'Content is not a zip file'
end
@@ -665,14 +665,45 @@ class WikiControllerTest < Test::Unit::TestCase
r = process('tex', 'web' => 'wiki1', 'id' => 'HomePage')
assert_response(:success)
- assert_equal "\\documentclass[12pt,titlepage]{article}\n\n\\usepackage{amsmath}" +
- "\n\\usepackage{amsfonts}\n\\usepackage{graphicx}\n\\usepackage{ucs}\n" +
- "\\usepackage[utf8x]{inputenc}\n\\usepackage{hyperref}\n\n" +
- "%-------------------------------------------------------------------\n\n" +
- "\\begin{document}\n\n%--------------------------------------------------" +
- "-----------------\n\n\\section*{HomePage}\n\nTeX export only supported with" +
- " the Markdown text filters.\n\n\\end{document}\n",
- r.body
+ assert_equal %q!\documentclass[12pt,titlepage]{article}
+
+\usepackage{amsmath}
+\usepackage{amsfonts}
+\usepackage{amssymb}
+\usepackage{graphicx}
+\usepackage{ucs}
+\usepackage[utf8x]{inputenc}
+\usepackage{hyperref}
+
+%----Macros----------
+\newcommand{\gt}{>}
+\newcommand{\lt}{<}
+\newcommand{\darr}{\downarrow}
+\newcommand{\nearr}{\nearrow}
+\newcommand{\nwarr}{\nwarrow}
+\newcommand{\searr}{\searrow}
+\newcommand{\swarr}{\swarrow}
+\newcommand{\iff}{\Longleftrightarrow}
+\newcommand{\impliedby}{\Leftarrow}
+\newcommand{\map}{\mapsto}
+\newcommand{\embedsin}{\hookrightarrow}
+\newcommand{\implies}{\Rightarrow}
+\newcommand{\qed}{\blacksquare}
+
+%-------------------------------------------------------------------
+
+\begin{document}
+
+%-------------------------------------------------------------------
+
+\section*{HomePage}
+
+HisWay would be MyWay in kinda ThatWay in HisWay though MyWay $\backslash$OverThere --{} see SmartEngine in that SmartEngineGUI
+
+
+
+\end{document}
+!, r.body
end
diff --git a/test/unit/page_renderer_test.rb b/test/unit/page_renderer_test.rb
index 94544d72..00354da6 100644
--- a/test/unit/page_renderer_test.rb
+++ b/test/unit/page_renderer_test.rb
@@ -46,7 +46,7 @@ class PageRendererTest < Test::Unit::TestCase
'would be My Way in kinda ' +
'That Way in ' +
'His Way? ' +
- %{though My Way OverThere—see } +
+ %{though My Way OverThere \xE2\x80\x93 see } +
'Smart Engine in that ' +
'Smart Engine GUI' +
'? ',
@@ -157,21 +157,21 @@ class PageRendererTest < Test::Unit::TestCase
assert_markup_parsed_as(
'should we go ' +
'That Way or This Way? ' +
- '
',
+ '',
'_should we go ThatWay or ThisWay _')
end
# wikiwords are invalid as styles, must be in "name: value" form
def test_content_with_wikiword_in_style_tag
assert_markup_parsed_as(
- "That is some Stylish Emphasis
",
+ "That is some Stylish Emphasis
",
'That is some Stylish Emphasis ')
end
# validates format of style..
def test_content_with_valid_style_in_style_tag
assert_markup_parsed_as(
- "That is some Stylish Emphasis
",
+ "That is some Stylish Emphasis
",
'That is some Stylish Emphasis ')
end
@@ -182,38 +182,38 @@ class PageRendererTest < Test::Unit::TestCase
def test_content_with_pre_blocks
assert_markup_parsed_as(
- 'A class SmartEngine end
would not mark up
CodeBlocks ',
- 'A class SmartEngine end
would not mark up CodeBlocks ')
+ 'A class SmartEngine end
would not mark up
\n\nCodeBlocks \n\nwould it?
',
+ 'A class SmartEngine end
would not mark up\n\nCodeBlocks \n\nwould it?')
end
def test_content_with_autolink_in_parentheses
assert_markup_parsed_as(
- 'The W3C body (' +
+ 'The W3C body (' +
'http://www.w3c.org ) sets web standards
',
'The W3C body (http://www.w3c.org) sets web standards')
end
def test_content_with_link_in_parentheses
assert_markup_parsed_as(
- "(What is a wiki? )
",
- '("What is a wiki?":http://wiki.org/wiki.cgi?WhatIsWiki)')
+ "(What is a wiki? )
",
+ '([What is a wiki?](http://wiki.org/wiki.cgi?WhatIsWiki))')
end
def test_content_with_image_link
assert_markup_parsed_as(
- "This is a Textile image link.
",
- 'This !http://hobix.com/sample.jpg! is a Textile image link.')
+ "This is a Markdown image link.
",
+ 'This ![](http://hobix.com/sample.jpg) is a Markdown image link.')
end
def test_content_with_inlined_img_tag
assert_markup_parsed_as(
- "This is an inline image link.
",
+ "This is an inline image link.
",
'This is an inline image link.')
# currently, upper case HTML elements are not allowed
assert_markup_parsed_as(
- 'This <IMG SRC="http://hobix.com/sample.jpg" alt=""> is an inline image link.
',
- 'This is an inline image link.')
+ 'This <IMG SRC="http://hobix.com/sample.jpg" alt=""></IMG> is an inline image link.
',
+ 'This is an inline image link.')
end
def test_nowiki_tag
@@ -230,6 +230,12 @@ class PageRendererTest < Test::Unit::TestCase
"Do not mark \n up [[this text]] \n" +
"and http://this.url.com but markup [[this]]")
end
+
+ def test_sanitize_nowiki_tag
+ assert_markup_parsed_as(
+ '[[test]]&shebang <script>alert("xss!");</script> *foo*
',
+ '[[test]]&shebang *foo* ')
+ end
def test_content_with_bracketted_wiki_word
set_web_property :brackets_only, true
@@ -244,7 +250,7 @@ class PageRendererTest < Test::Unit::TestCase
' My Way in kinda ' +
'That Way in ' +
'His Way though ' +
- %{My Way OverThere—see } +
+ %{My Way OverThere \xE2\x80\x93 see } +
'Smart Engine in that ' +
'Smart Engine GUI
',
test_renderer(@revision).display_content_for_export
@@ -253,14 +259,14 @@ class PageRendererTest < Test::Unit::TestCase
def test_double_replacing
@revision.content = "VersionHistory\r\n\r\ncry VersionHistory"
assert_equal 'Version History' +
- "?
\n\n\n\tcry " +
+ "?
\n\ncry " +
'Version History? ' +
'
',
test_renderer(@revision).display_content
@revision.content = "f\r\nVersionHistory\r\n\r\ncry VersionHistory"
- assert_equal "fVersion History" +
- "?
\n\n\n\tcry " +
+ assert_equal "
f Version History" +
+ "?
\n\ncry " +
"Version History? " +
"
",
test_renderer(@revision).display_content
@@ -321,12 +327,12 @@ class PageRendererTest < Test::Unit::TestCase
def test_list_with_tildas
list_with_tildas = <<-EOL
- * "a":~b
- * c~ d
+* [a](~b)
+* c~ d
EOL
assert_markup_parsed_as(
- "",
+ "",
list_with_tildas)
end
@@ -369,6 +375,16 @@ class PageRendererTest < Test::Unit::TestCase
assert_equal 'NewPageCategory', references[0].referenced_name
assert_equal WikiReference::CATEGORY, references[0].link_type
end
+
+ def test_references_creation_sanitized_categories
+ new_page = @web.add_page('NewPage', "Foo\ncategory: ",
+ Time.local(2004, 4, 4, 16, 50), 'AlexeyVerkhovsky', test_renderer)
+
+ references = new_page.wiki_references(true)
+ assert_equal 1, references.size
+ assert_equal "<script>alert('XSS');</script>", references[0].referenced_name
+ assert_equal WikiReference::CATEGORY, references[0].link_type
+ end
def test_rendering_included_page_under_different_modes
included = @web.add_page('Included', 'link to HomePage', Time.now, 'AnAuthor', test_renderer)
diff --git a/test/unit/web_test.rb b/test/unit/web_test.rb
index 0dc0b9ec..3ef65d68 100644
--- a/test/unit/web_test.rb
+++ b/test/unit/web_test.rb
@@ -1,7 +1,8 @@
-require File.expand_path(File.dirname(__FILE__) + '/../test_helper')
+require File.dirname(__FILE__) + '/../test_helper'
+#require File.expand_path(File.dirname(__FILE__) + '/../test_helper')
class WebTest < Test::Unit::TestCase
- fixtures :webs, :pages, :revisions, :system, :wiki_references
+ fixtures :system, :webs, :pages, :revisions, :wiki_references
def setup
@web = webs(:instiki)
diff --git a/vendor/plugins/HTML5lib/bin/html5 b/vendor/plugins/HTML5lib/bin/html5
index 2680aea3..bc0514ad 100755
--- a/vendor/plugins/HTML5lib/bin/html5
+++ b/vendor/plugins/HTML5lib/bin/html5
@@ -81,8 +81,8 @@ def print_output(parser, document, opts)
if opts.error
errList=[]
- for pos, message in parser.errors
- errList << ("Line %i Col %i"%pos + " " + message)
+ for pos, errorcode, datavars in parser.errors
+ errList << "Line %i Col %i"%pos + " " + constants.E.get(errorcode, 'Unknown error "%s"' % errorcode) % datavars
end
$stdout.write("\nParse errors:\n" + errList.join("\n")+"\n")
end
diff --git a/vendor/plugins/HTML5lib/lib/html5/constants.rb b/vendor/plugins/HTML5lib/lib/html5/constants.rb
index 8ccaf66d..9a4580fa 100755
--- a/vendor/plugins/HTML5lib/lib/html5/constants.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/constants.rb
@@ -2,6 +2,8 @@ module HTML5
class EOF < Exception; end
+ def self._(str); str end
+
CONTENT_MODEL_FLAGS = [
:PCDATA,
:RCDATA,
@@ -815,4 +817,228 @@ module HTML5
hz-gb-2312
]
+ E = {
+ "null-character" =>
+ _("Null character in input stream, replaced with U+FFFD."),
+ "incorrectly-placed-solidus" =>
+ _("Solidus (/) incorrectly placed in tag."),
+ "incorrect-cr-newline-entity" =>
+ _("Incorrect CR newline entity, replaced with LF."),
+ "illegal-windows-1252-entity" =>
+ _("Entity used with illegal number (windows-1252 reference)."),
+ "cant-convert-numeric-entity" =>
+ _("Numeric entity couldn't be converted to character " +
+ "(codepoint U+%(charAsInt)08x)."),
+ "illegal-codepoint-for-numeric-entity" =>
+ _("Numeric entity represents an illegal codepoint=> " +
+ "U+%(charAsInt)08x."),
+ "numeric-entity-without-semicolon" =>
+ _("Numeric entity didn't end with ';'."),
+ "expected-numeric-entity-but-got-eof" =>
+ _("Numeric entity expected. Got end of file instead."),
+ "expected-numeric-entity" =>
+ _("Numeric entity expected but none found."),
+ "named-entity-without-semicolon" =>
+ _("Named entity didn't end with ';'."),
+ "expected-named-entity" =>
+ _("Named entity expected. Got none."),
+ "attributes-in-end-tag" =>
+ _("End tag contains unexpected attributes."),
+ "expected-tag-name-but-got-right-bracket" =>
+ _("Expected tag name. Got '>' instead."),
+ "expected-tag-name-but-got-question-mark" =>
+ _("Expected tag name. Got '?' instead. (HTML doesn't " +
+ "support processing instructions.)"),
+ "expected-tag-name" =>
+ _("Expected tag name. Got something else instead"),
+ "expected-closing-tag-but-got-right-bracket" =>
+ _("Expected closing tag. Got '>' instead. Ignoring '>'."),
+ "expected-closing-tag-but-got-eof" =>
+ _("Expected closing tag. Unexpected end of file."),
+ "expected-closing-tag-but-got-char" =>
+ _("Expected closing tag. Unexpected character '%(data)' found."),
+ "eof-in-tag-name" =>
+ _("Unexpected end of file in the tag name."),
+ "expected-attribute-name-but-got-eof" =>
+ _("Unexpected end of file. Expected attribute name instead."),
+ "eof-in-attribute-name" =>
+ _("Unexpected end of file in attribute name."),
+ "duplicate-attribute" =>
+ _("Dropped duplicate attribute on tag."),
+ "expected-end-of-tag-name-but-got-eof" =>
+ _("Unexpected end of file. Expected = or end of tag."),
+ "expected-attribute-value-but-got-eof" =>
+ _("Unexpected end of file. Expected attribute value."),
+ "eof-in-attribute-value-double-quote" =>
+ _("Unexpected end of file in attribute value (\")."),
+ "eof-in-attribute-value-single-quote" =>
+ _("Unexpected end of file in attribute value (')."),
+ "eof-in-attribute-value-no-quotes" =>
+ _("Unexpected end of file in attribute value."),
+ "expected-dashes-or-doctype" =>
+ _("Expected '--' or 'DOCTYPE'. Not found."),
+ "incorrect-comment" =>
+ _("Incorrect comment."),
+ "eof-in-comment" =>
+ _("Unexpected end of file in comment."),
+ "eof-in-comment-end-dash" =>
+ _("Unexpected end of file in comment (-)"),
+ "unexpected-dash-after-double-dash-in-comment" =>
+ _("Unexpected '-' after '--' found in comment."),
+ "eof-in-comment-double-dash" =>
+ _("Unexpected end of file in comment (--)."),
+ "unexpected-char-in-comment" =>
+ _("Unexpected character in comment found."),
+ "need-space-after-doctype" =>
+ _("No space after literal string 'DOCTYPE'."),
+ "expected-doctype-name-but-got-right-bracket" =>
+ _("Unexpected > character. Expected DOCTYPE name."),
+ "expected-doctype-name-but-got-eof" =>
+ _("Unexpected end of file. Expected DOCTYPE name."),
+ "eof-in-doctype-name" =>
+ _("Unexpected end of file in DOCTYPE name."),
+ "eof-in-doctype" =>
+ _("Unexpected end of file in DOCTYPE."),
+ "expected-space-or-right-bracket-in-doctype" =>
+ _("Expected space or '>'. Got '%(data)'"),
+ "unexpected-end-of-doctype" =>
+ _("Unexpected end of DOCTYPE."),
+ "unexpected-char-in-doctype" =>
+ _("Unexpected character in DOCTYPE."),
+ "eof-in-bogus-doctype" =>
+ _("Unexpected end of file in bogus doctype."),
+ "eof-in-innerhtml" =>
+ _("XXX innerHTML EOF"),
+ "unexpected-doctype" =>
+ _("Unexpected DOCTYPE. Ignored."),
+ "non-html-root" =>
+ _("html needs to be the first start tag."),
+ "expected-doctype-but-got-eof" =>
+ _("Unexpected End of file. Expected DOCTYPE."),
+ "unknown-doctype" =>
+ _("Erroneous DOCTYPE."),
+ "expected-doctype-but-got-chars" =>
+ _("Unexpected non-space characters. Expected DOCTYPE."),
+ "expected-doctype-but-got-start-tag" =>
+ _("Unexpected start tag (%(name)). Expected DOCTYPE."),
+ "expected-doctype-but-got-end-tag" =>
+ _("Unexpected end tag (%(name)). Expected DOCTYPE."),
+ "end-tag-after-implied-root" =>
+ _("Unexpected end tag (%(name)) after the (implied) root element."),
+ "expected-named-closing-tag-but-got-eof" =>
+ _("Unexpected end of file. Expected end tag (%(name))."),
+ "two-heads-are-not-better-than-one" =>
+ _("Unexpected start tag head in existing head. Ignored."),
+ "unexpected-end-tag" =>
+ _("Unexpected end tag (%(name)). Ignored."),
+ "unexpected-start-tag-out-of-my-head" =>
+ _("Unexpected start tag (%(name)) that can be in head. Moved."),
+ "unexpected-start-tag" =>
+ _("Unexpected start tag (%(name))."),
+ "missing-end-tag" =>
+ _("Missing end tag (%(name))."),
+ "missing-end-tags" =>
+ _("Missing end tags (%(name))."),
+ "unexpected-start-tag-implies-end-tag" =>
+ _("Unexpected start tag (%(startName)) " +
+ "implies end tag (%(endName))."),
+ "unexpected-start-tag-treated-as" =>
+ _("Unexpected start tag (%(originalName)). Treated as %(newName)."),
+ "deprecated-tag" =>
+ _("Unexpected start tag %(name). Don't use it!"),
+ "unexpected-start-tag-ignored" =>
+ _("Unexpected start tag %(name). Ignored."),
+ "expected-one-end-tag-but-got-another" =>
+ _("Unexpected end tag (%(gotName)). " +
+ "Missing end tag (%(expectedName))."),
+ "end-tag-too-early" =>
+ _("End tag (%(name)) seen too early. Expected other end tag."),
+ "end-tag-too-early-named" =>
+ _("Unexpected end tag (%(gotName)). Expected end tag (%(expectedName))."),
+ "end-tag-too-early-ignored" =>
+ _("End tag (%(name)) seen too early. Ignored."),
+ "adoption-agency-1.1" =>
+ _("End tag (%(name)) violates step 1, " +
+ "paragraph 1 of the adoption agency algorithm."),
+ "adoption-agency-1.2" =>
+ _("End tag (%(name)) violates step 1, " +
+ "paragraph 2 of the adoption agency algorithm."),
+ "adoption-agency-1.3" =>
+ _("End tag (%(name)) violates step 1, " +
+ "paragraph 3 of the adoption agency algorithm."),
+ "unexpected-end-tag-treated-as" =>
+ _("Unexpected end tag (%(originalName)). Treated as %(newName)."),
+ "no-end-tag" =>
+ _("This element (%(name)) has no end tag."),
+ "unexpected-implied-end-tag-in-table" =>
+ _("Unexpected implied end tag (%(name)) in the table phase."),
+ "unexpected-implied-end-tag-in-table-body" =>
+ _("Unexpected implied end tag (%(name)) in the table body phase."),
+ "unexpected-char-implies-table-voodoo" =>
+ _("Unexpected non-space characters in " +
+ "table context caused voodoo mode."),
+ "unexpected-start-tag-implies-table-voodoo" =>
+ _("Unexpected start tag (%(name)) in " +
+ "table context caused voodoo mode."),
+ "unexpected-end-tag-implies-table-voodoo" =>
+ _("Unexpected end tag (%(name)) in " +
+ "table context caused voodoo mode."),
+ "unexpected-cell-in-table-body" =>
+ _("Unexpected table cell start tag (%(name)) " +
+ "in the table body phase."),
+ "unexpected-cell-end-tag" =>
+ _("Got table cell end tag (%(name)) " +
+ "while required end tags are missing."),
+ "unexpected-end-tag-in-table-body" =>
+ _("Unexpected end tag (%(name)) in the table body phase. Ignored."),
+ "unexpected-implied-end-tag-in-table-row" =>
+ _("Unexpected implied end tag (%(name)) in the table row phase."),
+ "unexpected-end-tag-in-table-row" =>
+ _("Unexpected end tag (%(name)) in the table row phase. Ignored."),
+ "unexpected-select-in-select" =>
+ _("Unexpected select start tag in the select phase " +
+ "implies select start tag."),
+ "unexpected-start-tag-in-select" =>
+ _("Unexpected start tag token (%(name) in the select phase. " +
+ "Ignored."),
+ "unexpected-end-tag-in-select" =>
+ _("Unexpected end tag (%(name)) in the select phase. Ignored."),
+ "unexpected-char-after-body" =>
+ _("Unexpected non-space characters in the after body phase."),
+ "unexpected-start-tag-after-body" =>
+ _("Unexpected start tag token (%(name))" +
+ " in the after body phase."),
+ "unexpected-end-tag-after-body" =>
+ _("Unexpected end tag token (%(name))" +
+ " in the after body phase."),
+ "unexpected-char-in-frameset" =>
+ _("Unepxected characters in the frameset phase. Characters ignored."),
+ "unexpected-start-tag-in-frameset" =>
+ _("Unexpected start tag token (%(name))" +
+ " in the frameset phase. Ignored."),
+ "unexpected-frameset-in-frameset-innerhtml" =>
+ _("Unexpected end tag token (frameset) " +
+ "in the frameset phase (innerHTML)."),
+ "unexpected-end-tag-in-frameset" =>
+ _("Unexpected end tag token (%(name))" +
+ " in the frameset phase. Ignored."),
+ "unexpected-char-after-frameset" =>
+ _("Unexpected non-space characters in the " +
+ "after frameset phase. Ignored."),
+ "unexpected-start-tag-after-frameset" =>
+ _("Unexpected start tag (%(name))" +
+ " in the after frameset phase. Ignored."),
+ "unexpected-end-tag-after-frameset" =>
+ _("Unexpected end tag (%(name))" +
+ " in the after frameset phase. Ignored."),
+ "expected-eof-but-got-char" =>
+ _("Unexpected non-space characters. Expected end of file."),
+ "expected-eof-but-got-start-tag" =>
+ _("Unexpected start tag (%(name))" +
+ ". Expected end of file."),
+ "expected-eof-but-got-end-tag" =>
+ _("Unexpected end tag (%(name))" +
+ ". Expected end of file."),
+ }
+
end
diff --git a/vendor/plugins/HTML5lib/lib/html5/filters/iso639codes.rb b/vendor/plugins/HTML5lib/lib/html5/filters/iso639codes.rb
new file mode 100755
index 00000000..ce3c9623
--- /dev/null
+++ b/vendor/plugins/HTML5lib/lib/html5/filters/iso639codes.rb
@@ -0,0 +1,752 @@
+# borrowed from feedvalidator, original copyright license is
+#
+# Copyright (c) 2002-2006, Sam Ruby, Mark Pilgrim, Joseph Walton, and Phil Ringnalda
+#
+# Permission is hereby granted, free of charge, to any person obtaining a copy
+# of this software and associated documentation files (the "Software"), to deal
+# in the Software without restriction, including without limitation the rights
+# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+# copies of the Software, and to permit persons to whom the Software is
+# furnished to do so, subject to the following conditions:
+#
+# The above copyright notice and this permission notice shall be included in all
+# copies or substantial portions of the Software.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+# SOFTWARE.
+
+ISO_LANG = {
+ 'aa' => 'Afar',
+ 'ab' => 'Abkhazian',
+ 'ae' => 'Avestan',
+ 'af' => 'Afrikaans',
+ 'ak' => 'Akan',
+ 'am' => 'Amharic',
+ 'an' => 'Aragonese',
+ 'ar' => 'Arabic',
+ 'as' => 'Assamese',
+ 'av' => 'Avaric',
+ 'ay' => 'Aymara',
+ 'az' => 'Azerbaijani',
+ 'ba' => 'Bashkir',
+ 'be' => 'Byelorussian',
+ 'bg' => 'Bulgarian',
+ 'bh' => 'Bihari',
+ 'bi' => 'Bislama',
+ 'bm' => 'Bambara',
+ 'bn' => 'Bengali;Bangla',
+ 'bo' => 'Tibetan',
+ 'br' => 'Breton',
+ 'bs' => 'Bosnian',
+ 'ca' => 'Catalan',
+ 'ce' => 'Chechen',
+ 'ch' => 'Chamorro',
+ 'co' => 'Corsican',
+ 'cr' => 'Cree',
+ 'cs' => 'Czech',
+ 'cu' => 'Church Slavic',
+ 'cv' => 'Chuvash',
+ 'cy' => 'Welsh',
+ 'da' => 'Danish',
+ 'de' => 'German',
+ 'dv' => 'Divehi',
+ 'dz' => 'Dzongkha',
+ 'ee' => 'Ewe',
+ 'el' => 'Greek',
+ 'en' => 'English',
+ 'eo' => 'Esperanto',
+ 'es' => 'Spanish',
+ 'et' => 'Estonian',
+ 'eu' => 'Basque',
+ 'fa' => 'Persian (Farsi)',
+ 'ff' => 'Fulah',
+ 'fi' => 'Finnish',
+ 'fj' => 'Fiji',
+ 'fo' => 'Faroese',
+ 'fr' => 'French',
+ 'fy' => 'Frisian, Western',
+ 'ga' => 'Irish',
+ 'gd' => 'Scots Gaelic',
+ 'gl' => 'Galician',
+ 'gn' => 'Guarani',
+ 'gu' => 'Gujarati',
+ 'gv' => 'Manx',
+ 'ha' => 'Hausa',
+ 'he' => 'Hebrew',
+ 'hi' => 'Hindi',
+ 'ho' => 'Hiri Motu',
+ 'hr' => 'Croatian',
+ 'ht' => 'Haitian',
+ 'hu' => 'Hungarian',
+ 'hy' => 'Armenian',
+ 'hz' => 'Herero',
+ 'ia' => 'Interlingua',
+ 'id' => 'Indonesian',
+ 'ie' => 'Interlingue',
+ 'ig' => 'Igbo',
+ 'ii' => 'Sichuan Yi',
+ 'ik' => 'Inupiak',
+ 'io' => 'Ido',
+ 'is' => 'Icelandic',
+ 'it' => 'Italian',
+ 'iu' => 'Inuktitut',
+ 'ja' => 'Japanese',
+ 'jv' => 'Javanese',
+ 'ka' => 'Georgian',
+ 'kg' => 'Kongo',
+ 'ki' => 'Kikuyu; Gikuyu',
+ 'kj' => 'Kuanyama; Kwanyama',
+ 'kk' => 'Kazakh',
+ 'kl' => 'Greenlandic',
+ 'km' => 'Cambodian',
+ 'kn' => 'Kannada',
+ 'ko' => 'Korean',
+ 'kr' => 'Kanuri',
+ 'ks' => 'Kashmiri',
+ 'ku' => 'Kurdish',
+ 'kv' => 'Komi',
+ 'kw' => 'Cornish',
+ 'ky' => 'Kirghiz',
+ 'la' => 'Latin',
+ 'lb' => 'Letzeburgesch; Luxembourgish',
+ 'lg' => 'Ganda',
+ 'li' => 'Limburgan; Limburger, Limburgish',
+ 'ln' => 'Lingala',
+ 'lo' => 'Lao',
+ 'lt' => 'Lithuanian',
+ 'lu' => 'Luba-Katanga',
+ 'lv' => 'Latvian',
+ 'mg' => 'Malagasy',
+ 'mh' => 'Marshallese',
+ 'mi' => 'Maori',
+ 'mk' => 'Macedonian',
+ 'ml' => 'Malayalam',
+ 'mn' => 'Mongolian',
+ 'mo' => 'Moldavian',
+ 'mr' => 'Marathi',
+ 'ms' => 'Malay',
+ 'mt' => 'Maltese',
+ 'my' => 'Burmese',
+ 'na' => 'Nauru',
+ 'nb' => 'Norwegian Bokmal',
+ 'nd' => 'Ndebele, North',
+ 'ne' => 'Nepali',
+ 'ng' => 'Ndonga',
+ 'nl' => 'Dutch',
+ 'nn' => 'Norwegian Nynorsk',
+ 'no' => 'Norwegian',
+ 'nr' => 'Ndebele, South',
+ 'nv' => 'Navaho; Navajo',
+ 'ny' => 'Chewa; Chichewa; Nyanha',
+ 'oc' => 'Occitan',
+ 'oj' => 'Ojibwa',
+ 'om' => 'Afan (Oromo)',
+ 'or' => 'Oriya',
+ 'os' => 'Ossetian; Ossetic',
+ 'pa' => 'Punjabi',
+ 'pi' => 'Pali',
+ 'pl' => 'Polish',
+ 'ps' => 'Pushto',
+ 'pt' => 'Portuguese',
+ 'qu' => 'Quechua',
+ 'rm' => 'Rhaeto-Romance',
+ 'rn' => 'Kurundi',
+ 'ro' => 'Romanian',
+ 'ru' => 'Russian',
+ 'rw' => 'Kinyarwanda',
+ 'sa' => 'Sanskrit',
+ 'sc' => 'Sardinian',
+ 'sd' => 'Sindhi',
+ 'se' => 'Northern Sami',
+ 'sg' => 'Sangho',
+ 'sh' => 'Serbo-Croatian',
+ 'si' => 'Singhalese',
+ 'sk' => 'Slovak',
+ 'sl' => 'Slovenian',
+ 'sm' => 'Samoan',
+ 'sn' => 'Shona',
+ 'so' => 'Somali',
+ 'sq' => 'Albanian',
+ 'sr' => 'Serbian',
+ 'ss' => 'Swati',
+ 'st' => 'Sotho, Southern',
+ 'su' => 'Sundanese',
+ 'sv' => 'Swedish',
+ 'sw' => 'Swahili',
+ 'ta' => 'Tamil',
+ 'te' => 'Telugu',
+ 'tg' => 'Tajik',
+ 'th' => 'Thai',
+ 'ti' => 'Tigrinya',
+ 'tk' => 'Turkmen',
+ 'tl' => 'Tagalog',
+ 'tn' => 'Tswana',
+ 'to' => 'Tonga',
+ 'tr' => 'Turkish',
+ 'ts' => 'Tsonga',
+ 'tt' => 'Tatar',
+ 'tw' => 'Twi',
+ 'ty' => 'Tahitian',
+ 'ug' => 'Uigur',
+ 'uk' => 'Ukrainian',
+ 'ur' => 'Urdu',
+ 'uz' => 'Uzbek',
+ 've' => 'Venda',
+ 'vi' => 'Vietnamese',
+ 'vo' => 'Volapuk',
+ 'wa' => 'Walloon',
+ 'wo' => 'Wolof',
+ 'xh' => 'Xhosa',
+ 'yi' => 'Yiddish',
+ 'yo' => 'Yoruba',
+ 'za' => 'Zhuang',
+ 'zh' => 'Chinese',
+ 'zu' => 'Zulu',
+ 'x' => 'a user-defined language',
+ 'xx' => 'a user-defined language',
+
+ 'abk' => 'Abkhazian',
+ 'ace' => 'Achinese',
+ 'ach' => 'Acoli',
+ 'ada' => 'Adangme',
+ 'ady' => 'Adygei',
+ 'ady' => 'Adyghe',
+ 'aar' => 'Afar',
+ 'afh' => 'Afrihili',
+ 'afr' => 'Afrikaans',
+ 'afa' => 'Afro-Asiatic (Other)',
+ 'ain' => 'Ainu',
+ 'aka' => 'Akan',
+ 'akk' => 'Akkadian',
+ 'alb' => 'Albanian',
+ 'sqi' => 'Albanian',
+ 'gws' => 'Alemanic',
+ 'ale' => 'Aleut',
+ 'alg' => 'Algonquian languages',
+ 'tut' => 'Altaic (Other)',
+ 'amh' => 'Amharic',
+ 'anp' => 'Angika',
+ 'apa' => 'Apache languages',
+ 'ara' => 'Arabic',
+ 'arg' => 'Aragonese',
+ 'arc' => 'Aramaic',
+ 'arp' => 'Arapaho',
+ 'arn' => 'Araucanian',
+ 'arw' => 'Arawak',
+ 'arm' => 'Armenian',
+ 'hye' => 'Armenian',
+ 'rup' => 'Aromanian',
+ 'art' => 'Artificial (Other)',
+ 'asm' => 'Assamese',
+ 'ast' => 'Asturian',
+ 'ath' => 'Athapascan languages',
+ 'aus' => 'Australian languages',
+ 'map' => 'Austronesian (Other)',
+ 'ava' => 'Avaric',
+ 'ave' => 'Avestan',
+ 'awa' => 'Awadhi',
+ 'aym' => 'Aymara',
+ 'aze' => 'Azerbaijani',
+ 'ast' => 'Bable',
+ 'ban' => 'Balinese',
+ 'bat' => 'Baltic (Other)',
+ 'bal' => 'Baluchi',
+ 'bam' => 'Bambara',
+ 'bai' => 'Bamileke languages',
+ 'bad' => 'Banda',
+ 'bnt' => 'Bantu (Other)',
+ 'bas' => 'Basa',
+ 'bak' => 'Bashkir',
+ 'baq' => 'Basque',
+ 'eus' => 'Basque',
+ 'btk' => 'Batak (Indonesia)',
+ 'bej' => 'Beja',
+ 'bel' => 'Belarusian',
+ 'bem' => 'Bemba',
+ 'ben' => 'Bengali',
+ 'ber' => 'Berber (Other)',
+ 'bho' => 'Bhojpuri',
+ 'bih' => 'Bihari',
+ 'bik' => 'Bikol',
+ 'byn' => 'Bilin',
+ 'bin' => 'Bini',
+ 'bis' => 'Bislama',
+ 'byn' => 'Blin',
+ 'nob' => 'Bokmal, Norwegian',
+ 'bos' => 'Bosnian',
+ 'bra' => 'Braj',
+ 'bre' => 'Breton',
+ 'bug' => 'Buginese',
+ 'bul' => 'Bulgarian',
+ 'bua' => 'Buriat',
+ 'bur' => 'Burmese',
+ 'mya' => 'Burmese',
+ 'cad' => 'Caddo',
+ 'car' => 'Carib',
+ 'spa' => 'Castilian',
+ 'cat' => 'Catalan',
+ 'cau' => 'Caucasian (Other)',
+ 'ceb' => 'Cebuano',
+ 'cel' => 'Celtic (Other)',
+ 'cai' => 'Central American Indian (Other)',
+ 'chg' => 'Chagatai',
+ 'cmc' => 'Chamic languages',
+ 'cha' => 'Chamorro',
+ 'che' => 'Chechen',
+ 'chr' => 'Cherokee',
+ 'nya' => 'Chewa',
+ 'chy' => 'Cheyenne',
+ 'chb' => 'Chibcha',
+ 'nya' => 'Chichewa',
+ 'chi' => 'Chinese',
+ 'zho' => 'Chinese',
+ 'chn' => 'Chinook jargon',
+ 'chp' => 'Chipewyan',
+ 'cho' => 'Choctaw',
+ 'zha' => 'Chuang',
+ 'chu' => 'Church Slavic; Church Slavonic; Old Church Slavonic; Old Church Slavic; Old Bulgarian',
+ 'chk' => 'Chuukese',
+ 'chv' => 'Chuvash',
+ 'nwc' => 'Classical Nepal Bhasa; Classical Newari; Old Newari',
+ 'cop' => 'Coptic',
+ 'cor' => 'Cornish',
+ 'cos' => 'Corsican',
+ 'cre' => 'Cree',
+ 'mus' => 'Creek',
+ 'crp' => 'Creoles and pidgins(Other)',
+ 'cpe' => 'Creoles and pidgins, English-based (Other)',
+ 'cpf' => 'Creoles and pidgins, French-based (Other)',
+ 'cpp' => 'Creoles and pidgins, Portuguese-based (Other)',
+ 'crh' => 'Crimean Tatar; Crimean Turkish',
+ 'scr' => 'Croatian',
+ 'hrv' => 'Croatian',
+ 'cus' => 'Cushitic (Other)',
+ 'cze' => 'Czech',
+ 'ces' => 'Czech',
+ 'dak' => 'Dakota',
+ 'dan' => 'Danish',
+ 'dar' => 'Dargwa',
+ 'day' => 'Dayak',
+ 'del' => 'Delaware',
+ 'din' => 'Dinka',
+ 'div' => 'Divehi',
+ 'doi' => 'Dogri',
+ 'dgr' => 'Dogrib',
+ 'dra' => 'Dravidian (Other)',
+ 'dua' => 'Duala',
+ 'dut' => 'Dutch',
+ 'nld' => 'Dutch',
+ 'dum' => 'Dutch, Middle (ca. 1050-1350)',
+ 'dyu' => 'Dyula',
+ 'dzo' => 'Dzongkha',
+ 'efi' => 'Efik',
+ 'egy' => 'Egyptian (Ancient)',
+ 'eka' => 'Ekajuk',
+ 'elx' => 'Elamite',
+ 'eng' => 'English',
+ 'enm' => 'English, Middle (1100-1500)',
+ 'ang' => 'English, Old (ca.450-1100)',
+ 'myv' => 'Erzya',
+ 'epo' => 'Esperanto',
+ 'est' => 'Estonian',
+ 'ewe' => 'Ewe',
+ 'ewo' => 'Ewondo',
+ 'fan' => 'Fang',
+ 'fat' => 'Fanti',
+ 'fao' => 'Faroese',
+ 'fij' => 'Fijian',
+ 'fil' => 'Filipino; Pilipino',
+ 'fin' => 'Finnish',
+ 'fiu' => 'Finno-Ugrian (Other)',
+ 'fon' => 'Fon',
+ 'fre' => 'French',
+ 'fra' => 'French',
+ 'frm' => 'French, Middle (ca.1400-1600)',
+ 'fro' => 'French, Old (842-ca.1400)',
+ 'frs' => 'Frisian, Eastern',
+ 'fry' => 'Frisian, Western',
+ 'fur' => 'Friulian',
+ 'ful' => 'Fulah',
+ 'gaa' => 'Ga',
+ 'gla' => 'Gaelic',
+ 'glg' => 'Gallegan',
+ 'lug' => 'Ganda',
+ 'gay' => 'Gayo',
+ 'gba' => 'Gbaya',
+ 'gez' => 'Geez',
+ 'geo' => 'Georgian',
+ 'kat' => 'Georgian',
+ 'ger' => 'German',
+ 'deu' => 'German',
+ 'nds' => 'German, Low',
+ 'gmh' => 'German, Middle High (ca.1050-1500)',
+ 'goh' => 'German, Old High (ca.750-1050)',
+ 'gem' => 'Germanic (Other)',
+ 'kik' => 'Gikuyu',
+ 'gil' => 'Gilbertese',
+ 'gon' => 'Gondi',
+ 'gor' => 'Gorontalo',
+ 'got' => 'Gothic',
+ 'grb' => 'Grebo',
+ 'grc' => 'Greek, Ancient (to 1453)',
+ 'gre' => 'Greek, Modern (1453-)',
+ 'ell' => 'Greek, Modern (1453-)',
+ 'kal' => 'Greenlandic; Kalaallisut',
+ 'grn' => 'Guarani',
+ 'guj' => 'Gujarati',
+ 'gwi' => 'Gwich\'in',
+ 'hai' => 'Haida',
+ 'hat' => 'Haitian',
+ 'hau' => 'Hausa',
+ 'haw' => 'Hawaiian',
+ 'heb' => 'Hebrew',
+ 'her' => 'Herero',
+ 'hil' => 'Hiligaynon',
+ 'him' => 'Himachali',
+ 'hin' => 'Hindi',
+ 'hmo' => 'Hiri Motu',
+ 'hit' => 'Hittite',
+ 'hmn' => 'Hmong',
+ 'hun' => 'Hungarian',
+ 'hup' => 'Hupa',
+ 'iba' => 'Iban',
+ 'ice' => 'Icelandic',
+ 'isl' => 'Icelandic',
+ 'ido' => 'Ido',
+ 'ibo' => 'Igbo',
+ 'ijo' => 'Ijo',
+ 'ilo' => 'Iloko',
+ 'smn' => 'Inari Sami',
+ 'inc' => 'Indic (Other)',
+ 'ine' => 'Indo-European (Other)',
+ 'ind' => 'Indonesian',
+ 'inh' => 'Ingush',
+ 'ina' => 'Interlingua (International Auxiliary Language Association)',
+ 'ile' => 'Interlingue',
+ 'iku' => 'Inuktitut',
+ 'ipk' => 'Inupiaq',
+ 'ira' => 'Iranian (Other)',
+ 'gle' => 'Irish',
+ 'mga' => 'Irish, Middle (900-1200)',
+ 'sga' => 'Irish, Old (to 900)',
+ 'iro' => 'Iroquoian languages',
+ 'ita' => 'Italian',
+ 'jpn' => 'Japanese',
+ 'jav' => 'Javanese',
+ 'jrb' => 'Judeo-Arabic',
+ 'jpr' => 'Judeo-Persian',
+ 'kbd' => 'Kabardian',
+ 'kab' => 'Kabyle',
+ 'kac' => 'Kachin',
+ 'kal' => 'Kalaallisut',
+ 'xal' => 'Kalmyk',
+ 'kam' => 'Kamba',
+ 'kan' => 'Kannada',
+ 'kau' => 'Kanuri',
+ 'krc' => 'Karachay-Balkar',
+ 'kaa' => 'Kara-Kalpak',
+ 'krl' => 'Karelian',
+ 'kar' => 'Karen',
+ 'kas' => 'Kashmiri',
+ 'csb' => 'Kashubian',
+ 'kaw' => 'Kawi',
+ 'kaz' => 'Kazakh',
+ 'kha' => 'Khasi',
+ 'khm' => 'Khmer',
+ 'khi' => 'Khoisan (Other)',
+ 'kho' => 'Khotanese',
+ 'kik' => 'Kikuyu',
+ 'kmb' => 'Kimbundu',
+ 'kin' => 'Kinyarwanda',
+ 'kir' => 'Kirghiz',
+ 'tlh' => 'Klingon; tlhIngan-Hol',
+ 'kom' => 'Komi',
+ 'kon' => 'Kongo',
+ 'kok' => 'Konkani',
+ 'kor' => 'Korean',
+ 'kos' => 'Kosraean',
+ 'kpe' => 'Kpelle',
+ 'kro' => 'Kru',
+ 'kua' => 'Kuanyama',
+ 'kum' => 'Kumyk',
+ 'kur' => 'Kurdish',
+ 'kru' => 'Kurukh',
+ 'kut' => 'Kutenai',
+ 'kua' => 'Kwanyama',
+ 'lad' => 'Ladino',
+ 'lah' => 'Lahnda',
+ 'lam' => 'Lamba',
+ 'lao' => 'Lao',
+ 'lat' => 'Latin',
+ 'lav' => 'Latvian',
+ 'ltz' => 'Letzeburgesch',
+ 'lez' => 'Lezghian',
+ 'lim' => 'Limburgan',
+ 'lin' => 'Lingala',
+ 'lit' => 'Lithuanian',
+ 'jbo' => 'Lojban',
+ 'nds' => 'Low German',
+ 'dsb' => 'Lower Sorbian',
+ 'loz' => 'Lozi',
+ 'lub' => 'Luba-Katanga',
+ 'lua' => 'Luba-Lulua',
+ 'lui' => 'Luiseno',
+ 'smj' => 'Lule Sami',
+ 'lun' => 'Lunda',
+ 'luo' => 'Luo (Kenya and Tanzania)',
+ 'lus' => 'Lushai',
+ 'ltz' => 'Luxembourgish',
+ 'mac' => 'Macedonian',
+ 'mkd' => 'Macedonian',
+ 'mad' => 'Madurese',
+ 'mag' => 'Magahi',
+ 'mai' => 'Maithili',
+ 'mak' => 'Makasar',
+ 'mlg' => 'Malagasy',
+ 'may' => 'Malay',
+ 'msa' => 'Malay',
+ 'mal' => 'Malayalam',
+ 'mlt' => 'Maltese',
+ 'mnc' => 'Manchu',
+ 'mdr' => 'Mandar',
+ 'man' => 'Mandingo',
+ 'mni' => 'Manipuri',
+ 'mno' => 'Manobo languages',
+ 'glv' => 'Manx',
+ 'mao' => 'Maori',
+ 'mri' => 'Maori',
+ 'mar' => 'Marathi',
+ 'chm' => 'Mari',
+ 'mah' => 'Marshallese',
+ 'mwr' => 'Marwari',
+ 'mas' => 'Masai',
+ 'myn' => 'Mayan languages',
+ 'men' => 'Mende',
+ 'mic' => 'Micmac',
+ 'min' => 'Minangkabau',
+ 'mwl' => 'Mirandese',
+ 'mis' => 'Miscellaneous languages',
+ 'moh' => 'Mohawk',
+ 'mdf' => 'Moksha',
+ 'mol' => 'Moldavian',
+ 'mkh' => 'Mon-Khmer (Other)',
+ 'lol' => 'Mongo',
+ 'mon' => 'Mongolian',
+ 'mos' => 'Mossi',
+ 'mul' => 'Multiple languages',
+ 'mun' => 'Munda languages',
+ 'nah' => 'Nahuatl',
+ 'nau' => 'Nauru',
+ 'nav' => 'Navaho; Navajo',
+ 'nde' => 'Ndebele, North',
+ 'nbl' => 'Ndebele, South',
+ 'ndo' => 'Ndonga',
+ 'nap' => 'Neapolitan',
+ 'nep' => 'Nepali',
+ 'new' => 'Newari',
+ 'nia' => 'Nias',
+ 'nic' => 'Niger-Kordofanian (Other)',
+ 'ssa' => 'Nilo-Saharan (Other)',
+ 'niu' => 'Niuean',
+ 'nog' => 'Nogai',
+ 'non' => 'Norse, Old',
+ 'nai' => 'North American Indian (Other)',
+ 'frr' => 'Northern Frisian',
+ 'sme' => 'Northern Sami',
+ 'nso' => 'Northern Sotho; Pedi; Sepedi',
+ 'nde' => 'North Ndebele',
+ 'nor' => 'Norwegian',
+ 'nob' => 'Norwegian Bokmal',
+ 'nno' => 'Norwegian Nynorsk',
+ 'nub' => 'Nubian languages',
+ 'nym' => 'Nyamwezi',
+ 'nya' => 'Nyanja',
+ 'nyn' => 'Nyankole',
+ 'nno' => 'Nynorsk, Norwegian',
+ 'nyo' => 'Nyoro',
+ 'nzi' => 'Nzima',
+ 'oci' => 'Occitan (post 1500)',
+ 'oji' => 'Ojibwa',
+ 'ori' => 'Oriya',
+ 'orm' => 'Oromo',
+ 'osa' => 'Osage',
+ 'oss' => 'Ossetian; Ossetic',
+ 'oto' => 'Otomian languages',
+ 'pal' => 'Pahlavi',
+ 'pau' => 'Palauan',
+ 'pli' => 'Pali',
+ 'pam' => 'Pampanga',
+ 'pag' => 'Pangasinan',
+ 'pan' => 'Panjabi',
+ 'pap' => 'Papiamento',
+ 'paa' => 'Papuan (Other)',
+ 'per' => 'Persian',
+ 'fas' => 'Persian',
+ 'peo' => 'Persian, Old (ca.600-400)',
+ 'phi' => 'Philippine (Other)',
+ 'phn' => 'Phoenician',
+ 'pon' => 'Pohnpeian',
+ 'pol' => 'Polish',
+ 'por' => 'Portuguese',
+ 'pra' => 'Prakrit languages',
+ 'oci' => 'Provencal',
+ 'pro' => 'Provencal, Old (to 1500)',
+ 'pan' => 'Punjabi',
+ 'pus' => 'Pushto',
+ 'que' => 'Quechua',
+ 'roh' => 'Raeto-Romance',
+ 'raj' => 'Rajasthani',
+ 'rap' => 'Rapanui',
+ 'rar' => 'Rarotongan',
+ 'qaa' => 'Reserved for local use',
+ 'qtz' => 'Reserved for local use',
+ 'roa' => 'Romance (Other)',
+ 'rum' => 'Romanian',
+ 'ron' => 'Romanian',
+ 'rom' => 'Romany',
+ 'run' => 'Rundi',
+ 'rus' => 'Russian',
+ 'sal' => 'Salishan languages',
+ 'sam' => 'Samaritan Aramaic',
+ 'smi' => 'Sami languages (Other)',
+ 'smo' => 'Samoan',
+ 'sad' => 'Sandawe',
+ 'sag' => 'Sango',
+ 'san' => 'Sanskrit',
+ 'sat' => 'Santali',
+ 'srd' => 'Sardinian',
+ 'sas' => 'Sasak',
+ 'nds' => 'Saxon, Low',
+ 'sco' => 'Scots',
+ 'gla' => 'Scottish Gaelic',
+ 'sel' => 'Selkup',
+ 'sem' => 'Semitic (Other)',
+ 'nso' => 'Sepedi; Northern Sotho; Pedi',
+ 'scc' => 'Serbian',
+ 'srp' => 'Serbian',
+ 'srr' => 'Serer',
+ 'shn' => 'Shan',
+ 'sna' => 'Shona',
+ 'iii' => 'Sichuan Yi',
+ 'scn' => 'Sicilian',
+ 'sid' => 'Sidamo',
+ 'sgn' => 'Sign languages',
+ 'bla' => 'Siksika',
+ 'snd' => 'Sindhi',
+ 'sin' => 'Sinhalese',
+ 'sit' => 'Sino-Tibetan (Other)',
+ 'sio' => 'Siouan languages',
+ 'sms' => 'Skolt Sami',
+ 'den' => 'Slave (Athapascan)',
+ 'sla' => 'Slavic (Other)',
+ 'slo' => 'Slovak',
+ 'slk' => 'Slovak',
+ 'slv' => 'Slovenian',
+ 'sog' => 'Sogdian',
+ 'som' => 'Somali',
+ 'son' => 'Songhai',
+ 'snk' => 'Soninke',
+ 'wen' => 'Sorbian languages',
+ 'nso' => 'Sotho, Northern',
+ 'sot' => 'Sotho, Southern',
+ 'sai' => 'South American Indian (Other)',
+ 'alt' => 'Southern Altai',
+ 'sma' => 'Southern Sami',
+ 'nbl' => 'South Ndebele',
+ 'spa' => 'Spanish',
+ 'srn' => 'Sranan Tongo',
+ 'suk' => 'Sukuma',
+ 'sux' => 'Sumerian',
+ 'sun' => 'Sundanese',
+ 'sus' => 'Susu',
+ 'swa' => 'Swahili',
+ 'ssw' => 'Swati',
+ 'swe' => 'Swedish',
+ 'gsw' => 'Swiss German; Alemanic',
+ 'syr' => 'Syriac',
+ 'tgl' => 'Tagalog',
+ 'tah' => 'Tahitian',
+ 'tai' => 'Tai (Other)',
+ 'tgk' => 'Tajik',
+ 'tmh' => 'Tamashek',
+ 'tam' => 'Tamil',
+ 'tat' => 'Tatar',
+ 'tel' => 'Telugu',
+ 'ter' => 'Tereno',
+ 'tet' => 'Tetum',
+ 'tha' => 'Thai',
+ 'tib' => 'Tibetan',
+ 'bod' => 'Tibetan',
+ 'tig' => 'Tigre',
+ 'tir' => 'Tigrinya',
+ 'tem' => 'Timne',
+ 'tiv' => 'Tiv',
+ 'tlh' => 'tlhIngan-Hol; Klingon',
+ 'tli' => 'Tlingit',
+ 'tpi' => 'Tok Pisin',
+ 'tkl' => 'Tokelau',
+ 'tog' => 'Tonga (Nyasa)',
+ 'ton' => 'Tonga (Tonga Islands)',
+ 'tsi' => 'Tsimshian',
+ 'tso' => 'Tsonga',
+ 'tsn' => 'Tswana',
+ 'tum' => 'Tumbuka',
+ 'tup' => 'Tupi languages',
+ 'tur' => 'Turkish',
+ 'ota' => 'Turkish, Ottoman (1500-1928)',
+ 'tuk' => 'Turkmen',
+ 'tvl' => 'Tuvalu',
+ 'tyv' => 'Tuvinian',
+ 'twi' => 'Twi',
+ 'udm' => 'Udmurt',
+ 'uga' => 'Ugaritic',
+ 'uig' => 'Uighur',
+ 'ukr' => 'Ukrainian',
+ 'umb' => 'Umbundu',
+ 'und' => 'Undetermined',
+ 'hsb' => 'Upper Sorbian',
+ 'urd' => 'Urdu',
+ 'uzb' => 'Uzbek',
+ 'vai' => 'Vai',
+ 'cat' => 'Valencian',
+ 'ven' => 'Venda',
+ 'vie' => 'Vietnamese',
+ 'vol' => 'Volapuk',
+ 'vot' => 'Votic',
+ 'wak' => 'Wakashan languages',
+ 'wal' => 'Walamo',
+ 'wln' => 'Walloon',
+ 'war' => 'Waray',
+ 'was' => 'Washo',
+ 'wel' => 'Welsh',
+ 'cym' => 'Welsh',
+ 'fry' => 'Wester Frisian',
+ 'wol' => 'Wolof',
+ 'xho' => 'Xhosa',
+ 'sah' => 'Yakut',
+ 'yao' => 'Yao',
+ 'yap' => 'Yapese',
+ 'yid' => 'Yiddish',
+ 'yor' => 'Yoruba',
+ 'ypk' => 'Yupik languages',
+ 'znd' => 'Zande',
+ 'zap' => 'Zapotec',
+ 'zen' => 'Zenaga',
+ 'zha' => 'Zhuang',
+ 'zul' => 'Zulu',
+ 'zun' => 'Zuni'
+}
+
+def is_valid_lang_code(value)
+ if value.include? '-'
+ lang, sublang = value.split('-', 2)
+ else
+ lang = value
+ end
+ !!ISO_LANG[lang.downcase]
+end
\ No newline at end of file
diff --git a/vendor/plugins/HTML5lib/lib/html5/filters/rfc2046.rb b/vendor/plugins/HTML5lib/lib/html5/filters/rfc2046.rb
new file mode 100755
index 00000000..593baf42
--- /dev/null
+++ b/vendor/plugins/HTML5lib/lib/html5/filters/rfc2046.rb
@@ -0,0 +1,30 @@
+# adapted from feedvalidator, original copyright license is
+#
+# Copyright (c) 2002-2006, Sam Ruby, Mark Pilgrim, Joseph Walton, and Phil Ringnalda
+#
+# Permission is hereby granted, free of charge, to any person obtaining a copy
+# of this software and associated documentation files (the "Software"), to deal
+# in the Software without restriction, including without limitation the rights
+# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+# copies of the Software, and to permit persons to whom the Software is
+# furnished to do so, subject to the following conditions:
+#
+# The above copyright notice and this permission notice shall be included in all
+# copies or substantial portions of the Software.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+# SOFTWARE.
+
+
+# mime_re = Regexp.new('[^\s()<>,;:\\"/[\]?=]+/[^\s()<>,;:\\"/[\]?=]+(\s*;\s*[^\s()<>,;:\\"/[\]?=]+=("(\\"|[^"])*"|[^\s()<>,;:\\"/[\]?=]+))*$')
+
+def is_valid_mime_type(value)
+ # !!mime_re.match(value)
+ true
+end
+
diff --git a/vendor/plugins/HTML5lib/lib/html5/filters/rfc3987.rb b/vendor/plugins/HTML5lib/lib/html5/filters/rfc3987.rb
new file mode 100755
index 00000000..bf730e06
--- /dev/null
+++ b/vendor/plugins/HTML5lib/lib/html5/filters/rfc3987.rb
@@ -0,0 +1,89 @@
+# adapted from feedvalidator, original copyright license is
+#
+# Copyright (c) 2002-2006, Sam Ruby, Mark Pilgrim, Joseph Walton, and Phil Ringnalda
+#
+# Permission is hereby granted, free of charge, to any person obtaining a copy
+# of this software and associated documentation files (the "Software"), to deal
+# in the Software without restriction, including without limitation the rights
+# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+# copies of the Software, and to permit persons to whom the Software is
+# furnished to do so, subject to the following conditions:
+#
+# The above copyright notice and this permission notice shall be included in all
+# copies or substantial portions of the Software.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+# SOFTWARE.
+
+iana_schemes = [ # http://www.iana.org/assignments/uri-schemes.html
+ "ftp", "http", "gopher", "mailto", "news", "nntp", "telnet", "wais",
+ "file", "prospero", "z39.50s", "z39.50r", "cid", "mid", "vemmi",
+ "service", "imap", "nfs", "acap", "rtsp", "tip", "pop", "data", "dav",
+ "opaquelocktoken", "sip", "sips", "tel", "fax", "modem", "ldap",
+ "https", "soap.beep", "soap.beeps", "xmlrpc.beep", "xmlrpc.beeps",
+ "urn", "go", "h323", "ipp", "tftp", "mupdate", "pres", "im", "mtqp",
+ "iris.beep", "dict", "snmp", "crid", "tag", "dns", "info"
+]
+ALLOWED_SCHEMES = iana_schemes + ['javascript']
+
+RFC2396 = Regexp.new("^([a-zA-Z][0-9a-zA-Z+\\-\\.]*:)?/{0,2}[0-9a-zA-Z;/?:@&=+$\\.\\-_!~*'()%,#]*$", Regexp::MULTILINE)
+rfc2396_full = Regexp.new("[a-zA-Z][0-9a-zA-Z+\\-\\.]*:(//)?[0-9a-zA-Z;/?:@&=+$\\.\\-_!~*'()%,#]+$")
+URN = Regexp.new("^[Uu][Rr][Nn]:[a-zA-Z0-9][a-zA-Z0-9-]{1,31}:([a-zA-Z0-9()+,\.:=@;$_!*'\-]|%[0-9A-Fa-f]{2})+$")
+TAG = Regexp.new("^tag:([a-z0-9\\-\._]+?@)?[a-z0-9\.\-]+?,\d{4}(-\d{2}(-\d{2})?)?:[0-9a-zA-Z;/\?:@&=+$\.\-_!~*'\(\)%,]*(#[0-9a-zA-Z;/\?:@&=+$\.\-_!~*'\(\)%,]*)?$")
+
+def is_valid_uri(value, uri_pattern = RFC2396)
+ scheme = value.split(':').first
+ scheme.downcase! if scheme
+ if scheme == 'tag'
+ if !TAG.match(value)
+ return false, "invalid-tag-uri"
+ end
+ elsif scheme == "urn"
+ if !URN.match(value)
+ return false, "invalid-urn"
+ end
+ elsif uri_pattern.match(value).to_a.reject{|i| i == ''}.compact.length == 0 || uri_pattern.match(value)[0] != value
+ urichars = Regexp.new("^[0-9a-zA-Z;/?:@&=+$\\.\\-_!~*'()%,#]$", Regexp::MULTILINE)
+ if value.length > 0
+ value.each_byte do |b|
+ if b < 128 and !urichars.match([b].pack('c*'))
+ return false, "invalid-uri-char"
+ end
+ end
+ else
+ begin
+ if uri_pattern.match(value.encode('idna'))
+ return false, "uri-not-iri"
+ end
+ rescue
+ end
+ return false, "invalid-uri"
+ end
+ elsif ['http','ftp'].include?(scheme)
+ if !value.match(%r{^\w+://[^/].*})
+ return false, "invalid-http-or-ftp-uri"
+ end
+ elsif value.index(':') && scheme.match(/^[a-z]+$/) && !ALLOWED_SCHEMES.include?(scheme)
+ return false, "invalid-scheme"
+ end
+ return true, ""
+end
+
+def is_valid_iri(value)
+ begin
+ if value.length > 0
+ value = value.encode('idna')
+ end
+ rescue
+ end
+ is_valid_uri(value)
+end
+
+def is_valid_fully_qualified_uri(value)
+ is_valid_uri(value, rfc2396_full)
+end
diff --git a/vendor/plugins/HTML5lib/lib/html5/filters/validator.rb b/vendor/plugins/HTML5lib/lib/html5/filters/validator.rb
new file mode 100755
index 00000000..99e67baa
--- /dev/null
+++ b/vendor/plugins/HTML5lib/lib/html5/filters/validator.rb
@@ -0,0 +1,830 @@
+# HTML 5 conformance checker
+#
+# Warning: this module is experimental, incomplete, and subject to removal at any time.
+#
+# Usage:
+# >>> from html5lib.html5parser import HTMLParser
+# >>> from html5lib.filters.validator import HTMLConformanceChecker
+# >>> p = HTMLParser(tokenizer=HTMLConformanceChecker)
+# >>> p.parse('\n')
+# < nil>
+# >>> p.errors
+# [((2, 14), 'unknown-attribute', {'attributeName' => u'foo', 'tagName' => u'html'})]
+
+require 'html5/constants'
+require 'html5/filters/base'
+require 'html5/filters/iso639codes'
+require 'html5/filters/rfc3987'
+require 'html5/filters/rfc2046'
+
+def _(str); str; end
+
+class String
+ # lifted from rails
+ def underscore()
+ self.gsub(/::/, '/').
+ gsub(/([A-Z]+)([A-Z][a-z])/,'\1_\2').
+ gsub(/([a-z\d])([A-Z])/,'\1_\2').
+ tr("-", "_").
+ downcase
+ end
+end
+
+HTML5::E.update({
+ "unknown-start-tag" =>
+ _("Unknown start tag <%(tagName)>."),
+ "unknown-attribute" =>
+ _("Unknown '%(attributeName)' attribute on <%(tagName)>."),
+ "missing-required-attribute" =>
+ _("The '%(attributeName)' attribute is required on <%(tagName)>."),
+ "unknown-input-type" =>
+ _("Illegal value for attribute on ."),
+ "attribute-not-allowed-on-this-input-type" =>
+ _("The '%(attributeName)' attribute is not allowed on ."),
+ "deprecated-attribute" =>
+ _("This attribute is deprecated: '%(attributeName)' attribute on <%(tagName)>."),
+ "duplicate-value-in-token-list" =>
+ _("Duplicate value in token list: '%(attributeValue)' in '%(attributeName)' attribute on <%(tagName)>."),
+ "invalid-attribute-value" =>
+ _("Invalid attribute value: '%(attributeName)' attribute on <%(tagName)>."),
+ "space-in-id" =>
+ _("Whitespace is not allowed here: '%(attributeName)' attribute on <%(tagName)>."),
+ "duplicate-id" =>
+ _("This ID was already defined earlier: 'id' attribute on <%(tagName)>."),
+ "attribute-value-can-not-be-blank" =>
+ _("This value can not be blank: '%(attributeName)' attribute on <%(tagName)>."),
+ "id-does-not-exist" =>
+ _("This value refers to a non-existent ID: '%(attributeName)' attribute on <%(tagName)>."),
+ "invalid-enumerated-value" =>
+ _("Value must be one of %(enumeratedValues): '%(attributeName)' attribute on <%tagName)>."),
+ "invalid-boolean-value" =>
+ _("Value must be one of %(enumeratedValues): '%(attributeName)' attribute on <%tagName)>."),
+ "contextmenu-must-point-to-menu" =>
+ _("The contextmenu attribute must point to an ID defined on a element."),
+ "invalid-lang-code" =>
+ _("Invalid language code: '%(attributeName)' attibute on <%(tagName)>."),
+ "invalid-integer-value" =>
+ _("Value must be an integer: '%(attributeName)' attribute on <%tagName)>."),
+ "invalid-root-namespace" =>
+ _("Root namespace must be 'http://www.w3.org/1999/xhtml', or omitted."),
+ "invalid-browsing-context" =>
+ _("Value must be one of ('_self', '_parent', '_top'), or a name that does not start with '_' => '%(attributeName)' attribute on <%(tagName)>."),
+ "invalid-tag-uri" =>
+ _("Invalid URI: '%(attributeName)' attribute on <%(tagName)>."),
+ "invalid-urn" =>
+ _("Invalid URN: '%(attributeName)' attribute on <%(tagName)>."),
+ "invalid-uri-char" =>
+ _("Illegal character in URI: '%(attributeName)' attribute on <%(tagName)>."),
+ "uri-not-iri" =>
+ _("Expected a URI but found an IRI: '%(attributeName)' attribute on <%(tagName)>."),
+ "invalid-uri" =>
+ _("Invalid URI: '%(attributeName)' attribute on <%(tagName)>."),
+ "invalid-http-or-ftp-uri" =>
+ _("Invalid URI: '%(attributeName)' attribute on <%(tagName)>."),
+ "invalid-scheme" =>
+ _("Unregistered URI scheme: '%(attributeName)' attribute on <%(tagName)>."),
+ "invalid-rel" =>
+ _("Invalid link relation: '%(attributeName)' attribute on <%(tagName)>."),
+ "invalid-mime-type" =>
+ _("Invalid MIME type: '%(attributeName)' attribute on <%(tagName)>."),
+})
+
+
+class HTMLConformanceChecker < HTML5::Filters::Base
+
+ @@global_attributes = %w[class contenteditable contextmenu dir
+ draggable id irrelevant lang ref tabindex template
+ title onabort onbeforeunload onblur onchange onclick
+ oncontextmenu ondblclick ondrag ondragend ondragenter
+ ondragleave ondragover ondragstart ondrop onerror
+ onfocus onkeydown onkeypress onkeyup onload onmessage
+ onmousedown onmousemove onmouseout onmouseover onmouseup
+ onmousewheel onresize onscroll onselect onsubmit onunload]
+ # XXX lang in HTML only, xml:lang in XHTML only
+ # XXX validate ref, template
+
+ @@allowed_attribute_map = {
+ 'html' => %w[xmlns],
+ 'head' => [],
+ 'title' => [],
+ 'base' => %w[href target],
+ 'link' => %w[href rel media hreflang type],
+ 'meta' => %w[name http-equiv content charset], # XXX charset in HTML only
+ 'style' => %w[media type scoped],
+ 'body' => [],
+ 'section' => [],
+ 'nav' => [],
+ 'article' => [],
+ 'blockquote' => %w[cite],
+ 'aside' => [],
+ 'h1' => [],
+ 'h2' => [],
+ 'h3' => [],
+ 'h4' => [],
+ 'h5' => [],
+ 'h6' => [],
+ 'header' => [],
+ 'footer' => [],
+ 'address' => [],
+ 'p' => [],
+ 'hr' => [],
+ 'br' => [],
+ 'dialog' => [],
+ 'pre' => [],
+ 'ol' => %w[start],
+ 'ul' => [],
+ 'li' => %w[value], # XXX depends on parent
+ 'dl' => [],
+ 'dt' => [],
+ 'dd' => [],
+ 'a' => %w[href target ping rel media hreflang type],
+ 'q' => %w[cite],
+ 'cite' => [],
+ 'em' => [],
+ 'strong' => [],
+ 'small' => [],
+ 'm' => [],
+ 'dfn' => [],
+ 'abbr' => [],
+ 'time' => %w[datetime],
+ 'meter' => %w[value min low high max optimum],
+ 'progress' => %w[value max],
+ 'code' => [],
+ 'var' => [],
+ 'samp' => [],
+ 'kbd' => [],
+ 'sup' => [],
+ 'sub' => [],
+ 'span' => [],
+ 'i' => [],
+ 'b' => [],
+ 'bdo' => [],
+ 'ins' => %w[cite datetime],
+ 'del' => %w[cite datetime],
+ 'figure' => [],
+ 'img' => %w[alt src usemap ismap height width], # XXX ismap depends on parent
+ 'iframe' => %w[src],
+ # handled separately
+ 'object' => %w[data type usemap height width],
+ 'param' => %w[name value],
+ 'video' => %w[src autoplay start loopstart loopend end loopcount controls],
+ 'audio' => %w[src autoplay start loopstart loopend end loopcount controls],
+ 'source' => %w[src type media],
+ 'canvas' => %w[height width],
+ 'map' => [],
+ 'area' => %w[alt coords shape href target ping rel media hreflang type],
+ 'table' => [],
+ 'caption' => [],
+ 'colgroup' => %w[span], # XXX only if element contains no elements
+ 'col' => %w[span],
+ 'tbody' => [],
+ 'thead' => [],
+ 'tfoot' => [],
+ 'tr' => [],
+ 'td' => %w[colspan rowspan],
+ 'th' => %w[colspan rowspan scope],
+ # all possible attributes are listed here but is really handled separately
+ 'input' => %w[accept accesskey action alt autocomplete autofocus checked
+ disabled enctype form inputmode list maxlength method min
+ max name pattern step readonly replace required size src
+ tabindex target template value
+ ],
+ 'form' => %w[action method enctype accept name onsubmit onreset accept-charset
+ data replace
+ ],
+ 'button' => %w[action enctype method replace template name value type disabled form autofocus], # XXX may need matrix of acceptable attributes based on value of type attribute (like input)
+ 'select' => %w[name size multiple disabled data accesskey form autofocus],
+ 'optgroup' => %w[disabled label],
+ 'option' => %w[selected disabled label value],
+ 'textarea' => %w[maxlength name rows cols disabled readonly required form autofocus wrap accept],
+ 'label' => %w[for accesskey form],
+ 'fieldset' => %w[disabled form],
+ 'output' => %w[form name for onforminput onformchange],
+ 'datalist' => %w[data],
+ # XXX repetition model for repeating form controls
+ 'script' => %w[src defer async type],
+ 'noscript' => [],
+ 'noembed' => [],
+ 'event-source' => %w[src],
+ 'details' => %w[open],
+ 'datagrid' => %w[multiple disabled],
+ 'command' => %w[type label icon hidden disabled checked radiogroup default],
+ 'menu' => %w[type label autosubmit],
+ 'datatemplate' => [],
+ 'rule' => [],
+ 'nest' => [],
+ 'legend' => [],
+ 'div' => [],
+ 'font' => %w[style]
+ }
+
+ @@required_attribute_map = {
+ 'link' => %w[href rel],
+ 'bdo' => %w[dir],
+ 'img' => %w[src],
+ 'embed' => %w[src],
+ 'object' => [], # XXX one of 'data' or 'type' is required
+ 'param' => %w[name value],
+ 'source' => %w[src],
+ 'map' => %w[id]
+ }
+
+ @@input_type_allowed_attribute_map = {
+ 'text' => %w[accesskey autocomplete autofocus disabled form inputmode list maxlength name pattern readonly required size tabindex value],
+ 'password' => %w[accesskey autocomplete autofocus disabled form inputmode maxlength name pattern readonly required size tabindex value],
+ 'checkbox' => %w[accesskey autofocus checked disabled form name required tabindex value],
+ 'radio' => %w[accesskey autofocus checked disabled form name required tabindex value],
+ 'button' => %w[accesskey autofocus disabled form name tabindex value],
+ 'submit' => %w[accesskey action autofocus disabled enctype form method name replace tabindex target value],
+ 'reset' => %w[accesskey autofocus disabled form name tabindex value],
+ 'add' => %w[accesskey autofocus disabled form name tabindex template value],
+ 'remove' => %w[accesskey autofocus disabled form name tabindex value],
+ 'move-up' => %w[accesskey autofocus disabled form name tabindex value],
+ 'move-down' => %w[accesskey autofocus disabled form name tabindex value],
+ 'file' => %w[accept accesskey autofocus disabled form min max name required tabindex],
+ 'hidden' => %w[disabled form name value],
+ 'image' => %w[accesskey action alt autofocus disabled enctype form method name replace src tabindex target],
+ 'datetime' => %w[accesskey autocomplete autofocus disabled form list min max name step readonly required tabindex value],
+ 'datetime-local' => %w[accesskey autocomplete autofocus disabled form list min max name step readonly required tabindex value],
+ 'date' => %w[accesskey autocomplete autofocus disabled form list min max name step readonly required tabindex value],
+ 'month' => %w[accesskey autocomplete autofocus disabled form list min max name step readonly required tabindex value],
+ 'week' => %w[accesskey autocomplete autofocus disabled form list min max name step readonly required tabindex value],
+ 'time' => %w[accesskey autocomplete autofocus disabled form list min max name step readonly required tabindex value],
+ 'number' => %w[accesskey autocomplete autofocus disabled form list min max name step readonly required tabindex value],
+ 'range' => %w[accesskey autocomplete autofocus disabled form list min max name step readonly required tabindex value],
+ 'email' => %w[accesskey autocomplete autofocus disabled form inputmode list maxlength name pattern readonly required tabindex value],
+ 'url' => %w[accesskey autocomplete autofocus disabled form inputmode list maxlength name pattern readonly required tabindex value],
+ }
+
+ @@input_type_deprecated_attribute_map = {
+ 'text' => ['size'],
+ 'password' => ['size']
+ }
+
+ @@link_rel_values = %w[alternate archive archives author contact feed first begin start help icon index top contents toc last end license copyright next pingback prefetch prev previous search stylesheet sidebar tag up]
+ @@a_rel_values = %w[alternate archive archives author contact feed first begin start help index top contents toc last end license copyright next prev previous search sidebar tag up bookmark external nofollow]
+
+ def initialize(stream, *args)
+ super(HTML5::HTMLTokenizer.new(stream, *args))
+ @things_that_define_an_id = []
+ @things_that_point_to_an_id = []
+ @ids_we_have_known_and_loved = []
+ end
+
+ def each
+ __getobj__.each do |token|
+ method = "validate_#{token.fetch(:type, '-').to_s.underscore}_#{token.fetch(:name, '-').to_s.underscore}"
+ if respond_to?(method)
+ send(method, token){|t| yield t }
+ else
+ method = "validate_#{token.fetch(:type, '-').to_s.underscore}"
+ if respond_to?(method)
+ send(method, token) do |t|
+ yield t
+ end
+ end
+ end
+ yield token
+ end
+ eof do |t|
+ yield t
+ end
+ end
+
+ ##########################################################################
+ # Start tag validation
+ ##########################################################################
+
+ def validate_start_tag(token)
+ check_unknown_start_tag(token){|t| yield t}
+ check_start_tag_required_attributes(token) do |t|
+ yield t
+ end
+ check_start_tag_unknown_attributes(token) do |t|
+ yield t
+ end
+ check_attribute_values(token) do |t|
+ yield t
+ end
+ end
+
+ def validate_start_tag_embed(token)
+ check_start_tag_required_attributes(token) do |t|
+ yield t
+ end
+ check_attribute_values(token) do |t|
+ yield t
+ end
+ # spec says "any attributes w/o namespace"
+ # so don't call check_start_tag_unknown_attributes
+ end
+
+ def validate_start_tag_input(token)
+ check_attribute_values(token) do |t|
+ yield t
+ end
+ attr_dict = Hash[*token[:data].collect{|(name, value)| [name.downcase, value]}.flatten]
+ input_type = attr_dict.fetch('type', "text")
+ if !@@input_type_allowed_attribute_map.keys().include?(input_type)
+ yield({:type => "ParseError",
+ :data => "unknown-input-type",
+ :datavars => {:attrValue => input_type}})
+ end
+ allowed_attributes = @@input_type_allowed_attribute_map.fetch(input_type, [])
+ attr_dict.each do |attr_name, attr_value|
+ if !@@allowed_attribute_map['input'].include?(attr_name)
+ yield({:type => "ParseError",
+ :data => "unknown-attribute",
+ :datavars => {"tagName" => "input",
+ "attributeName" => attr_name}})
+ elsif !allowed_attributes.include?(attr_name)
+ yield({:type => "ParseError",
+ :data => "attribute-not-allowed-on-this-input-type",
+ :datavars => {"attributeName" => attr_name,
+ "inputType" => input_type}})
+ end
+ if @@input_type_deprecated_attribute_map.fetch(input_type, []).include?(attr_name)
+ yield({:type => "ParseError",
+ :data => "deprecated-attribute",
+ :datavars => {"attributeName" => attr_name,
+ "inputType" => input_type}})
+ end
+ end
+ end
+
+ ##########################################################################
+ # Start tag validation helpers
+ ##########################################################################
+
+ def check_unknown_start_tag(token)
+ # check for recognized tag name
+ name = (token[:name] || "").downcase
+ if !@@allowed_attribute_map.keys.include?(name)
+ yield({:type => "ParseError",
+ :data => "unknown-start-tag",
+ :datavars => {"tagName" => name}})
+ end
+ end
+
+ def check_start_tag_required_attributes(token)
+ # check for presence of required attributes
+ name = (token[:name] || "").downcase
+ if @@required_attribute_map.keys().include?(name)
+ attrs_present = (token[:data] || []).collect{|t| t[0]}
+ for attr_name in @@required_attribute_map[name]
+ if !attrs_present.include?(attr_name)
+ yield( {:type => "ParseError",
+ :data => "missing-required-attribute",
+ :datavars => {"tagName" => name,
+ "attributeName" => attr_name}})
+ end
+ end
+ end
+ end
+
+ def check_start_tag_unknown_attributes(token)
+ # check for recognized attribute names
+ name = token[:name].downcase
+ allowed_attributes = @@global_attributes | @@allowed_attribute_map.fetch(name, [])
+ for attr_name, attr_value in token.fetch(:data, [])
+ if !allowed_attributes.include?(attr_name.downcase())
+ yield( {:type => "ParseError",
+ :data => "unknown-attribute",
+ :datavars => {"tagName" => name,
+ "attributeName" => attr_name}})
+ end
+ end
+ end
+
+ ##########################################################################
+ # Attribute validation helpers
+ ##########################################################################
+
+# def checkURI(token, tag_name, attr_name, attr_value)
+# is_valid, error_code = rfc3987.is_valid_uri(attr_value)
+# if not is_valid
+# yield {:type => "ParseError",
+# :data => error_code,
+# :datavars => {"tagName" => tag_name,
+# "attributeName" => attr_name}}
+# yield {:type => "ParseError",
+# :data => "invalid-attribute-value",
+# :datavars => {"tagName" => tag_name,
+# "attributeName" => attr_name}}
+
+ def check_iri(token, tag_name, attr_name, attr_value)
+ is_valid, error_code = is_valid_iri(attr_value)
+ if !is_valid
+ yield({:type => "ParseError",
+ :data => error_code,
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name}})
+ yield({:type => "ParseError",
+ :data => "invalid-attribute-value",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name}})
+ end
+ end
+
+ def check_id(token, tag_name, attr_name, attr_value)
+ if !attr_value || attr_value.length == 0
+ yield({:type => "ParseError",
+ :data => "attribute-value-can-not-be-blank",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name}})
+ end
+ attr_value.each_byte do |b|
+ c = [b].pack('c*')
+ if HTML5::SPACE_CHARACTERS.include?(c)
+ yield( {:type => "ParseError",
+ :data => "space-in-id",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name}})
+ yield( {:type => "ParseError",
+ :data => "invalid-attribute-value",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name}})
+ break
+ end
+ end
+ end
+
+ def parse_token_list(value)
+ valueList = []
+ currentValue = ''
+ (value + ' ').each_byte do |b|
+ c = [b].pack('c*')
+ if HTML5::SPACE_CHARACTERS.include?(c)
+ if currentValue.length > 0
+ valueList << currentValue
+ currentValue = ''
+ end
+ else
+ currentValue += c
+ end
+ end
+ if currentValue.length > 0
+ valueList << currentValue
+ end
+ valueList
+ end
+
+ def check_token_list(tag_name, attr_name, attr_value)
+ # The "token" in the method name refers to tokens in an attribute value
+ # i.e. http://www.whatwg.org/specs/web-apps/current-work/#set-of
+ # but the "token" parameter refers to the token generated from
+ # HTMLTokenizer. Sorry for the confusion.
+ value_list = parse_token_list(attr_value)
+ value_dict = {}
+ for current_value in value_list
+ if value_dict.has_key?(current_value)
+ yield({:type => "ParseError",
+ :data => "duplicate-value-in-token-list",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name,
+ "attributeValue" => current_value}})
+ break
+ end
+ value_dict[current_value] = 1
+ end
+ end
+
+ def check_enumerated_value(token, tag_name, attr_name, attr_value, enumerated_values)
+ if !attr_value || attr_value.length == 0
+ yield( {:type => "ParseError",
+ :data => "attribute-value-can-not-be-blank",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name}})
+ return
+ end
+ attr_value.downcase!
+ if !enumerated_values.include?(attr_value)
+ yield( {:type => "ParseError",
+ :data => "invalid-enumerated-value",
+ :datavars => {"tagName" => tag_name,
+ "attribute_name" => attr_name,
+ "enumeratedValues" => enumerated_values}})
+ yield( {:type => "ParseError",
+ :data => "invalid-attribute-value",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name}})
+ end
+ end
+
+ def check_boolean(token, tag_name, attr_name, attr_value)
+ enumerated_values = [attr_name, '']
+ if !enumerated_values.include?(attr_value)
+ yield( {:type => "ParseError",
+ :data => "invalid-boolean-value",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name,
+ "enumeratedValues" => enumerated_values}})
+ yield( {:type => "ParseError",
+ :data => "invalid-attribute-value",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name}})
+ end
+ end
+
+ def check_integer(token, tag_name, attr_name, attr_value)
+ sign = 1
+ number_string = ''
+ state = 'begin' # ('begin', 'initial-number', 'number', 'trailing-junk')
+ error = {:type => "ParseError",
+ :data => "invalid-integer-value",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name,
+ "attributeValue" => attr_value}}
+ attr_value.scan(/./) do |c|
+ if state == 'begin'
+ if HTML5::SPACE_CHARACTERS.include?(c)
+ next
+ elsif c == '-'
+ sign = -1
+ state = 'initial-number'
+ elsif HTML5::DIGITS.include?(c)
+ number_string += c
+ state = 'in-number'
+ else
+ yield error
+ return
+ end
+ elsif state == 'initial-number'
+ if !HTML5::DIGITS.include?(c)
+ yield error
+ return
+ end
+ number_string += c
+ state = 'in-number'
+ elsif state == 'in-number'
+ if HTML5::DIGITS.include?(c)
+ number_string += c
+ else
+ state = 'trailing-junk'
+ end
+ elsif state == 'trailing-junk'
+ next
+ end
+ end
+ if number_string.length == 0
+ yield( {:type => "ParseError",
+ :data => "attribute-value-can-not-be-blank",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name}})
+ end
+ end
+
+ def check_floating_point_number(token, tag_name, attr_name, attr_value)
+ # XXX
+ end
+
+ def check_browsing_context(token, tag_name, attr_name, attr_value)
+ return if not attr_value
+ return if attr_value[0] != ?_
+ attr_value.downcase!
+ return if ['_self', '_parent', '_top', '_blank'].include?(attr_value)
+ yield({:type => "ParseError",
+ :data => "invalid-browsing-context",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name}})
+ end
+
+ def check_lang_code(token, tag_name, attr_name, attr_value)
+ return if !attr_value || attr_value == '' # blank is OK
+ if not is_valid_lang_code(attr_value)
+ yield( {:type => "ParseError",
+ :data => "invalid-lang-code",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name,
+ "attributeValue" => attr_value}})
+ end
+ end
+
+ def check_mime_type(token, tag_name, attr_name, attr_value)
+ # XXX needs tests
+ if not attr_value
+ yield( {:type => "ParseError",
+ :data => "attribute-value-can-not-be-blank",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name}})
+ end
+ if not is_valid_mime_type(attr_value)
+ yield( {:type => "ParseError",
+ :data => "invalid-mime-type",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name,
+ "attributeValue" => attr_value}})
+ end
+ end
+
+ def check_media_query(token, tag_name, attr_name, attr_value)
+ # XXX
+ end
+
+ def check_link_relation(token, tag_name, attr_name, attr_value)
+ check_token_list(tag_name, attr_name, attr_value) do |t|
+ yield t
+ end
+ value_list = parse_token_list(attr_value)
+ allowed_values = tag_name == 'link' ? @@link_rel_values : @@a_rel_values
+ for current_value in value_list
+ if !allowed_values.include?(current_value)
+ yield({:type => "ParseError",
+ :data => "invalid-rel",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name}})
+ end
+ end
+ end
+
+ def check_date_time(token, tag_name, attr_name, attr_value)
+ # XXX
+ state = 'begin' # ('begin', '...
+# for c in attr_value
+# if state == 'begin' =>
+# if SPACE_CHARACTERS.include?(c)
+# continue
+# elsif digits.include?(c)
+# state = ...
+ end
+
+ ##########################################################################
+ # Attribute validation
+ ##########################################################################
+
+ def check_attribute_values(token)
+ tag_name = token.fetch(:name, "")
+ for attr_name, attr_value in token.fetch(:data, [])
+ attr_name = attr_name.downcase
+ method = "validate_attribute_value_#{tag_name.to_s.underscore}_#{attr_name.to_s.underscore}"
+ if respond_to?(method)
+ send(method, token, tag_name, attr_name, attr_value) do |t|
+ yield t
+ end
+ else
+ method = "validate_attribute_value_#{attr_name.to_s.underscore}"
+ if respond_to?(method)
+ send(method, token, tag_name, attr_name, attr_value) do |t|
+ yield t
+ end
+ end
+ end
+ end
+ end
+
+ def validate_attribute_value_class(token, tag_name, attr_name, attr_value)
+ check_token_list(tag_name, attr_name, attr_value) do |t|
+ yield t
+ yield( {:type => "ParseError",
+ :data => "invalid-attribute-value",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name}})
+ end
+ end
+
+ def validate_attribute_value_contenteditable(token, tag_name, attr_name, attr_value)
+ check_enumerated_value(token, tag_name, attr_name, attr_value, ['true', 'false', '']) do |t|
+ yield t
+ end
+ end
+
+ def validate_attribute_value_dir(token, tag_name, attr_name, attr_value)
+ check_enumerated_value(token, tag_name, attr_name, attr_value, ['ltr', 'rtl']) do |t|
+ yield t
+ end
+ end
+
+ def validate_attribute_value_draggable(token, tag_name, attr_name, attr_value)
+ check_enumerated_value(token, tag_name, attr_name, attr_value, ['true', 'false']) do |t|
+ yield t
+ end
+ end
+
+ alias validate_attribute_value_irrelevant check_boolean
+ alias validate_attribute_value_lang check_lang_code
+
+ def validate_attribute_value_contextmenu(token, tag_name, attr_name, attr_value)
+ check_id(token, tag_name, attr_name, attr_value) do |t|
+ yield t
+ end
+ @things_that_point_to_an_id << token
+ end
+
+ def validate_attribute_value_id(token, tag_name, attr_name, attr_value)
+ # This method has side effects. It adds 'token' to the list of
+ # things that define an ID (@things_that_define_an_id) so that we can
+ # later check 1) whether an ID is duplicated, and 2) whether all the
+ # things that point to something else by ID (like or
+ # ) point to an ID that actually exists somewhere.
+ check_id(token, tag_name, attr_name, attr_value) do |t|
+ yield t
+ end
+ return if not attr_value
+ if @ids_we_have_known_and_loved.include?(attr_value)
+ yield( {:type => "ParseError",
+ :data => "duplicate-id",
+ :datavars => {"tagName" => tag_name}})
+ end
+ @ids_we_have_known_and_loved << attr_value
+ @things_that_define_an_id << token
+ end
+
+ alias validate_attribute_value_tabindex check_integer
+
+ def validate_attribute_value_ref(token, tag_name, attr_name, attr_value)
+ # XXX
+ end
+
+ def validate_attribute_value_template(token, tag_name, attr_name, attr_value)
+ # XXX
+ end
+
+ def validate_attribute_value_html_xmlns(token, tag_name, attr_name, attr_value)
+ if attr_value != "http://www.w3.org/1999/xhtml"
+ yield( {:type => "ParseError",
+ :data => "invalid-root-namespace",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => attr_name}})
+ end
+ end
+
+ alias validate_attribute_value_base_href check_iri
+ alias validate_attribute_value_base_target check_browsing_context
+ alias validate_attribute_value_link_href check_iri
+ alias validate_attribute_value_link_rel check_link_relation
+ alias validate_attribute_value_link_media check_media_query
+ alias validate_attribute_value_link_hreflang check_lang_code
+ alias validate_attribute_value_link_type check_mime_type
+ # XXX attributes
+ alias validate_attribute_value_style_media check_media_query
+ alias validate_attribute_value_style_type check_mime_type
+ alias validate_attribute_value_style_scoped check_boolean
+ alias validate_attribute_value_blockquote_cite check_iri
+ alias validate_attribute_value_ol_start check_integer
+ alias validate_attribute_value_li_value check_integer
+ # XXX need tests from here on
+ alias validate_attribute_value_a_href check_iri
+ alias validate_attribute_value_a_target check_browsing_context
+
+ def validate_attribute_value_a_ping(token, tag_name, attr_name, attr_value)
+ value_list = parse_token_list(attr_value)
+ for current_value in value_list
+ checkIRI(token, tag_name, attr_name, attr_value) do |t|
+ yield t
+ end
+ end
+ end
+
+ alias validate_attribute_value_a_rel check_link_relation
+ alias validate_attribute_value_a_media check_media_query
+ alias validate_attribute_value_a_hreflang check_lang_code
+ alias validate_attribute_value_a_type check_mime_type
+ alias validate_attribute_value_q_cite check_iri
+ alias validate_attribute_value_time_datetime check_date_time
+ alias validate_attribute_value_meter_value check_floating_point_number
+ alias validate_attribute_value_meter_min check_floating_point_number
+ alias validate_attribute_value_meter_low check_floating_point_number
+ alias validate_attribute_value_meter_high check_floating_point_number
+ alias validate_attribute_value_meter_max check_floating_point_number
+ alias validate_attribute_value_meter_optimum check_floating_point_number
+ alias validate_attribute_value_progress_value check_floating_point_number
+ alias validate_attribute_value_progress_max check_floating_point_number
+ alias validate_attribute_value_ins_cite check_iri
+ alias validate_attribute_value_ins_datetime check_date_time
+ alias validate_attribute_value_del_cite check_iri
+ alias validate_attribute_value_del_datetime check_date_time
+
+ ##########################################################################
+ # Whole document validation (IDs, etc.)
+ ##########################################################################
+
+ def eof
+ for token in @things_that_point_to_an_id
+ tag_name = token.fetch(:name, "").downcase
+ attrs_dict = token[:data] # by now html5parser has "normalized" the attrs list into a dict.
+ # hooray for obscure side effects!
+ attr_value = attrs_dict.fetch("contextmenu", "")
+ if attr_value and (!@ids_we_have_known_and_loved.include?(attr_value))
+ yield( {:type => "ParseError",
+ :data => "id-does-not-exist",
+ :datavars => {"tagName" => tag_name,
+ "attributeName" => "contextmenu",
+ "attributeValue" => attr_value}})
+ else
+ for ref_token in @things_that_define_an_id
+ id = ref_token.fetch(:data, {}).fetch("id", "")
+ if not id
+ continue
+ end
+ if id == attr_value
+ if ref_token.fetch(:name, "").downcase != "men"
+ yield( {:type => "ParseError",
+ :data => "contextmenu-must-point-to-menu"})
+ end
+ break
+ end
+ end
+ end
+ end
+ end
+end
diff --git a/vendor/plugins/HTML5lib/lib/html5/html5parser.rb b/vendor/plugins/HTML5lib/lib/html5/html5parser.rb
index b20238b8..8a7e05f3 100644
--- a/vendor/plugins/HTML5lib/lib/html5/html5parser.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/html5parser.rb
@@ -100,17 +100,17 @@ module HTML5
method = 'process%s' % token[:type]
case token[:type]
- when :Characters, :SpaceCharacters, :Comment
- @phase.send method, token[:data]
- when :StartTag
- @phase.send method, token[:name], token[:data]
- when :EndTag
- @phase.send method, token[:name]
- when :Doctype
- @phase.send method, token[:name], token[:publicId],
- token[:systemId], token[:correct]
- else
- parse_error(token[:data])
+ when :Characters, :SpaceCharacters, :Comment
+ @phase.send method, token[:data]
+ when :StartTag
+ @phase.send method, token[:name], token[:data]
+ when :EndTag
+ @phase.send method, token[:name]
+ when :Doctype
+ @phase.send method, token[:name], token[:publicId],
+ token[:systemId], token[:correct]
+ else
+ parse_error(token[:data], token[:datavars])
end
end
@@ -147,9 +147,9 @@ module HTML5
@tree.get_fragment
end
- def parse_error(data = 'XXX ERROR MESSAGE NEEDED')
+ def parse_error(code = 'XXX-undefined-error', data = {})
# XXX The idea is to make data mandatory.
- @errors.push([@tokenizer.stream.position, data])
+ @errors.push([@tokenizer.stream.position, code, data])
raise ParseError if @strict
end
@@ -163,7 +163,7 @@ module HTML5
# thing and if it doesn't it's wrong for everyone.
unless VOID_ELEMENTS.include?(token[:name])
- parse_error(_('Solidus (/) incorrectly placed in tag.'))
+ parse_error("incorrectly-placed-solidus")
end
token[:type] = :StartTag
@@ -181,7 +181,7 @@ module HTML5
end
elsif token[:type] == :EndTag
- parse_error(_('End tag contains unexpected attributes.')) unless token[:data].empty?
+ parse_error("attributes-in-end-tag") unless token[:data].empty?
token[:name] = token[:name].downcase
end
diff --git a/vendor/plugins/HTML5lib/lib/html5/html5parser/after_body_phase.rb b/vendor/plugins/HTML5lib/lib/html5/html5parser/after_body_phase.rb
index 5d535423..a55e4701 100644
--- a/vendor/plugins/HTML5lib/lib/html5/html5parser/after_body_phase.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/html5parser/after_body_phase.rb
@@ -12,13 +12,13 @@ module HTML5
end
def processCharacters(data)
- parse_error(_('Unexpected non-space characters in the after body phase.'))
+ parse_error("unexpected-char-after-body")
@parser.phase = @parser.phases[:inBody]
@parser.phase.processCharacters(data)
end
def processStartTag(name, attributes)
- parse_error(_("Unexpected start tag token (#{name}) in the after body phase."))
+ parse_error("unexpected-start-tag-after-body", {"name" => name})
@parser.phase = @parser.phases[:inBody]
@parser.phase.processStartTag(name, attributes)
end
@@ -37,7 +37,7 @@ module HTML5
end
def endTagOther(name)
- parse_error(_("Unexpected end tag token (#{name}) in the after body phase."))
+ parse_error("unexpected-end-tag-after-body", {"name" => name})
@parser.phase = @parser.phases[:inBody]
@parser.phase.processEndTag(name)
end
diff --git a/vendor/plugins/HTML5lib/lib/html5/html5parser/after_frameset_phase.rb b/vendor/plugins/HTML5lib/lib/html5/html5parser/after_frameset_phase.rb
index 0445f3c1..43416232 100644
--- a/vendor/plugins/HTML5lib/lib/html5/html5parser/after_frameset_phase.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/html5parser/after_frameset_phase.rb
@@ -10,7 +10,7 @@ module HTML5
handle_end 'html'
def processCharacters(data)
- parse_error(_('Unexpected non-space characters in the after frameset phase. Ignored.'))
+ parse_error("unexpected-char-after-frameset")
end
def startTagNoframes(name, attributes)
@@ -18,7 +18,7 @@ module HTML5
end
def startTagOther(name, attributes)
- parse_error(_("Unexpected start tag (#{name}) in the after frameset phase. Ignored."))
+ parse_error("unexpected-start-tag-after-frameset", {"name" => name})
end
def endTagHtml(name)
@@ -27,8 +27,7 @@ module HTML5
end
def endTagOther(name)
- parse_error(_("Unexpected end tag (#{name}) in the after frameset phase. Ignored."))
+ parse_error("unexpected-end-tag-after-frameset", {"name" => name})
end
-
end
end
\ No newline at end of file
diff --git a/vendor/plugins/HTML5lib/lib/html5/html5parser/after_head_phase.rb b/vendor/plugins/HTML5lib/lib/html5/html5parser/after_head_phase.rb
index 2f48946b..2460134c 100644
--- a/vendor/plugins/HTML5lib/lib/html5/html5parser/after_head_phase.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/html5parser/after_head_phase.rb
@@ -26,7 +26,7 @@ module HTML5
end
def startTagFromHead(name, attributes)
- parse_error(_("Unexpected start tag (#{name}) that can be in head. Moved."))
+ parse_error("unexpected-start-tag-out-of-my-head", {"name" => name})
@parser.phase = @parser.phases[:inHead]
@parser.phase.processStartTag(name, attributes)
end
diff --git a/vendor/plugins/HTML5lib/lib/html5/html5parser/before_head_phase.rb b/vendor/plugins/HTML5lib/lib/html5/html5parser/before_head_phase.rb
index 79785d07..f3419594 100644
--- a/vendor/plugins/HTML5lib/lib/html5/html5parser/before_head_phase.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/html5parser/before_head_phase.rb
@@ -34,7 +34,7 @@ module HTML5
end
def endTagOther(name)
- parse_error(_("Unexpected end tag (#{name}) after the (implied) root element."))
+ parse_error("end-tag-after-implied-root", {"name" => name})
end
end
diff --git a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_body_phase.rb b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_body_phase.rb
index ca59bbf7..e7c30203 100644
--- a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_body_phase.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_body_phase.rb
@@ -100,12 +100,12 @@ module HTML5
end
def startTagTitle(name, attributes)
- parse_error(_("Unexpected start tag (#{name}) that belongs in the head. Moved."))
+ parse_error("unexpected-start-tag-out-of-my-head", {"name" => name})
@parser.phases[:inHead].processStartTag(name, attributes)
end
def startTagBody(name, attributes)
- parse_error(_('Unexpected start tag (body).'))
+ parse_error("unexpected-start-tag", {"name" => "body"})
if (@tree.open_elements.length == 1 || @tree.open_elements[1].name != 'body')
assert @parser.inner_html
@@ -126,7 +126,7 @@ module HTML5
def startTagForm(name, attributes)
if @tree.formPointer
- parse_error(_('Unexpected start tag (form). Ignored.'))
+ parse_error("Unexpected start tag (form). Ignored.")
else
endTagP('p') if in_scope?('p')
@tree.insert_element(name, attributes)
@@ -143,7 +143,10 @@ module HTML5
if stopName.include?(node.name)
poppedNodes = (0..i).collect { @tree.open_elements.pop }
if i >= 1
- parse_error(_("Missing end tag%s (%s)" % [(i>1 ? 's' : ''), poppedNodes.reverse.map{|item| item.name}.join(', ')]))
+ parse_error(
+ i == 1 ? "missing-end-tag" : "missing-end-tags",
+ {"name" => poppedNodes[0..-1].collect{|n| n.name}.join(", ")})
+
end
break
end
@@ -169,7 +172,7 @@ module HTML5
# Uncomment the following for IE7 behavior:
# HEADING_ELEMENTS.each do |element|
# if in_scope?(element)
- # parse_error(_("Unexpected start tag (#{name})."))
+ # parse_error("unexpected-start-tag", {"name" => name})
#
# remove_open_elements_until do |element|
# HEADING_ELEMENTS.include?(element.name)
@@ -183,7 +186,7 @@ module HTML5
def startTagA(name, attributes)
if afeAElement = @tree.elementInActiveFormattingElements('a')
- parse_error(_('Unexpected start tag (a) implies end tag (a).'))
+ parse_error("unexpected-start-tag-implies-end-tag", {"startName" => "a", "endName" => "a"})
endTagFormatting('a')
@tree.open_elements.delete(afeAElement) if @tree.open_elements.include?(afeAElement)
@tree.activeFormattingElements.delete(afeAElement) if @tree.activeFormattingElements.include?(afeAElement)
@@ -200,7 +203,7 @@ module HTML5
def startTagNobr(name, attributes)
@tree.reconstructActiveFormattingElements
if in_scope?('nobr')
- parse_error(_('Unexpected start tag (nobr) implies end tag (nobr).'))
+ parse_error("unexpected-start-tag-implies-end-tag", {"startName" => "nobr", "endName" => "nobr"})
processEndTag('nobr')
# XXX Need tests that trigger the following
@tree.reconstructActiveFormattingElements
@@ -210,7 +213,7 @@ module HTML5
def startTagButton(name, attributes)
if in_scope?('button')
- parse_error(_('Unexpected start tag (button) implied end tag (button).'))
+ parse_error("unexpected-start-tag-implies-end-tag", {"startName" => "button", "endName" => "button"})
processEndTag('button')
@parser.phase.processStartTag(name, attributes)
else
@@ -252,7 +255,7 @@ module HTML5
def startTagImage(name, attributes)
# No really...
- parse_error(_('Unexpected start tag (image). Treated as img.'))
+ parse_error("unexpected-start-tag-treated-as", {"originalName" => "image", "newName" => "img"})
processStartTag('img', attributes)
end
@@ -267,7 +270,7 @@ module HTML5
end
def startTagIsindex(name, attributes)
- parse_error(_("Unexpected start tag isindex. Don't use it!"))
+ parse_error("deprecated-tag", {"name" => "isindex"})
return if @tree.formPointer
processStartTag('form', {})
processStartTag('hr', {})
@@ -310,13 +313,13 @@ module HTML5
# "caption", "col", "colgroup", "frame", "frameset", "head",
# "option", "optgroup", "tbody", "td", "tfoot", "th", "thead",
# "tr", "noscript"
- parse_error(_("Unexpected start tag (#{name}). Ignored."))
+ parse_error("unexpected-start-tag-ignored", {"name" => name})
end
def startTagNew(name, attributes)
# New HTML5 elements, "event-source", "section", "nav",
# "article", "aside", "header", "footer", "datagrid", "command"
- sys.stderr.write("Warning: Undefined behaviour for start tag #{name}")
+ # $stderr.puts("Warning: Undefined behaviour for start tag #{name}")
startTagOther(name, attributes)
#raise NotImplementedError
end
@@ -328,7 +331,7 @@ module HTML5
def endTagP(name)
@tree.generateImpliedEndTags('p') if in_scope?('p')
- parse_error(_('Unexpected end tag (p).')) unless @tree.open_elements.last.name == 'p'
+ parse_error("unexpected-end-tag", {"name" => "p"}) unless @tree.open_elements.last.name == 'p'
if in_scope?('p')
@tree.open_elements.pop while in_scope?('p')
else
@@ -347,7 +350,9 @@ module HTML5
return
end
unless @tree.open_elements.last.name == 'body'
- parse_error(_("Unexpected end tag (body). Missing end tag (#{@tree.open_elements[-1].name})."))
+ parse_error("expected-one-end-tag-but-got-another",
+ {"expectedName" => "body",
+ "gotName" => @tree.open_elements.last.name})
end
@parser.phase = @parser.phases[:afterBody]
end
@@ -364,7 +369,7 @@ module HTML5
@tree.generateImpliedEndTags if in_scope?(name)
unless @tree.open_elements.last.name == name
- parse_error(_("End tag (#{name}) seen too early. Expected other end tag."))
+ parse_error("end-tag-too-early", {"name" => name})
end
if in_scope?(name)
@@ -377,7 +382,7 @@ module HTML5
@tree.generateImpliedEndTags
end
if @tree.open_elements.last.name != name
- parse_error(_("End tag (form) seen too early. Ignored."))
+ parse_error("end-tag-too-early-ignored", {"name" => "form"})
else
@tree.open_elements.pop
end
@@ -389,7 +394,7 @@ module HTML5
@tree.generateImpliedEndTags(name) if in_scope?(name)
unless @tree.open_elements.last.name == name
- parse_error(_("End tag (#{name}) seen too early. " + 'Expected other end tag.'))
+ parse_error("end-tag-too-early", {"name" => name})
end
remove_open_elements_until(name) if in_scope?(name)
@@ -404,7 +409,7 @@ module HTML5
end
unless @tree.open_elements.last.name == name
- parse_error(_("Unexpected end tag (#{name}). Expected other end tag."))
+ parse_error("end-tag-too-early", {"name" => name})
end
HEADING_ELEMENTS.each do |element|
@@ -423,18 +428,18 @@ module HTML5
# Step 1 paragraph 1
afeElement = @tree.elementInActiveFormattingElements(name)
if !afeElement or (@tree.open_elements.include?(afeElement) && !in_scope?(afeElement.name))
- parse_error(_("End tag (#{name}) violates step 1, paragraph 1 of the adoption agency algorithm."))
+ parse_error("adoption-agency-1.1", {"name" => name})
return
# Step 1 paragraph 2
elsif not @tree.open_elements.include?(afeElement)
- parse_error(_("End tag (#{name}) violates step 1, paragraph 2 of the adoption agency algorithm."))
+ parse_error("adoption-agency-1.2", {"name" => name})
@tree.activeFormattingElements.delete(afeElement)
return
end
# Step 1 paragraph 3
if afeElement != @tree.open_elements.last
- parse_error(_("End tag (#{name}) violates step 1, paragraph 3 of the adoption agency algorithm."))
+ parse_error("adoption-agency-1.3", {"name" => name})
end
# Step 2
@@ -531,7 +536,7 @@ module HTML5
@tree.generateImpliedEndTags if in_scope?(name)
unless @tree.open_elements.last.name == name
- parse_error(_("Unexpected end tag (#{name}). Expected other end tag first."))
+ parse_error("end-tag-too-early", {"name" => name})
end
if in_scope?(name)
@@ -543,11 +548,12 @@ module HTML5
def endTagMisplaced(name)
# This handles elements with end tags in other insertion modes.
- parse_error(_("Unexpected end tag (#{name}). Ignored."))
+ parse_error("unexpected-end-tag", {"name" => name})
end
def endTagBr(name)
- parse_error(_("Unexpected end tag (br). Treated as br element."))
+ parse_error("unexpected-end-tag-treated-as",
+ {"originalName" => "br", "newName" => "br element"})
@tree.reconstructActiveFormattingElements
@tree.insert_element(name, {})
@tree.open_elements.pop()
@@ -555,21 +561,21 @@ module HTML5
def endTagNone(name)
# This handles elements with no end tag.
- parse_error(_("This tag (#{name}) has no end tag"))
+ parse_error("no-end-tag", {"name" => name})
end
def endTagCdataTextAreaXmp(name)
if @tree.open_elements.last.name == name
@tree.open_elements.pop
else
- parse_error(_("Unexpected end tag (#{name}). Ignored."))
+ parse_error("unexpected-end-tag", {"name" => name})
end
end
def endTagNew(name)
# New HTML5 elements, "event-source", "section", "nav",
# "article", "aside", "header", "footer", "datagrid", "command"
- STDERR.puts "Warning: Undefined behaviour for end tag #{name}"
+ # STDERR.puts "Warning: Undefined behaviour for end tag #{name}"
endTagOther(name)
#raise NotImplementedError
end
@@ -581,7 +587,7 @@ module HTML5
@tree.generateImpliedEndTags
unless @tree.open_elements.last.name == name
- parse_error(_("Unexpected end tag (#{name})."))
+ parse_error("unexpected-end-tag", {"name" => name})
end
remove_open_elements_until {|element| element == node }
@@ -589,7 +595,7 @@ module HTML5
break
else
if (SPECIAL_ELEMENTS + SCOPING_ELEMENTS).include?(node.name)
- parse_error(_("Unexpected end tag (#{name}). Ignored."))
+ parse_error("unexpected-end-tag", {"name" => name})
break
end
end
diff --git a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_caption_phase.rb b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_caption_phase.rb
index 65718759..541b2d14 100644
--- a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_caption_phase.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_caption_phase.rb
@@ -39,7 +39,9 @@ module HTML5
@tree.generateImpliedEndTags
unless @tree.open_elements[-1].name == 'caption'
- parse_error(_("Unexpected end tag (caption). Missing end tags."))
+ parse_error("expected-one-end-tag-but-got-another",
+ {"gotName" => "caption",
+ "expectedNmae" => @tree.open_elements.last.name})
end
remove_open_elements_until('caption')
@@ -57,7 +59,7 @@ module HTML5
end
def endTagIgnore(name)
- parse_error(_("Unexpected end tag (#{name}). Ignored."))
+ parse_error("unexpected-end-tag", {"name" => name})
end
def endTagOther(name)
diff --git a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_cell_phase.rb b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_cell_phase.rb
index 50b29141..30081422 100644
--- a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_cell_phase.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_cell_phase.rb
@@ -33,7 +33,7 @@ module HTML5
if in_scope?(name, true)
@tree.generateImpliedEndTags(name)
if @tree.open_elements.last.name != name
- parse_error("Got table cell end tag (#{name}) while required end tags are missing.")
+ parse_error("unexpected-cell-end-tag", {"name" => name})
remove_open_elements_until(name)
else
@@ -42,12 +42,12 @@ module HTML5
@tree.clearActiveFormattingElements
@parser.phase = @parser.phases[:inRow]
else
- parse_error(_("Unexpected end tag (#{name}). Ignored."))
+ parse_error("unexpected-end-tag", {"name" => name})
end
end
def endTagIgnore(name)
- parse_error(_("Unexpected end tag (#{name}). Ignored."))
+ parse_error("unexpected-end-tag", {"name" => name})
end
def endTagImply(name)
diff --git a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_column_group_phase.rb b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_column_group_phase.rb
index 81841c26..9e1dec2a 100644
--- a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_column_group_phase.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_column_group_phase.rb
@@ -42,7 +42,7 @@ module HTML5
end
def endTagCol(name)
- parse_error(_('Unexpected end tag (col). col has no end tag.'))
+ parse_error("no-end-tag", {"name" => "col"})
end
def endTagOther(name)
diff --git a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_frameset_phase.rb b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_frameset_phase.rb
index 07d68d71..5ff9bd6b 100644
--- a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_frameset_phase.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_frameset_phase.rb
@@ -10,7 +10,7 @@ module HTML5
handle_end 'frameset', 'noframes'
def processCharacters(data)
- parse_error(_('Unexpected characters in the frameset phase. Characters ignored.'))
+ parse_error("unexpected-char-in-frameset")
end
def startTagFrameset(name, attributes)
@@ -27,13 +27,14 @@ module HTML5
end
def startTagOther(name, attributes)
- parse_error(_("Unexpected start tag token (#{name}) in the frameset phase. Ignored"))
+ parse_error("unexpected-start-tag-in-frameset",
+ {"name" => name})
end
def endTagFrameset(name)
if @tree.open_elements.last.name == 'html'
# inner_html case
- parse_error(_("Unexpected end tag token (frameset) in the frameset phase (inner_html)."))
+ parse_error("unexpected-frameset-in-frameset-innerhtml")
else
@tree.open_elements.pop
end
@@ -50,8 +51,7 @@ module HTML5
end
def endTagOther(name)
- parse_error(_("Unexpected end tag token (#{name}) in the frameset phase. Ignored."))
+ parse_error("unexpected-end-tag-in-frameset", {"name" => name})
end
-
end
end
\ No newline at end of file
diff --git a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_head_phase.rb b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_head_phase.rb
index 349c138a..c543bba5 100644
--- a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_head_phase.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_head_phase.rb
@@ -12,7 +12,7 @@ module HTML5
def process_eof
if ['title', 'style', 'script'].include?(name = @tree.open_elements.last.name)
- parse_error(_("Unexpected end of file. Expected end tag (#{name})."))
+ parse_error("expected-named-closing-tag-but-got-eof", {"name" => @tree.open_elements.last.name})
@tree.open_elements.pop
end
anything_else
@@ -29,7 +29,7 @@ module HTML5
end
def startTagHead(name, attributes)
- parse_error(_('Unexpected start tag head in existing head. Ignored'))
+ parse_error("two-heads-are-not-better-than-one")
end
def startTagTitle(name, attributes)
@@ -93,7 +93,7 @@ module HTML5
if @tree.open_elements.last.name == 'head'
@tree.open_elements.pop
else
- parse_error(_("Unexpected end tag (head). Ignored."))
+ parse_error("unexpected-end-tag", {"name" => "head"})
end
@parser.phase = @parser.phases[:afterHead]
end
@@ -107,12 +107,12 @@ module HTML5
if @tree.open_elements.last.name == name
@tree.open_elements.pop
else
- parse_error(_("Unexpected end tag (#{name}). Ignored."))
+ parse_error("unexpected-end-tag", {"name" => name})
end
end
def endTagOther(name)
- parse_error(_("Unexpected end tag (#{name}). Ignored."))
+ parse_error("unexpected-end-tag", {"name" => name})
end
def anything_else
diff --git a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_row_phase.rb b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_row_phase.rb
index b8cbf304..12af6212 100644
--- a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_row_phase.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_row_phase.rb
@@ -62,7 +62,8 @@ module HTML5
end
def endTagIgnore(name)
- parse_error(_("Unexpected end tag (#{name}) in the row phase. Ignored."))
+ parse_error("unexpected-end-tag-in-table-row",
+ {"name" => name})
end
def endTagOther(name)
@@ -74,7 +75,8 @@ module HTML5
# XXX unify this with other table helper methods
def clearStackToTableRowContext
until %w[tr html].include?(name = @tree.open_elements.last.name)
- parse_error(_("Unexpected implied end tag (#{name}) in the row phase."))
+ parse_error("unexpected-implied-end-tag-in-table-row",
+ {"name" => @tree.open_elements.last.name})
@tree.open_elements.pop
end
end
diff --git a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_select_phase.rb b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_select_phase.rb
index 9294bcf3..619a4503 100644
--- a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_select_phase.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_select_phase.rb
@@ -26,19 +26,19 @@ module HTML5
end
def startTagSelect(name, attributes)
- parse_error(_('Unexpected start tag (select) in the select phase implies select start tag.'))
+ parse_error("unexpected-select-in-select")
endTagSelect('select')
end
def startTagOther(name, attributes)
- parse_error(_('Unexpected start tag token (#{name}) in the select phase. Ignored.'))
+ parse_error("unexpected-start-tag-in-select", {"name" => name})
end
def endTagOption(name)
if @tree.open_elements.last.name == 'option'
@tree.open_elements.pop
else
- parse_error(_('Unexpected end tag (option) in the select phase. Ignored.'))
+ parse_error("unexpected-end-tag-in-select", {"name" => "option"})
end
end
@@ -52,7 +52,8 @@ module HTML5
@tree.open_elements.pop
# But nothing else
else
- parse_error(_('Unexpected end tag (optgroup) in the select phase. Ignored.'))
+ parse_error("unexpected-end-tag-in-select",
+ {"name" => "optgroup"})
end
end
@@ -68,7 +69,8 @@ module HTML5
end
def endTagTableElements(name)
- parse_error(_("Unexpected table end tag (#{name}) in the select phase."))
+ parse_error("unexpected-end-tag-in-select",
+ {"name" => name})
if in_scope?(name, true)
endTagSelect('select')
diff --git a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_table_body_phase.rb b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_table_body_phase.rb
index d31c88f7..b9adfa40 100644
--- a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_table_body_phase.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_table_body_phase.rb
@@ -20,7 +20,7 @@ module HTML5
end
def startTagTableCell(name, attributes)
- parse_error(_("Unexpected table cell start tag (#{name}) in the table body phase."))
+ parse_error("unexpected-cell-in-table-body", {"name" => name})
startTagTr('tr', {})
@parser.phase.processStartTag(name, attributes)
end
@@ -47,7 +47,8 @@ module HTML5
@tree.open_elements.pop
@parser.phase = @parser.phases[:inTable]
else
- parse_error(_("Unexpected end tag (#{name}) in the table body phase. Ignored."))
+ parse_error("unexpected-end-tag-in-table-body",
+ {"name" => name})
end
end
@@ -63,7 +64,8 @@ module HTML5
end
def endTagIgnore(name)
- parse_error(_("Unexpected end tag (#{name}) in the table body phase. Ignored."))
+ parse_error("unexpected-end-tag-in-table-body",
+ {"name" => name})
end
def endTagOther(name)
@@ -74,7 +76,8 @@ module HTML5
def clearStackToTableBodyContext
until %w[tbody tfoot thead html].include?(name = @tree.open_elements.last.name)
- parse_error(_("Unexpected implied end tag (#{name}) in the table body phase."))
+ parse_error("unexpected-implied-end-tag-in-table",
+ {"name" => @tree.open_elements.last.name})
@tree.open_elements.pop
end
end
diff --git a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_table_phase.rb b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_table_phase.rb
index 5733261f..6ffa8812 100644
--- a/vendor/plugins/HTML5lib/lib/html5/html5parser/in_table_phase.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/html5parser/in_table_phase.rb
@@ -12,7 +12,7 @@ module HTML5
handle_end 'table', %w( body caption col colgroup html tbody td tfoot th thead tr ) => 'Ignore'
def processCharacters(data)
- parse_error(_("Unexpected non-space characters in table context caused voodoo mode."))
+ parse_error("unexpected-char-implies-table-voodoo")
# Make all the special element rearranging voodoo kick in
@tree.insert_from_table = true
# Process the character in the "in body" mode
@@ -50,13 +50,15 @@ module HTML5
end
def startTagTable(name, attributes)
- parse_error(_("Unexpected start tag (table) in table phase. Implies end tag (table)."))
+ parse_error("unexpected-start-tag-implies-end-tag",
+ {"startName" => "table", "endName" => "table"})
@parser.phase.processEndTag('table')
@parser.phase.processStartTag(name, attributes) unless @parser.inner_html
end
def startTagOther(name, attributes)
- parse_error(_("Unexpected start tag (#{name}) in table context caused voodoo mode."))
+ parse_error("unexpected-start-tag-implies-table-voodoo",
+ {"name" => name})
# Make all the special element rearranging voodoo kick in
@tree.insert_from_table = true
# Process the start tag in the "in body" mode
@@ -69,7 +71,9 @@ module HTML5
@tree.generateImpliedEndTags
unless @tree.open_elements.last.name == 'table'
- parse_error(_("Unexpected end tag (table). Expected end tag (#{@tree.open_elements.last.name})."))
+ parse_error("end-tag-too-early-named",
+ {"gotName" => "table",
+ "expectedName" => @tree.open_elements.last.name})
end
remove_open_elements_until('table')
@@ -83,11 +87,11 @@ module HTML5
end
def endTagIgnore(name)
- parse_error(_("Unexpected end tag (#{name}). Ignored."))
+ parse_error("unexpected-end-tag", {"name" => name})
end
def endTagOther(name)
- parse_error(_("Unexpected end tag (#{name}) in table context caused voodoo mode."))
+ parse_error("unexpected-end-tag-implies-table-voodoo", {"name" => name})
# Make all the special element rearranging voodoo kick in
@tree.insert_from_table = true
# Process the end tag in the "in body" mode
@@ -100,7 +104,8 @@ module HTML5
def clearStackToTableContext
# "clear the stack back to a table context"
until %w[table html].include?(name = @tree.open_elements.last.name)
- parse_error(_("Unexpected implied end tag (#{name}) in the table phase."))
+ parse_error("unexpected-implied-end-tag-in-table",
+ {"name" => @tree.open_elements.last.name})
@tree.open_elements.pop
end
# When the current node is it's an inner_html case
diff --git a/vendor/plugins/HTML5lib/lib/html5/html5parser/initial_phase.rb b/vendor/plugins/HTML5lib/lib/html5/html5parser/initial_phase.rb
index e4ea7848..fa6672b8 100644
--- a/vendor/plugins/HTML5lib/lib/html5/html5parser/initial_phase.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/html5parser/initial_phase.rb
@@ -8,7 +8,7 @@ module HTML5
# "quirks mode". It is expected that a future version of HTML5 will define this.
def process_eof
- parse_error(_('Unexpected End of file. Expected DOCTYPE.'))
+ parse_error("expected-doctype-but-got-eof")
@parser.phase = @parser.phases[:rootElement]
@parser.phase.process_eof
end
@@ -19,7 +19,7 @@ module HTML5
def processDoctype(name, publicId, systemId, correct)
if name.downcase != 'html' or publicId or systemId
- parse_error(_('Erroneous DOCTYPE.'))
+ parse_error("unknown-doctype")
end
# XXX need to update DOCTYPE tokens
@tree.insertDoctype(name, publicId, systemId)
@@ -113,22 +113,21 @@ module HTML5
end
def processCharacters(data)
- parse_error(_('Unexpected non-space characters. Expected DOCTYPE.'))
+ parse_error("expected-doctype-but-got-chars")
@parser.phase = @parser.phases[:rootElement]
@parser.phase.processCharacters(data)
end
def processStartTag(name, attributes)
- parse_error(_("Unexpected start tag (#{name}). Expected DOCTYPE."))
+ parse_error("expected-doctype-but-got-start-tag", {"name" => name})
@parser.phase = @parser.phases[:rootElement]
@parser.phase.processStartTag(name, attributes)
end
def processEndTag(name)
- parse_error(_("Unexpected end tag (#{name}). Expected DOCTYPE."))
+ parse_error("expected-doctype-but-got-end-tag", {"name" => name})
@parser.phase = @parser.phases[:rootElement]
@parser.phase.processEndTag(name)
end
-
end
end
diff --git a/vendor/plugins/HTML5lib/lib/html5/html5parser/phase.rb b/vendor/plugins/HTML5lib/lib/html5/html5parser/phase.rb
index 8a7a8842..237ae7d1 100644
--- a/vendor/plugins/HTML5lib/lib/html5/html5parser/phase.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/html5parser/phase.rb
@@ -87,13 +87,13 @@ module HTML5
@tree.generateImpliedEndTags
if @tree.open_elements.length > 2
- parse_error(_('Unexpected end of file. Missing closing tags.'))
+ parse_error("expected-closing-tag-but-got-eof")
elsif @tree.open_elements.length == 2 and @tree.open_elements[1].name != 'body'
# This happens for framesets or something?
- parse_error(_("Unexpected end of file. Expected end tag (#{@tree.open_elements[1].name}) first."))
+ parse_error("expected-closing-tag-but-got-eof")
elsif @parser.inner_html and @tree.open_elements.length > 1
# XXX This is not what the specification says. Not sure what to do here.
- parse_error(_('XXX inner_html EOF'))
+ parse_error("eof-in-innerhtml")
end
# Betting ends.
end
@@ -105,7 +105,7 @@ module HTML5
end
def processDoctype(name, publicId, systemId, correct)
- parse_error(_('Unexpected DOCTYPE. Ignored.'))
+ parse_error("unexpected-doctype")
end
def processSpaceCharacters(data)
@@ -118,7 +118,7 @@ module HTML5
def startTagHtml(name, attributes)
if @parser.first_start_tag == false and name == 'html'
- parse_error(_('html needs to be the first start tag.'))
+ parse_error("non-html-root")
end
# XXX Need a check here to see if the first start tag token emitted is
# this token... If it's not, invoke parse_error.
@@ -134,10 +134,6 @@ module HTML5
send self.class.end_tag_handlers[name], name
end
- def _(string)
- string
- end
-
def assert(value)
throw AssertionError.new unless value
end
diff --git a/vendor/plugins/HTML5lib/lib/html5/html5parser/trailing_end_phase.rb b/vendor/plugins/HTML5lib/lib/html5/html5parser/trailing_end_phase.rb
index 9dd08a41..c122512d 100644
--- a/vendor/plugins/HTML5lib/lib/html5/html5parser/trailing_end_phase.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/html5parser/trailing_end_phase.rb
@@ -15,19 +15,19 @@ module HTML5
end
def processCharacters(data)
- parse_error(_('Unexpected non-space characters. Expected end of file.'))
+ parse_error("expected-eof-but-got-char")
@parser.phase = @parser.last_phase
@parser.phase.processCharacters(data)
end
def processStartTag(name, attributes)
- parse_error(_('Unexpected start tag (#{name}). Expected end of file.'))
+ parse_error("expected-eof-but-got-start-tag", {"name" => name})
@parser.phase = @parser.last_phase
@parser.phase.processStartTag(name, attributes)
end
def processEndTag(name)
- parse_error(_('Unexpected end tag (#{name}). Expected end of file.'))
+ parse_error("expected-eof-but-got-end-tag", {"name" => name})
@parser.phase = @parser.last_phase
@parser.phase.processEndTag(name)
end
diff --git a/vendor/plugins/HTML5lib/lib/html5/inputstream.rb b/vendor/plugins/HTML5lib/lib/html5/inputstream.rb
index d1dec6af..fe87bf96 100755
--- a/vendor/plugins/HTML5lib/lib/html5/inputstream.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/inputstream.rb
@@ -198,8 +198,9 @@ module HTML5
end
end
+ #TODO: huh?
require 'delegate'
- @raw_stream = SimpleDelegator.new(@raw_stream)
+ # @raw_stream = SimpleDelegator.new(@raw_stream)
class << @raw_stream
def read(chars=-1)
@@ -315,8 +316,7 @@ module HTML5
end
when 0x00
- @errors.push('null character found in input stream, ' +
- 'replaced with U+FFFD')
+ @errors.push("null-character")
[0xFFFD].pack('U') # null characters are invalid
else
diff --git a/vendor/plugins/HTML5lib/lib/html5/liberalxmlparser.rb b/vendor/plugins/HTML5lib/lib/html5/liberalxmlparser.rb
index ee4faec8..15363ed9 100755
--- a/vendor/plugins/HTML5lib/lib/html5/liberalxmlparser.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/liberalxmlparser.rb
@@ -50,7 +50,7 @@ module HTML5
when :EndTag
if token[:data]
- parse_error(_("End tag contains unexpected attributes."))
+ parse_error("attributes-in-end-tag")
end
when :Comment
@@ -81,7 +81,7 @@ module HTML5
# open and close tags are emitted
if token[:type] == :EndTag
if VOID_ELEMENTS.include? token[:name]
- if @tree.open_elements[-1].name != token["name"]:
+ if @tree.open_elements[-1].name != token["name"]
token[:type] = :EmptyTag
token["data"] ||= {}
end
diff --git a/vendor/plugins/HTML5lib/lib/html5/serializer/htmlserializer.rb b/vendor/plugins/HTML5lib/lib/html5/serializer/htmlserializer.rb
index 1f89c3fe..d8920b2c 100644
--- a/vendor/plugins/HTML5lib/lib/html5/serializer/htmlserializer.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/serializer/htmlserializer.rb
@@ -171,7 +171,6 @@ module HTML5
end
end
- def _(string); string; end
end
# Error in serialized tree
diff --git a/vendor/plugins/HTML5lib/lib/html5/tokenizer.rb b/vendor/plugins/HTML5lib/lib/html5/tokenizer.rb
index 7cb425e8..0bd97c52 100644
--- a/vendor/plugins/HTML5lib/lib/html5/tokenizer.rb
+++ b/vendor/plugins/HTML5lib/lib/html5/tokenizer.rb
@@ -69,7 +69,7 @@ module HTML5
if @current_token[:type] == :StartTag and data == ">"
@current_token[:type] = :EmptyTag
else
- @token_queue << {:type => :ParseError, :data => _("Solidus (/) incorrectly placed in tag.")}
+ @token_queue << {:type => :ParseError, :data => "incorrectly-placed-solidus"}
end
# The character we just consumed need to be put back on the stack so it
@@ -107,12 +107,12 @@ module HTML5
charAsInt = char_stack.join('').to_i(radix)
if charAsInt == 13
- @token_queue << {:type => :ParseError, :data => _("Incorrect CR newline entity. Replaced with LF.")}
+ @token_queue << {:type => :ParseError, :data => "incorrect-cr-newline-entity"}
charAsInt = 10
elsif (128..159).include? charAsInt
# If the integer is between 127 and 160 (so 128 and bigger and 159
# and smaller) we need to do the "windows trick".
- @token_queue << {:type => :ParseError, :data => _("Entity used with illegal number (windows-1252 reference).")}
+ @token_queue << {:type => :ParseError, :data => "illegal-windows-1252-entity"}
charAsInt = ENTITIES_WINDOWS1252[charAsInt - 128]
end
@@ -121,13 +121,13 @@ module HTML5
char = [charAsInt].pack('U')
else
char = [0xFFFD].pack('U')
- @token_queue << {:type => :ParseError, :data => _("Numeric entity represents an illegal codepoint.")}
+ @token_queue << {:type => :ParseError, :data => "cant-convert-numeric-entity", :datavars => {"charAsInt" => charAsInt}}
end
# Discard the ; if present. Otherwise, put it back on the queue and
# invoke parse_error on parser.
if c != ";"
- @token_queue << {:type => :ParseError, :data => _("Numeric entity didn't end with ';'.")}
+ @token_queue << {:type => :ParseError, :data => "numeric-entity-without-semicolon"}
@stream.unget(c)
end
@@ -147,7 +147,7 @@ module HTML5
# back in the queue
char_stack = char_stack[0...char_stack.index(:EOF)]
@stream.unget(char_stack)
- @token_queue << {:type => :ParseError, :data => _("Numeric entity expected. Got end of file instead.")}
+ @token_queue << {:type => :ParseError, :data => "expected-numeric-entity-but-got-eof"}
else
if char_stack[1].downcase == "x" and HEX_DIGITS.include? char_stack[2]
# Hexadecimal entity detected.
@@ -160,7 +160,7 @@ module HTML5
else
# No number entity detected.
@stream.unget(char_stack)
- @token_queue << {:type => :ParseError, :data => _("Numeric entity expected but none found.")}
+ @token_queue << {:type => :ParseError, :data => "expected-numeric-entity"}
end
end
else
@@ -196,10 +196,10 @@ module HTML5
# Check whether or not the last character returned can be
# discarded or needs to be put back.
if entityName[-1] != ?;
- @token_queue << {:type => :ParseError, :data => _("Named entity didn't end with ';'.")}
+ @token_queue << {:type => :ParseError, :data => "named-entity-without-semicolon"}
end
- if char_stack[-1] != ";" and from_attribute and
+ if entityName[-1] != ";" and from_attribute and
(ASCII_LETTERS.include?(char_stack[entityName.length]) or
DIGITS.include?(char_stack[entityName.length]))
@stream.unget(char_stack)
@@ -208,7 +208,7 @@ module HTML5
@stream.unget(char_stack[entityName.length..-1])
end
else
- @token_queue << {:type => :ParseError, :data => _("Named entity expected. Got none.")}
+ @token_queue << {:type => :ParseError, :data => "expected-named-entity"}
@stream.unget(char_stack)
end
end
@@ -217,7 +217,7 @@ module HTML5
# This method replaces the need for "entityInAttributeValueState".
def process_entity_in_attribute
- entity = consume_entity(true)
+ entity = consume_entity()
if entity
@current_token[:data][-1][1] += entity
else
@@ -309,19 +309,18 @@ module HTML5
elsif data == ">"
# XXX In theory it could be something besides a tag name. But
# do we really care?
- @token_queue << {:type => :ParseError, :data => _("Expected tag name. Got '>' instead.")}
+ @token_queue << {:type => :ParseError, :data => "expected-tag-name-but-got-right-bracket"}
@token_queue << {:type => :Characters, :data => "<>"}
@state = :data_state
elsif data == "?"
# XXX In theory it could be something besides a tag name. But
# do we really care?
- @token_queue.push({:type => :ParseError, :data => _("Expected tag name. Got '?' instead (HTML doesn't " +
- "support processing instructions).")})
+ @token_queue.push({:type => :ParseError, :data => "expected-tag-name-but-got-question-mark"})
@stream.unget(data)
@state = :bogus_comment_state
else
# XXX
- @token_queue << {:type => :ParseError, :data => _("Expected tag name. Got something else instead")}
+ @token_queue << {:type => :ParseError, :data => "expected-tag-name"}
@token_queue << {:type => :Characters, :data => "<"}
@stream.unget(data)
@state = :data_state
@@ -382,18 +381,18 @@ module HTML5
data = @stream.char
if data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Expected closing tag. Unexpected end of file.")}
+ @token_queue << {:type => :ParseError, :data => "expected-closing-tag-but-got-eof"}
@token_queue << {:type => :Characters, :data => ""}
@state = :data_state
elsif ASCII_LETTERS.include? data
@current_token = {:type => :EndTag, :name => data, :data => []}
@state = :tag_name_state
elsif data == ">"
- @token_queue << {:type => :ParseError, :data => _("Expected closing tag. Got '>' instead. Ignoring '>'.")}
+ @token_queue << {:type => :ParseError, :data => "expected-closing-tag-but-got-right-bracket"}
@state = :data_state
else
# XXX data can be _'_...
- @token_queue << {:type => :ParseError, :data => _("Expected closing tag. Unexpected character '#{data}' found.")}
+ @token_queue << {:type => :ParseError, :data => "expected-closing-tag-but-got-char", :datavars => {:data => data}}
@stream.unget(data)
@state = :bogus_comment_state
end
@@ -406,7 +405,7 @@ module HTML5
if SPACE_CHARACTERS.include? data
@state = :before_attribute_name_state
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in the tag name.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-tag-name"}
emit_current_token
elsif ASCII_LETTERS.include? data
@current_token[:name] += data + @stream.chars_until(ASCII_LETTERS, true)
@@ -426,7 +425,7 @@ module HTML5
if SPACE_CHARACTERS.include? data
@stream.chars_until(SPACE_CHARACTERS, true)
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file. Expected attribute name instead.")}
+ @token_queue << {:type => :ParseError, :data => "expected-attribute-name-but-got-eof"}
emit_current_token
elsif ASCII_LETTERS.include? data
@current_token[:data].push([data, ""])
@@ -449,7 +448,7 @@ module HTML5
if data == "="
@state = :before_attribute_value_state
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in attribute name.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-attribute-name"}
@state = :data_state
emitToken = true
elsif ASCII_LETTERS.include? data
@@ -479,7 +478,7 @@ module HTML5
end
@current_token[:data][0...-1].each {|name,value|
if @current_token[:data].last.first == name
- @token_queue << {:type => :ParseError, :data =>_("Dropped duplicate attribute on tag.")}
+ @token_queue << {:type => :ParseError, :data => "duplicate-attribute"}
break # don't report an error more than once
end
}
@@ -498,7 +497,7 @@ module HTML5
elsif data == ">"
emit_current_token
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file. Expected = or end of tag.")}
+ @token_queue << {:type => :ParseError, :data => "expected-end-of-tag-but-got-eof"}
emit_current_token
elsif ASCII_LETTERS.include? data
@current_token[:data].push([data, ""])
@@ -527,7 +526,7 @@ module HTML5
elsif data == ">"
emit_current_token
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file. Expected attribute value.")}
+ @token_queue << {:type => :ParseError, :data => "expected-attribute-value-but-got-eof"}
emit_current_token
else
@current_token[:data][-1][1] += data
@@ -543,7 +542,7 @@ module HTML5
elsif data == "&"
process_entity_in_attribute
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in attribute value (\").")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-attribute-value-double-quote"}
emit_current_token
else
@current_token[:data][-1][1] += data + @stream.chars_until(["\"", "&"])
@@ -558,7 +557,7 @@ module HTML5
elsif data == "&"
process_entity_in_attribute
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in attribute value (').")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-attribute-value-single-quote"}
emit_current_token
else
@current_token[:data][-1][1] += data +\
@@ -576,7 +575,7 @@ module HTML5
elsif data == ">"
emit_current_token
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in attribute value.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-attribute-value-no-quotes"}
emit_current_token
else
@current_token[:data][-1][1] += data + @stream.chars_until(["&", ">","<"] + SPACE_CHARACTERS)
@@ -609,7 +608,7 @@ module HTML5
@current_token = {:type => :Doctype, :name => "", :publicId => nil, :systemId => nil, :correct => true}
@state = :doctype_state
else
- @token_queue << {:type => :ParseError, :data => _("Expected '--' or 'DOCTYPE'. Not found.")}
+ @token_queue << {:type => :ParseError, :data => "expected-dashes-or-doctype"}
@stream.unget(char_stack)
@state = :bogus_comment_state
end
@@ -622,11 +621,11 @@ module HTML5
if data == "-"
@state = :comment_start_dash_state
elsif data == ">"
- @token_queue << {:type => :ParseError, :data => _("Incorrect comment.")}
+ @token_queue << {:type => :ParseError, :data => "incorrect-comment"}
@token_queue << @current_token
@state = :data_state
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in comment.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-comment"}
@token_queue << @current_token
@state = :data_state
else
@@ -641,11 +640,11 @@ module HTML5
if data == "-"
@state = :comment_end_state
elsif data == ">"
- @token_queue << {:type => :ParseError, :data => _("Incorrect comment.")}
+ @token_queue << {:type => :ParseError, :data => "incorrect-comment"}
@token_queue << @current_token
@state = :data_state
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in comment.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-comment"}
@token_queue << @current_token
@state = :data_state
else
@@ -660,7 +659,7 @@ module HTML5
if data == "-"
@state = :comment_end_dash_state
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in comment.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-comment"}
@token_queue << @current_token
@state = :data_state
else
@@ -674,7 +673,7 @@ module HTML5
if data == "-"
@state = :comment_end_state
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in comment (-)")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-comment-end-dash"}
@token_queue << @current_token
@state = :data_state
else
@@ -694,15 +693,15 @@ module HTML5
@token_queue << @current_token
@state = :data_state
elsif data == "-"
- @token_queue << {:type => :ParseError, :data => _("Unexpected '-' after '--' found in comment.")}
+ @token_queue << {:type => :ParseError, :data => "unexpected-dash-after-double-dash-in-comment"}
@current_token[:data] += data
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in comment (--).")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-comment-double-dash"}
@token_queue << @current_token
@state = :data_state
else
# XXX
- @token_queue << {:type => :ParseError, :data => _("Unexpected character in comment found.")}
+ @token_queue << {:type => :ParseError, :data => "unexpected-char-in-comment"}
@current_token[:data] += "--" + data
@state = :comment_state
end
@@ -714,7 +713,7 @@ module HTML5
if SPACE_CHARACTERS.include? data
@state = :before_doctype_name_state
else
- @token_queue << {:type => :ParseError, :data => _("No space after literal string 'DOCTYPE'.")}
+ @token_queue << {:type => :ParseError, :data => "need-space-after-doctype"}
@stream.unget(data)
@state = :before_doctype_name_state
end
@@ -725,12 +724,12 @@ module HTML5
data = @stream.char
if SPACE_CHARACTERS.include? data
elsif data == ">"
- @token_queue << {:type => :ParseError, :data => _("Unexpected > character. Expected DOCTYPE name.")}
+ @token_queue << {:type => :ParseError, :data => "expected-doctype-name-but-got-right-bracket"}
@current_token[:correct] = false
@token_queue << @current_token
@state = :data_state
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file. Expected DOCTYPE name.")}
+ @token_queue << {:type => :ParseError, :data => "expected-doctype-name-but-got-eof"}
@current_token[:correct] = false
@token_queue << @current_token
@state = :data_state
@@ -749,7 +748,7 @@ module HTML5
@token_queue << @current_token
@state = :data_state
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in DOCTYPE name.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-doctype-name"}
@current_token[:correct] = false
@token_queue << @current_token
@state = :data_state
@@ -769,7 +768,7 @@ module HTML5
elsif data == :EOF
@current_token[:correct] = false
@stream.unget(data)
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in DOCTYPE.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-doctype"}
@token_queue << @current_token
@state = :data_state
else
@@ -782,7 +781,7 @@ module HTML5
@state = :before_doctype_system_identifier_state
else
@stream.unget(char_stack)
- @token_queue << {:type => :ParseError, :data => _("Expected 'public' or 'system'. Got '#{token}'")}
+ @token_queue << {:type => :ParseError, :data => "expected-space-or-right-bracket-in-doctype", "datavars" => {"data" => data}}
@state = :bogus_doctype_state
end
end
@@ -800,17 +799,17 @@ module HTML5
@current_token[:publicId] = ""
@state = :doctype_public_identifier_single_quoted_state
elsif data == ">"
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of DOCTYPE.")}
+ @token_queue << {:type => :ParseError, :data => "unexpected-end-of-doctype"}
@current_token[:correct] = false
@token_queue << @current_token
@state = :data_state
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in DOCTYPE.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-doctype"}
@current_token[:correct] = false
@token_queue << @current_token
@state = :data_state
else
- @token_queue << {:type => :ParseError, :data => _("Unexpected character in DOCTYPE.")}
+ @token_queue << {:type => :ParseError, :data => "unexpected-char-in-doctype"}
@state = :bogus_doctype_state
end
@@ -822,7 +821,7 @@ module HTML5
if data == "\""
@state = :after_doctype_public_identifier_state
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in DOCTYPE.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-doctype"}
@current_token[:correct] = false
@token_queue << @current_token
@state = :data_state
@@ -837,7 +836,7 @@ module HTML5
if data == "'"
@state = :after_doctype_public_identifier_state
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in DOCTYPE.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-doctype"}
@current_token[:correct] = false
@token_queue << @current_token
@state = :data_state
@@ -860,12 +859,12 @@ module HTML5
@token_queue << @current_token
@state = :data_state
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in DOCTYPE.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-doctype"}
@current_token[:correct] = false
@token_queue << @current_token
@state = :data_state
else
- @token_queue << {:type => :ParseError, :data => _("Unexpected character in DOCTYPE.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-doctype"}
@state = :bogus_doctype_state
end
return true
@@ -881,17 +880,17 @@ module HTML5
@current_token[:systemId] = ""
@state = :doctype_system_identifier_single_quoted_state
elsif data == ">"
- @token_queue << {:type => :ParseError, :data => _("Unexpected character in DOCTYPE.")}
+ @token_queue << {:type => :ParseError, :data => "unexpected-char-in-doctype"}
@current_token[:correct] = false
@token_queue << @current_token
@state = :data_state
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in DOCTYPE.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-doctype"}
@current_token[:correct] = false
@token_queue << @current_token
@state = :data_state
else
- @token_queue << {:type => :ParseError, :data => _("Unexpected character in DOCTYPE.")}
+ @token_queue << {:type => :ParseError, :data => "unexpected-char-in-doctype"}
@state = :bogus_doctype_state
end
return true
@@ -902,7 +901,7 @@ module HTML5
if data == "\""
@state = :after_doctype_system_identifier_state
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in DOCTYPE.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-doctype"}
@current_token[:correct] = false
@token_queue << @current_token
@state = :data_state
@@ -917,7 +916,7 @@ module HTML5
if data == "'"
@state = :after_doctype_system_identifier_state
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in DOCTYPE.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-doctype"}
@current_token[:correct] = false
@token_queue << @current_token
@state = :data_state
@@ -934,12 +933,12 @@ module HTML5
@token_queue << @current_token
@state = :data_state
elsif data == :EOF
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in DOCTYPE.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-doctype"}
@current_token[:correct] = false
@token_queue << @current_token
@state = :data_state
else
- @token_queue << {:type => :ParseError, :data => _("Unexpected character in DOCTYPE.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-doctype"}
@state = :bogus_doctype_state
end
return true
@@ -954,7 +953,7 @@ module HTML5
elsif data == :EOF
# XXX EMIT
@stream.unget(data)
- @token_queue << {:type => :ParseError, :data => _("Unexpected end of file in bogus doctype.")}
+ @token_queue << {:type => :ParseError, :data => "eof-in-doctype"}
@current_token[:correct] = false
@token_queue << @current_token
@state = :data_state
@@ -962,7 +961,6 @@ module HTML5
return true
end
- def _(string); string; end
end
end
diff --git a/vendor/plugins/HTML5lib/testdata/sanitizer/tests1.dat b/vendor/plugins/HTML5lib/testdata/sanitizer/tests1.dat
index cc8d3c96..89a7d451 100644
--- a/vendor/plugins/HTML5lib/testdata/sanitizer/tests1.dat
+++ b/vendor/plugins/HTML5lib/testdata/sanitizer/tests1.dat
@@ -405,5 +405,12 @@
"name": "xul",
"input": "fubar
",
"output": "fubar
"
+ },
+
+ {
+ "name": "quotes_in_attributes",
+ "input": " ",
+ "rexml": " ",
+ "output": " "
}
]
diff --git a/vendor/plugins/HTML5lib/testdata/tokenizer/entities.test b/vendor/plugins/HTML5lib/testdata/tokenizer/entities.test
index 7417c529..1a4422b4 100644
--- a/vendor/plugins/HTML5lib/testdata/tokenizer/entities.test
+++ b/vendor/plugins/HTML5lib/testdata/tokenizer/entities.test
@@ -1,2335 +1,2339 @@
-{"tests": [
-
-{"description": "Named entity: AElig with a semi-colon.",
-"input":"Æ",
-"output": [["Character", "\u00C6"]]},
-
-{"description": "Named entity: AElig without a semi-colon.",
-"input":"Æ",
-"output": ["ParseError", ["Character", "\u00C6"]]},
-
-{"description": "Named entity: AMP with a semi-colon.",
-"input":"&",
-"output": [["Character", "\u0026"]]},
-
-{"description": "Named entity: AMP without a semi-colon.",
-"input":"&",
-"output": ["ParseError", ["Character", "\u0026"]]},
-
-{"description": "Named entity: Aacute with a semi-colon.",
-"input":"Á",
-"output": [["Character", "\u00C1"]]},
-
-{"description": "Named entity: Aacute without a semi-colon.",
-"input":"Á",
-"output": ["ParseError", ["Character", "\u00C1"]]},
-
-{"description": "Named entity: Acirc with a semi-colon.",
-"input":"Â",
-"output": [["Character", "\u00C2"]]},
-
-{"description": "Named entity: Acirc without a semi-colon.",
-"input":"Â",
-"output": ["ParseError", ["Character", "\u00C2"]]},
-
-{"description": "Named entity: Agrave with a semi-colon.",
-"input":"À",
-"output": [["Character", "\u00C0"]]},
-
-{"description": "Named entity: Agrave without a semi-colon.",
-"input":"À",
-"output": ["ParseError", ["Character", "\u00C0"]]},
-
-{"description": "Named entity: Alpha with a semi-colon.",
-"input":"Α",
-"output": [["Character", "\u0391"]]},
-
-{"description": "Named entity: Aring with a semi-colon.",
-"input":"Å",
-"output": [["Character", "\u00C5"]]},
-
-{"description": "Named entity: Aring without a semi-colon.",
-"input":"Å",
-"output": ["ParseError", ["Character", "\u00C5"]]},
-
-{"description": "Named entity: Atilde with a semi-colon.",
-"input":"Ã",
-"output": [["Character", "\u00C3"]]},
-
-{"description": "Named entity: Atilde without a semi-colon.",
-"input":"Ã",
-"output": ["ParseError", ["Character", "\u00C3"]]},
-
-{"description": "Named entity: Auml with a semi-colon.",
-"input":"Ä",
-"output": [["Character", "\u00C4"]]},
-
-{"description": "Named entity: Auml without a semi-colon.",
-"input":"Ä",
-"output": ["ParseError", ["Character", "\u00C4"]]},
-
-{"description": "Named entity: Beta with a semi-colon.",
-"input":"Β",
-"output": [["Character", "\u0392"]]},
-
-{"description": "Named entity: COPY with a semi-colon.",
-"input":"©",
-"output": [["Character", "\u00A9"]]},
-
-{"description": "Named entity: COPY without a semi-colon.",
-"input":"©",
-"output": ["ParseError", ["Character", "\u00A9"]]},
-
-{"description": "Named entity: Ccedil with a semi-colon.",
-"input":"Ç",
-"output": [["Character", "\u00C7"]]},
-
-{"description": "Named entity: Ccedil without a semi-colon.",
-"input":"Ç",
-"output": ["ParseError", ["Character", "\u00C7"]]},
-
-{"description": "Named entity: Chi with a semi-colon.",
-"input":"Χ",
-"output": [["Character", "\u03A7"]]},
-
-{"description": "Named entity: Dagger with a semi-colon.",
-"input":"‡",
-"output": [["Character", "\u2021"]]},
-
-{"description": "Named entity: Delta with a semi-colon.",
-"input":"Δ",
-"output": [["Character", "\u0394"]]},
-
-{"description": "Named entity: ETH with a semi-colon.",
-"input":"Ð",
-"output": [["Character", "\u00D0"]]},
-
-{"description": "Named entity: ETH without a semi-colon.",
-"input":"Ð",
-"output": ["ParseError", ["Character", "\u00D0"]]},
-
-{"description": "Named entity: Eacute with a semi-colon.",
-"input":"É",
-"output": [["Character", "\u00C9"]]},
-
-{"description": "Named entity: Eacute without a semi-colon.",
-"input":"É",
-"output": ["ParseError", ["Character", "\u00C9"]]},
-
-{"description": "Named entity: Ecirc with a semi-colon.",
-"input":"Ê",
-"output": [["Character", "\u00CA"]]},
-
-{"description": "Named entity: Ecirc without a semi-colon.",
-"input":"Ê",
-"output": ["ParseError", ["Character", "\u00CA"]]},
-
-{"description": "Named entity: Egrave with a semi-colon.",
-"input":"È",
-"output": [["Character", "\u00C8"]]},
-
-{"description": "Named entity: Egrave without a semi-colon.",
-"input":"È",
-"output": ["ParseError", ["Character", "\u00C8"]]},
-
-{"description": "Named entity: Epsilon with a semi-colon.",
-"input":"Ε",
-"output": [["Character", "\u0395"]]},
-
-{"description": "Named entity: Eta with a semi-colon.",
-"input":"Η",
-"output": [["Character", "\u0397"]]},
-
-{"description": "Named entity: Euml with a semi-colon.",
-"input":"Ë",
-"output": [["Character", "\u00CB"]]},
-
-{"description": "Named entity: Euml without a semi-colon.",
-"input":"Ë",
-"output": ["ParseError", ["Character", "\u00CB"]]},
-
-{"description": "Named entity: GT with a semi-colon.",
-"input":">",
-"output": [["Character", "\u003E"]]},
-
-{"description": "Named entity: GT without a semi-colon.",
-"input":">",
-"output": ["ParseError", ["Character", "\u003E"]]},
-
-{"description": "Named entity: Gamma with a semi-colon.",
-"input":"Γ",
-"output": [["Character", "\u0393"]]},
-
-{"description": "Named entity: Iacute with a semi-colon.",
-"input":"Í",
-"output": [["Character", "\u00CD"]]},
-
-{"description": "Named entity: Iacute without a semi-colon.",
-"input":"Í",
-"output": ["ParseError", ["Character", "\u00CD"]]},
-
-{"description": "Named entity: Icirc with a semi-colon.",
-"input":"Î",
-"output": [["Character", "\u00CE"]]},
-
-{"description": "Named entity: Icirc without a semi-colon.",
-"input":"Î",
-"output": ["ParseError", ["Character", "\u00CE"]]},
-
-{"description": "Named entity: Igrave with a semi-colon.",
-"input":"Ì",
-"output": [["Character", "\u00CC"]]},
-
-{"description": "Named entity: Igrave without a semi-colon.",
-"input":"Ì",
-"output": ["ParseError", ["Character", "\u00CC"]]},
-
-{"description": "Named entity: Iota with a semi-colon.",
-"input":"Ι",
-"output": [["Character", "\u0399"]]},
-
-{"description": "Named entity: Iuml with a semi-colon.",
-"input":"Ï",
-"output": [["Character", "\u00CF"]]},
-
-{"description": "Named entity: Iuml without a semi-colon.",
-"input":"Ï",
-"output": ["ParseError", ["Character", "\u00CF"]]},
-
-{"description": "Named entity: Kappa with a semi-colon.",
-"input":"Κ",
-"output": [["Character", "\u039A"]]},
-
-{"description": "Named entity: LT with a semi-colon.",
-"input":"<",
-"output": [["Character", "\u003C"]]},
-
-{"description": "Named entity: LT without a semi-colon.",
-"input":"<",
-"output": ["ParseError", ["Character", "\u003C"]]},
-
-{"description": "Named entity: Lambda with a semi-colon.",
-"input":"Λ",
-"output": [["Character", "\u039B"]]},
-
-{"description": "Named entity: Mu with a semi-colon.",
-"input":"Μ",
-"output": [["Character", "\u039C"]]},
-
-{"description": "Named entity: Ntilde with a semi-colon.",
-"input":"Ñ",
-"output": [["Character", "\u00D1"]]},
-
-{"description": "Named entity: Ntilde without a semi-colon.",
-"input":"Ñ",
-"output": ["ParseError", ["Character", "\u00D1"]]},
-
-{"description": "Named entity: Nu with a semi-colon.",
-"input":"Ν",
-"output": [["Character", "\u039D"]]},
-
-{"description": "Named entity: OElig with a semi-colon.",
-"input":"Œ",
-"output": [["Character", "\u0152"]]},
-
-{"description": "Named entity: Oacute with a semi-colon.",
-"input":"Ó",
-"output": [["Character", "\u00D3"]]},
-
-{"description": "Named entity: Oacute without a semi-colon.",
-"input":"Ó",
-"output": ["ParseError", ["Character", "\u00D3"]]},
-
-{"description": "Named entity: Ocirc with a semi-colon.",
-"input":"Ô",
-"output": [["Character", "\u00D4"]]},
-
-{"description": "Named entity: Ocirc without a semi-colon.",
-"input":"Ô",
-"output": ["ParseError", ["Character", "\u00D4"]]},
-
-{"description": "Named entity: Ograve with a semi-colon.",
-"input":"Ò",
-"output": [["Character", "\u00D2"]]},
-
-{"description": "Named entity: Ograve without a semi-colon.",
-"input":"Ò",
-"output": ["ParseError", ["Character", "\u00D2"]]},
-
-{"description": "Named entity: Omega with a semi-colon.",
-"input":"Ω",
-"output": [["Character", "\u03A9"]]},
-
-{"description": "Named entity: Omicron with a semi-colon.",
-"input":"Ο",
-"output": [["Character", "\u039F"]]},
-
-{"description": "Named entity: Oslash with a semi-colon.",
-"input":"Ø",
-"output": [["Character", "\u00D8"]]},
-
-{"description": "Named entity: Oslash without a semi-colon.",
-"input":"Ø",
-"output": ["ParseError", ["Character", "\u00D8"]]},
-
-{"description": "Named entity: Otilde with a semi-colon.",
-"input":"Õ",
-"output": [["Character", "\u00D5"]]},
-
-{"description": "Named entity: Otilde without a semi-colon.",
-"input":"Õ",
-"output": ["ParseError", ["Character", "\u00D5"]]},
-
-{"description": "Named entity: Ouml with a semi-colon.",
-"input":"Ö",
-"output": [["Character", "\u00D6"]]},
-
-{"description": "Named entity: Ouml without a semi-colon.",
-"input":"Ö",
-"output": ["ParseError", ["Character", "\u00D6"]]},
-
-{"description": "Named entity: Phi with a semi-colon.",
-"input":"Φ",
-"output": [["Character", "\u03A6"]]},
-
-{"description": "Named entity: Pi with a semi-colon.",
-"input":"Π",
-"output": [["Character", "\u03A0"]]},
-
-{"description": "Named entity: Prime with a semi-colon.",
-"input":"″",
-"output": [["Character", "\u2033"]]},
-
-{"description": "Named entity: Psi with a semi-colon.",
-"input":"Ψ",
-"output": [["Character", "\u03A8"]]},
-
-{"description": "Named entity: QUOT with a semi-colon.",
-"input":""",
-"output": [["Character", "\u0022"]]},
-
-{"description": "Named entity: QUOT without a semi-colon.",
-"input":""",
-"output": ["ParseError", ["Character", "\u0022"]]},
-
-{"description": "Named entity: REG with a semi-colon.",
-"input":"®",
-"output": [["Character", "\u00AE"]]},
-
-{"description": "Named entity: REG without a semi-colon.",
-"input":"®",
-"output": ["ParseError", ["Character", "\u00AE"]]},
-
-{"description": "Named entity: Rho with a semi-colon.",
-"input":"Ρ",
-"output": [["Character", "\u03A1"]]},
-
-{"description": "Named entity: Scaron with a semi-colon.",
-"input":"Š",
-"output": [["Character", "\u0160"]]},
-
-{"description": "Named entity: Sigma with a semi-colon.",
-"input":"Σ",
-"output": [["Character", "\u03A3"]]},
-
-{"description": "Named entity: THORN with a semi-colon.",
-"input":"Þ",
-"output": [["Character", "\u00DE"]]},
-
-{"description": "Named entity: THORN without a semi-colon.",
-"input":"Þ",
-"output": ["ParseError", ["Character", "\u00DE"]]},
-
-{"description": "Named entity: TRADE with a semi-colon.",
-"input":"™",
-"output": [["Character", "\u2122"]]},
-
-{"description": "Named entity: Tau with a semi-colon.",
-"input":"Τ",
-"output": [["Character", "\u03A4"]]},
-
-{"description": "Named entity: Theta with a semi-colon.",
-"input":"Θ",
-"output": [["Character", "\u0398"]]},
-
-{"description": "Named entity: Uacute with a semi-colon.",
-"input":"Ú",
-"output": [["Character", "\u00DA"]]},
-
-{"description": "Named entity: Uacute without a semi-colon.",
-"input":"Ú",
-"output": ["ParseError", ["Character", "\u00DA"]]},
-
-{"description": "Named entity: Ucirc with a semi-colon.",
-"input":"Û",
-"output": [["Character", "\u00DB"]]},
-
-{"description": "Named entity: Ucirc without a semi-colon.",
-"input":"Û",
-"output": ["ParseError", ["Character", "\u00DB"]]},
-
-{"description": "Named entity: Ugrave with a semi-colon.",
-"input":"Ù",
-"output": [["Character", "\u00D9"]]},
-
-{"description": "Named entity: Ugrave without a semi-colon.",
-"input":"Ù",
-"output": ["ParseError", ["Character", "\u00D9"]]},
-
-{"description": "Named entity: Upsilon with a semi-colon.",
-"input":"Υ",
-"output": [["Character", "\u03A5"]]},
-
-{"description": "Named entity: Uuml with a semi-colon.",
-"input":"Ü",
-"output": [["Character", "\u00DC"]]},
-
-{"description": "Named entity: Uuml without a semi-colon.",
-"input":"Ü",
-"output": ["ParseError", ["Character", "\u00DC"]]},
-
-{"description": "Named entity: Xi with a semi-colon.",
-"input":"Ξ",
-"output": [["Character", "\u039E"]]},
-
-{"description": "Named entity: Yacute with a semi-colon.",
-"input":"Ý",
-"output": [["Character", "\u00DD"]]},
-
-{"description": "Named entity: Yacute without a semi-colon.",
-"input":"Ý",
-"output": ["ParseError", ["Character", "\u00DD"]]},
-
-{"description": "Named entity: Yuml with a semi-colon.",
-"input":"Ÿ",
-"output": [["Character", "\u0178"]]},
-
-{"description": "Named entity: Zeta with a semi-colon.",
-"input":"Ζ",
-"output": [["Character", "\u0396"]]},
-
-{"description": "Named entity: aacute with a semi-colon.",
-"input":"á",
-"output": [["Character", "\u00E1"]]},
-
-{"description": "Named entity: aacute without a semi-colon.",
-"input":"á",
-"output": ["ParseError", ["Character", "\u00E1"]]},
-
-{"description": "Named entity: acirc with a semi-colon.",
-"input":"â",
-"output": [["Character", "\u00E2"]]},
-
-{"description": "Named entity: acirc without a semi-colon.",
-"input":"â",
-"output": ["ParseError", ["Character", "\u00E2"]]},
-
-{"description": "Named entity: acute with a semi-colon.",
-"input":"´",
-"output": [["Character", "\u00B4"]]},
-
-{"description": "Named entity: acute without a semi-colon.",
-"input":"´",
-"output": ["ParseError", ["Character", "\u00B4"]]},
-
-{"description": "Named entity: aelig with a semi-colon.",
-"input":"æ",
-"output": [["Character", "\u00E6"]]},
-
-{"description": "Named entity: aelig without a semi-colon.",
-"input":"æ",
-"output": ["ParseError", ["Character", "\u00E6"]]},
-
-{"description": "Named entity: agrave with a semi-colon.",
-"input":"à",
-"output": [["Character", "\u00E0"]]},
-
-{"description": "Named entity: agrave without a semi-colon.",
-"input":"à",
-"output": ["ParseError", ["Character", "\u00E0"]]},
-
-{"description": "Named entity: alefsym with a semi-colon.",
-"input":"ℵ",
-"output": [["Character", "\u2135"]]},
-
-{"description": "Named entity: alpha with a semi-colon.",
-"input":"α",
-"output": [["Character", "\u03B1"]]},
-
-{"description": "Named entity: amp with a semi-colon.",
-"input":"&",
-"output": [["Character", "\u0026"]]},
-
-{"description": "Named entity: amp without a semi-colon.",
-"input":"&",
-"output": ["ParseError", ["Character", "\u0026"]]},
-
-{"description": "Named entity: and with a semi-colon.",
-"input":"∧",
-"output": [["Character", "\u2227"]]},
-
-{"description": "Named entity: ang with a semi-colon.",
-"input":"∠",
-"output": [["Character", "\u2220"]]},
-
-{"description": "Named entity: apos with a semi-colon.",
-"input":"'",
-"output": [["Character", "\u0027"]]},
-
-{"description": "Named entity: aring with a semi-colon.",
-"input":"å",
-"output": [["Character", "\u00E5"]]},
-
-{"description": "Named entity: aring without a semi-colon.",
-"input":"å",
-"output": ["ParseError", ["Character", "\u00E5"]]},
-
-{"description": "Named entity: asymp with a semi-colon.",
-"input":"≈",
-"output": [["Character", "\u2248"]]},
-
-{"description": "Named entity: atilde with a semi-colon.",
-"input":"ã",
-"output": [["Character", "\u00E3"]]},
-
-{"description": "Named entity: atilde without a semi-colon.",
-"input":"ã",
-"output": ["ParseError", ["Character", "\u00E3"]]},
-
-{"description": "Named entity: auml with a semi-colon.",
-"input":"ä",
-"output": [["Character", "\u00E4"]]},
-
-{"description": "Named entity: auml without a semi-colon.",
-"input":"ä",
-"output": ["ParseError", ["Character", "\u00E4"]]},
-
-{"description": "Named entity: bdquo with a semi-colon.",
-"input":"„",
-"output": [["Character", "\u201E"]]},
-
-{"description": "Named entity: beta with a semi-colon.",
-"input":"β",
-"output": [["Character", "\u03B2"]]},
-
-{"description": "Named entity: brvbar with a semi-colon.",
-"input":"¦",
-"output": [["Character", "\u00A6"]]},
-
-{"description": "Named entity: brvbar without a semi-colon.",
-"input":"¦",
-"output": ["ParseError", ["Character", "\u00A6"]]},
-
-{"description": "Named entity: bull with a semi-colon.",
-"input":"•",
-"output": [["Character", "\u2022"]]},
-
-{"description": "Named entity: cap with a semi-colon.",
-"input":"∩",
-"output": [["Character", "\u2229"]]},
-
-{"description": "Named entity: ccedil with a semi-colon.",
-"input":"ç",
-"output": [["Character", "\u00E7"]]},
-
-{"description": "Named entity: ccedil without a semi-colon.",
-"input":"ç",
-"output": ["ParseError", ["Character", "\u00E7"]]},
-
-{"description": "Named entity: cedil with a semi-colon.",
-"input":"¸",
-"output": [["Character", "\u00B8"]]},
-
-{"description": "Named entity: cedil without a semi-colon.",
-"input":"¸",
-"output": ["ParseError", ["Character", "\u00B8"]]},
-
-{"description": "Named entity: cent with a semi-colon.",
-"input":"¢",
-"output": [["Character", "\u00A2"]]},
-
-{"description": "Named entity: cent without a semi-colon.",
-"input":"¢",
-"output": ["ParseError", ["Character", "\u00A2"]]},
-
-{"description": "Named entity: chi with a semi-colon.",
-"input":"χ",
-"output": [["Character", "\u03C7"]]},
-
-{"description": "Named entity: circ with a semi-colon.",
-"input":"ˆ",
-"output": [["Character", "\u02C6"]]},
-
-{"description": "Named entity: clubs with a semi-colon.",
-"input":"♣",
-"output": [["Character", "\u2663"]]},
-
-{"description": "Named entity: cong with a semi-colon.",
-"input":"≅",
-"output": [["Character", "\u2245"]]},
-
-{"description": "Named entity: copy with a semi-colon.",
-"input":"©",
-"output": [["Character", "\u00A9"]]},
-
-{"description": "Named entity: copy without a semi-colon.",
-"input":"©",
-"output": ["ParseError", ["Character", "\u00A9"]]},
-
-{"description": "Named entity: crarr with a semi-colon.",
-"input":"↵",
-"output": [["Character", "\u21B5"]]},
-
-{"description": "Named entity: cup with a semi-colon.",
-"input":"∪",
-"output": [["Character", "\u222A"]]},
-
-{"description": "Named entity: curren with a semi-colon.",
-"input":"¤",
-"output": [["Character", "\u00A4"]]},
-
-{"description": "Named entity: curren without a semi-colon.",
-"input":"¤",
-"output": ["ParseError", ["Character", "\u00A4"]]},
-
-{"description": "Named entity: dArr with a semi-colon.",
-"input":"⇓",
-"output": [["Character", "\u21D3"]]},
-
-{"description": "Named entity: dagger with a semi-colon.",
-"input":"†",
-"output": [["Character", "\u2020"]]},
-
-{"description": "Named entity: darr with a semi-colon.",
-"input":"↓",
-"output": [["Character", "\u2193"]]},
-
-{"description": "Named entity: deg with a semi-colon.",
-"input":"°",
-"output": [["Character", "\u00B0"]]},
-
-{"description": "Named entity: deg without a semi-colon.",
-"input":"°",
-"output": ["ParseError", ["Character", "\u00B0"]]},
-
-{"description": "Named entity: delta with a semi-colon.",
-"input":"δ",
-"output": [["Character", "\u03B4"]]},
-
-{"description": "Named entity: diams with a semi-colon.",
-"input":"♦",
-"output": [["Character", "\u2666"]]},
-
-{"description": "Named entity: divide with a semi-colon.",
-"input":"÷",
-"output": [["Character", "\u00F7"]]},
-
-{"description": "Named entity: divide without a semi-colon.",
-"input":"÷",
-"output": ["ParseError", ["Character", "\u00F7"]]},
-
-{"description": "Named entity: eacute with a semi-colon.",
-"input":"é",
-"output": [["Character", "\u00E9"]]},
-
-{"description": "Named entity: eacute without a semi-colon.",
-"input":"é",
-"output": ["ParseError", ["Character", "\u00E9"]]},
-
-{"description": "Named entity: ecirc with a semi-colon.",
-"input":"ê",
-"output": [["Character", "\u00EA"]]},
-
-{"description": "Named entity: ecirc without a semi-colon.",
-"input":"ê",
-"output": ["ParseError", ["Character", "\u00EA"]]},
-
-{"description": "Named entity: egrave with a semi-colon.",
-"input":"è",
-"output": [["Character", "\u00E8"]]},
-
-{"description": "Named entity: egrave without a semi-colon.",
-"input":"è",
-"output": ["ParseError", ["Character", "\u00E8"]]},
-
-{"description": "Named entity: empty with a semi-colon.",
-"input":"∅",
-"output": [["Character", "\u2205"]]},
-
-{"description": "Named entity: emsp with a semi-colon.",
-"input":" ",
-"output": [["Character", "\u2003"]]},
-
-{"description": "Named entity: ensp with a semi-colon.",
-"input":" ",
-"output": [["Character", "\u2002"]]},
-
-{"description": "Named entity: epsilon with a semi-colon.",
-"input":"ε",
-"output": [["Character", "\u03B5"]]},
-
-{"description": "Named entity: equiv with a semi-colon.",
-"input":"≡",
-"output": [["Character", "\u2261"]]},
-
-{"description": "Named entity: eta with a semi-colon.",
-"input":"η",
-"output": [["Character", "\u03B7"]]},
-
-{"description": "Named entity: eth with a semi-colon.",
-"input":"ð",
-"output": [["Character", "\u00F0"]]},
-
-{"description": "Named entity: eth without a semi-colon.",
-"input":"ð",
-"output": ["ParseError", ["Character", "\u00F0"]]},
-
-{"description": "Named entity: euml with a semi-colon.",
-"input":"ë",
-"output": [["Character", "\u00EB"]]},
-
-{"description": "Named entity: euml without a semi-colon.",
-"input":"ë",
-"output": ["ParseError", ["Character", "\u00EB"]]},
-
-{"description": "Named entity: euro with a semi-colon.",
-"input":"€",
-"output": [["Character", "\u20AC"]]},
-
-{"description": "Named entity: exist with a semi-colon.",
-"input":"∃",
-"output": [["Character", "\u2203"]]},
-
-{"description": "Named entity: fnof with a semi-colon.",
-"input":"ƒ",
-"output": [["Character", "\u0192"]]},
-
-{"description": "Named entity: forall with a semi-colon.",
-"input":"∀",
-"output": [["Character", "\u2200"]]},
-
-{"description": "Named entity: frac12 with a semi-colon.",
-"input":"½",
-"output": [["Character", "\u00BD"]]},
-
-{"description": "Named entity: frac12 without a semi-colon.",
-"input":"½",
-"output": ["ParseError", ["Character", "\u00BD"]]},
-
-{"description": "Named entity: frac14 with a semi-colon.",
-"input":"¼",
-"output": [["Character", "\u00BC"]]},
-
-{"description": "Named entity: frac14 without a semi-colon.",
-"input":"¼",
-"output": ["ParseError", ["Character", "\u00BC"]]},
-
-{"description": "Named entity: frac34 with a semi-colon.",
-"input":"¾",
-"output": [["Character", "\u00BE"]]},
-
-{"description": "Named entity: frac34 without a semi-colon.",
-"input":"¾",
-"output": ["ParseError", ["Character", "\u00BE"]]},
-
-{"description": "Named entity: frasl with a semi-colon.",
-"input":"⁄",
-"output": [["Character", "\u2044"]]},
-
-{"description": "Named entity: gamma with a semi-colon.",
-"input":"γ",
-"output": [["Character", "\u03B3"]]},
-
-{"description": "Named entity: ge with a semi-colon.",
-"input":"≥",
-"output": [["Character", "\u2265"]]},
-
-{"description": "Named entity: gt with a semi-colon.",
-"input":">",
-"output": [["Character", "\u003E"]]},
-
-{"description": "Named entity: gt without a semi-colon.",
-"input":">",
-"output": ["ParseError", ["Character", "\u003E"]]},
-
-{"description": "Named entity: hArr with a semi-colon.",
-"input":"⇔",
-"output": [["Character", "\u21D4"]]},
-
-{"description": "Named entity: harr with a semi-colon.",
-"input":"↔",
-"output": [["Character", "\u2194"]]},
-
-{"description": "Named entity: hearts with a semi-colon.",
-"input":"♥",
-"output": [["Character", "\u2665"]]},
-
-{"description": "Named entity: hellip with a semi-colon.",
-"input":"…",
-"output": [["Character", "\u2026"]]},
-
-{"description": "Named entity: iacute with a semi-colon.",
-"input":"í",
-"output": [["Character", "\u00ED"]]},
-
-{"description": "Named entity: iacute without a semi-colon.",
-"input":"í",
-"output": ["ParseError", ["Character", "\u00ED"]]},
-
-{"description": "Named entity: icirc with a semi-colon.",
-"input":"î",
-"output": [["Character", "\u00EE"]]},
-
-{"description": "Named entity: icirc without a semi-colon.",
-"input":"î",
-"output": ["ParseError", ["Character", "\u00EE"]]},
-
-{"description": "Named entity: iexcl with a semi-colon.",
-"input":"¡",
-"output": [["Character", "\u00A1"]]},
-
-{"description": "Named entity: iexcl without a semi-colon.",
-"input":"¡",
-"output": ["ParseError", ["Character", "\u00A1"]]},
-
-{"description": "Named entity: igrave with a semi-colon.",
-"input":"ì",
-"output": [["Character", "\u00EC"]]},
-
-{"description": "Named entity: igrave without a semi-colon.",
-"input":"ì",
-"output": ["ParseError", ["Character", "\u00EC"]]},
-
-{"description": "Named entity: image with a semi-colon.",
-"input":"ℑ",
-"output": [["Character", "\u2111"]]},
-
-{"description": "Named entity: infin with a semi-colon.",
-"input":"∞",
-"output": [["Character", "\u221E"]]},
-
-{"description": "Named entity: int with a semi-colon.",
-"input":"∫",
-"output": [["Character", "\u222B"]]},
-
-{"description": "Named entity: iota with a semi-colon.",
-"input":"ι",
-"output": [["Character", "\u03B9"]]},
-
-{"description": "Named entity: iquest with a semi-colon.",
-"input":"¿",
-"output": [["Character", "\u00BF"]]},
-
-{"description": "Named entity: iquest without a semi-colon.",
-"input":"¿",
-"output": ["ParseError", ["Character", "\u00BF"]]},
-
-{"description": "Named entity: isin with a semi-colon.",
-"input":"∈",
-"output": [["Character", "\u2208"]]},
-
-{"description": "Named entity: iuml with a semi-colon.",
-"input":"ï",
-"output": [["Character", "\u00EF"]]},
-
-{"description": "Named entity: iuml without a semi-colon.",
-"input":"ï",
-"output": ["ParseError", ["Character", "\u00EF"]]},
-
-{"description": "Named entity: kappa with a semi-colon.",
-"input":"κ",
-"output": [["Character", "\u03BA"]]},
-
-{"description": "Named entity: lArr with a semi-colon.",
-"input":"⇐",
-"output": [["Character", "\u21D0"]]},
-
-{"description": "Named entity: lambda with a semi-colon.",
-"input":"λ",
-"output": [["Character", "\u03BB"]]},
-
-{"description": "Named entity: lang with a semi-colon.",
-"input":"〈",
-"output": [["Character", "\u3008"]]},
-
-{"description": "Named entity: laquo with a semi-colon.",
-"input":"«",
-"output": [["Character", "\u00AB"]]},
-
-{"description": "Named entity: laquo without a semi-colon.",
-"input":"«",
-"output": ["ParseError", ["Character", "\u00AB"]]},
-
-{"description": "Named entity: larr with a semi-colon.",
-"input":"←",
-"output": [["Character", "\u2190"]]},
-
-{"description": "Named entity: lceil with a semi-colon.",
-"input":"⌈",
-"output": [["Character", "\u2308"]]},
-
-{"description": "Named entity: ldquo with a semi-colon.",
-"input":"“",
-"output": [["Character", "\u201C"]]},
-
-{"description": "Named entity: le with a semi-colon.",
-"input":"≤",
-"output": [["Character", "\u2264"]]},
-
-{"description": "Named entity: lfloor with a semi-colon.",
-"input":"⌊",
-"output": [["Character", "\u230A"]]},
-
-{"description": "Named entity: lowast with a semi-colon.",
-"input":"∗",
-"output": [["Character", "\u2217"]]},
-
-{"description": "Named entity: loz with a semi-colon.",
-"input":"◊",
-"output": [["Character", "\u25CA"]]},
-
-{"description": "Named entity: lrm with a semi-colon.",
-"input":"",
-"output": [["Character", "\u200E"]]},
-
-{"description": "Named entity: lsaquo with a semi-colon.",
-"input":"‹",
-"output": [["Character", "\u2039"]]},
-
-{"description": "Named entity: lsquo with a semi-colon.",
-"input":"‘",
-"output": [["Character", "\u2018"]]},
-
-{"description": "Named entity: lt with a semi-colon.",
-"input":"<",
-"output": [["Character", "\u003C"]]},
-
-{"description": "Named entity: lt without a semi-colon.",
-"input":"<",
-"output": ["ParseError", ["Character", "\u003C"]]},
-
-{"description": "Named entity: macr with a semi-colon.",
-"input":"¯",
-"output": [["Character", "\u00AF"]]},
-
-{"description": "Named entity: macr without a semi-colon.",
-"input":"¯",
-"output": ["ParseError", ["Character", "\u00AF"]]},
-
-{"description": "Named entity: mdash with a semi-colon.",
-"input":"—",
-"output": [["Character", "\u2014"]]},
-
-{"description": "Named entity: micro with a semi-colon.",
-"input":"µ",
-"output": [["Character", "\u00B5"]]},
-
-{"description": "Named entity: micro without a semi-colon.",
-"input":"µ",
-"output": ["ParseError", ["Character", "\u00B5"]]},
-
-{"description": "Named entity: middot with a semi-colon.",
-"input":"·",
-"output": [["Character", "\u00B7"]]},
-
-{"description": "Named entity: middot without a semi-colon.",
-"input":"·",
-"output": ["ParseError", ["Character", "\u00B7"]]},
-
-{"description": "Named entity: minus with a semi-colon.",
-"input":"−",
-"output": [["Character", "\u2212"]]},
-
-{"description": "Named entity: mu with a semi-colon.",
-"input":"μ",
-"output": [["Character", "\u03BC"]]},
-
-{"description": "Named entity: nabla with a semi-colon.",
-"input":"∇",
-"output": [["Character", "\u2207"]]},
-
-{"description": "Named entity: nbsp with a semi-colon.",
-"input":" ",
-"output": [["Character", "\u00A0"]]},
-
-{"description": "Named entity: nbsp without a semi-colon.",
-"input":" ",
-"output": ["ParseError", ["Character", "\u00A0"]]},
-
-{"description": "Named entity: ndash with a semi-colon.",
-"input":"–",
-"output": [["Character", "\u2013"]]},
-
-{"description": "Named entity: ne with a semi-colon.",
-"input":"≠",
-"output": [["Character", "\u2260"]]},
-
-{"description": "Named entity: ni with a semi-colon.",
-"input":"∋",
-"output": [["Character", "\u220B"]]},
-
-{"description": "Named entity: not with a semi-colon.",
-"input":"¬",
-"output": [["Character", "\u00AC"]]},
-
-{"description": "Named entity: not without a semi-colon.",
-"input":"¬",
-"output": ["ParseError", ["Character", "\u00AC"]]},
-
-{"description": "Named entity: notin with a semi-colon.",
-"input":"∉",
-"output": [["Character", "\u2209"]]},
-
-{"description": "Named entity: nsub with a semi-colon.",
-"input":"⊄",
-"output": [["Character", "\u2284"]]},
-
-{"description": "Named entity: ntilde with a semi-colon.",
-"input":"ñ",
-"output": [["Character", "\u00F1"]]},
-
-{"description": "Named entity: ntilde without a semi-colon.",
-"input":"ñ",
-"output": ["ParseError", ["Character", "\u00F1"]]},
-
-{"description": "Named entity: nu with a semi-colon.",
-"input":"ν",
-"output": [["Character", "\u03BD"]]},
-
-{"description": "Named entity: oacute with a semi-colon.",
-"input":"ó",
-"output": [["Character", "\u00F3"]]},
-
-{"description": "Named entity: oacute without a semi-colon.",
-"input":"ó",
-"output": ["ParseError", ["Character", "\u00F3"]]},
-
-{"description": "Named entity: ocirc with a semi-colon.",
-"input":"ô",
-"output": [["Character", "\u00F4"]]},
-
-{"description": "Named entity: ocirc without a semi-colon.",
-"input":"ô",
-"output": ["ParseError", ["Character", "\u00F4"]]},
-
-{"description": "Named entity: oelig with a semi-colon.",
-"input":"œ",
-"output": [["Character", "\u0153"]]},
-
-{"description": "Named entity: ograve with a semi-colon.",
-"input":"ò",
-"output": [["Character", "\u00F2"]]},
-
-{"description": "Named entity: ograve without a semi-colon.",
-"input":"ò",
-"output": ["ParseError", ["Character", "\u00F2"]]},
-
-{"description": "Named entity: oline with a semi-colon.",
-"input":"‾",
-"output": [["Character", "\u203E"]]},
-
-{"description": "Named entity: omega with a semi-colon.",
-"input":"ω",
-"output": [["Character", "\u03C9"]]},
-
-{"description": "Named entity: omicron with a semi-colon.",
-"input":"ο",
-"output": [["Character", "\u03BF"]]},
-
-{"description": "Named entity: oplus with a semi-colon.",
-"input":"⊕",
-"output": [["Character", "\u2295"]]},
-
-{"description": "Named entity: or with a semi-colon.",
-"input":"∨",
-"output": [["Character", "\u2228"]]},
-
-{"description": "Named entity: ordf with a semi-colon.",
-"input":"ª",
-"output": [["Character", "\u00AA"]]},
-
-{"description": "Named entity: ordf without a semi-colon.",
-"input":"ª",
-"output": ["ParseError", ["Character", "\u00AA"]]},
-
-{"description": "Named entity: ordm with a semi-colon.",
-"input":"º",
-"output": [["Character", "\u00BA"]]},
-
-{"description": "Named entity: ordm without a semi-colon.",
-"input":"º",
-"output": ["ParseError", ["Character", "\u00BA"]]},
-
-{"description": "Named entity: oslash with a semi-colon.",
-"input":"ø",
-"output": [["Character", "\u00F8"]]},
-
-{"description": "Named entity: oslash without a semi-colon.",
-"input":"ø",
-"output": ["ParseError", ["Character", "\u00F8"]]},
-
-{"description": "Named entity: otilde with a semi-colon.",
-"input":"õ",
-"output": [["Character", "\u00F5"]]},
-
-{"description": "Named entity: otilde without a semi-colon.",
-"input":"õ",
-"output": ["ParseError", ["Character", "\u00F5"]]},
-
-{"description": "Named entity: otimes with a semi-colon.",
-"input":"⊗",
-"output": [["Character", "\u2297"]]},
-
-{"description": "Named entity: ouml with a semi-colon.",
-"input":"ö",
-"output": [["Character", "\u00F6"]]},
-
-{"description": "Named entity: ouml without a semi-colon.",
-"input":"ö",
-"output": ["ParseError", ["Character", "\u00F6"]]},
-
-{"description": "Named entity: para with a semi-colon.",
-"input":"¶",
-"output": [["Character", "\u00B6"]]},
-
-{"description": "Named entity: para without a semi-colon.",
-"input":"¶",
-"output": ["ParseError", ["Character", "\u00B6"]]},
-
-{"description": "Named entity: part with a semi-colon.",
-"input":"∂",
-"output": [["Character", "\u2202"]]},
-
-{"description": "Named entity: permil with a semi-colon.",
-"input":"‰",
-"output": [["Character", "\u2030"]]},
-
-{"description": "Named entity: perp with a semi-colon.",
-"input":"⊥",
-"output": [["Character", "\u22A5"]]},
-
-{"description": "Named entity: phi with a semi-colon.",
-"input":"φ",
-"output": [["Character", "\u03C6"]]},
-
-{"description": "Named entity: pi with a semi-colon.",
-"input":"π",
-"output": [["Character", "\u03C0"]]},
-
-{"description": "Named entity: piv with a semi-colon.",
-"input":"ϖ",
-"output": [["Character", "\u03D6"]]},
-
-{"description": "Named entity: plusmn with a semi-colon.",
-"input":"±",
-"output": [["Character", "\u00B1"]]},
-
-{"description": "Named entity: plusmn without a semi-colon.",
-"input":"±",
-"output": ["ParseError", ["Character", "\u00B1"]]},
-
-{"description": "Named entity: pound with a semi-colon.",
-"input":"£",
-"output": [["Character", "\u00A3"]]},
-
-{"description": "Named entity: pound without a semi-colon.",
-"input":"£",
-"output": ["ParseError", ["Character", "\u00A3"]]},
-
-{"description": "Named entity: prime with a semi-colon.",
-"input":"′",
-"output": [["Character", "\u2032"]]},
-
-{"description": "Named entity: prod with a semi-colon.",
-"input":"∏",
-"output": [["Character", "\u220F"]]},
-
-{"description": "Named entity: prop with a semi-colon.",
-"input":"∝",
-"output": [["Character", "\u221D"]]},
-
-{"description": "Named entity: psi with a semi-colon.",
-"input":"ψ",
-"output": [["Character", "\u03C8"]]},
-
-{"description": "Named entity: quot with a semi-colon.",
-"input":""",
-"output": [["Character", "\u0022"]]},
-
-{"description": "Named entity: quot without a semi-colon.",
-"input":""",
-"output": ["ParseError", ["Character", "\u0022"]]},
-
-{"description": "Named entity: rArr with a semi-colon.",
-"input":"⇒",
-"output": [["Character", "\u21D2"]]},
-
-{"description": "Named entity: radic with a semi-colon.",
-"input":"√",
-"output": [["Character", "\u221A"]]},
-
-{"description": "Named entity: rang with a semi-colon.",
-"input":"〉",
-"output": [["Character", "\u3009"]]},
-
-{"description": "Named entity: raquo with a semi-colon.",
-"input":"»",
-"output": [["Character", "\u00BB"]]},
-
-{"description": "Named entity: raquo without a semi-colon.",
-"input":"»",
-"output": ["ParseError", ["Character", "\u00BB"]]},
-
-{"description": "Named entity: rarr with a semi-colon.",
-"input":"→",
-"output": [["Character", "\u2192"]]},
-
-{"description": "Named entity: rceil with a semi-colon.",
-"input":"⌉",
-"output": [["Character", "\u2309"]]},
-
-{"description": "Named entity: rdquo with a semi-colon.",
-"input":"”",
-"output": [["Character", "\u201D"]]},
-
-{"description": "Named entity: real with a semi-colon.",
-"input":"ℜ",
-"output": [["Character", "\u211C"]]},
-
-{"description": "Named entity: reg with a semi-colon.",
-"input":"®",
-"output": [["Character", "\u00AE"]]},
-
-{"description": "Named entity: reg without a semi-colon.",
-"input":"®",
-"output": ["ParseError", ["Character", "\u00AE"]]},
-
-{"description": "Named entity: rfloor with a semi-colon.",
-"input":"⌋",
-"output": [["Character", "\u230B"]]},
-
-{"description": "Named entity: rho with a semi-colon.",
-"input":"ρ",
-"output": [["Character", "\u03C1"]]},
-
-{"description": "Named entity: rlm with a semi-colon.",
-"input":"",
-"output": [["Character", "\u200F"]]},
-
-{"description": "Named entity: rsaquo with a semi-colon.",
-"input":"›",
-"output": [["Character", "\u203A"]]},
-
-{"description": "Named entity: rsquo with a semi-colon.",
-"input":"’",
-"output": [["Character", "\u2019"]]},
-
-{"description": "Named entity: sbquo with a semi-colon.",
-"input":"‚",
-"output": [["Character", "\u201A"]]},
-
-{"description": "Named entity: scaron with a semi-colon.",
-"input":"š",
-"output": [["Character", "\u0161"]]},
-
-{"description": "Named entity: sdot with a semi-colon.",
-"input":"⋅",
-"output": [["Character", "\u22C5"]]},
-
-{"description": "Named entity: sect with a semi-colon.",
-"input":"§",
-"output": [["Character", "\u00A7"]]},
-
-{"description": "Named entity: sect without a semi-colon.",
-"input":"§",
-"output": ["ParseError", ["Character", "\u00A7"]]},
-
-{"description": "Named entity: shy with a semi-colon.",
-"input":"",
-"output": [["Character", "\u00AD"]]},
-
-{"description": "Named entity: shy without a semi-colon.",
-"input":"­",
-"output": ["ParseError", ["Character", "\u00AD"]]},
-
-{"description": "Named entity: sigma with a semi-colon.",
-"input":"σ",
-"output": [["Character", "\u03C3"]]},
-
-{"description": "Named entity: sigmaf with a semi-colon.",
-"input":"ς",
-"output": [["Character", "\u03C2"]]},
-
-{"description": "Named entity: sim with a semi-colon.",
-"input":"∼",
-"output": [["Character", "\u223C"]]},
-
-{"description": "Named entity: spades with a semi-colon.",
-"input":"♠",
-"output": [["Character", "\u2660"]]},
-
-{"description": "Named entity: sub with a semi-colon.",
-"input":"⊂",
-"output": [["Character", "\u2282"]]},
-
-{"description": "Named entity: sube with a semi-colon.",
-"input":"⊆",
-"output": [["Character", "\u2286"]]},
-
-{"description": "Named entity: sum with a semi-colon.",
-"input":"∑",
-"output": [["Character", "\u2211"]]},
-
-{"description": "Named entity: sup1 with a semi-colon.",
-"input":"¹",
-"output": [["Character", "\u00B9"]]},
-
-{"description": "Named entity: sup1 without a semi-colon.",
-"input":"¹",
-"output": ["ParseError", ["Character", "\u00B9"]]},
-
-{"description": "Named entity: sup2 with a semi-colon.",
-"input":"²",
-"output": [["Character", "\u00B2"]]},
-
-{"description": "Named entity: sup2 without a semi-colon.",
-"input":"²",
-"output": ["ParseError", ["Character", "\u00B2"]]},
-
-{"description": "Named entity: sup3 with a semi-colon.",
-"input":"³",
-"output": [["Character", "\u00B3"]]},
-
-{"description": "Named entity: sup3 without a semi-colon.",
-"input":"³",
-"output": ["ParseError", ["Character", "\u00B3"]]},
-
-{"description": "Named entity: sup with a semi-colon.",
-"input":"⊃",
-"output": [["Character", "\u2283"]]},
-
-{"description": "Named entity: supe with a semi-colon.",
-"input":"⊇",
-"output": [["Character", "\u2287"]]},
-
-{"description": "Named entity: szlig with a semi-colon.",
-"input":"ß",
-"output": [["Character", "\u00DF"]]},
-
-{"description": "Named entity: szlig without a semi-colon.",
-"input":"ß",
-"output": ["ParseError", ["Character", "\u00DF"]]},
-
-{"description": "Named entity: tau with a semi-colon.",
-"input":"τ",
-"output": [["Character", "\u03C4"]]},
-
-{"description": "Named entity: there4 with a semi-colon.",
-"input":"∴",
-"output": [["Character", "\u2234"]]},
-
-{"description": "Named entity: theta with a semi-colon.",
-"input":"θ",
-"output": [["Character", "\u03B8"]]},
-
-{"description": "Named entity: thetasym with a semi-colon.",
-"input":"ϑ",
-"output": [["Character", "\u03D1"]]},
-
-{"description": "Named entity: thinsp with a semi-colon.",
-"input":" ",
-"output": [["Character", "\u2009"]]},
-
-{"description": "Named entity: thorn with a semi-colon.",
-"input":"þ",
-"output": [["Character", "\u00FE"]]},
-
-{"description": "Named entity: thorn without a semi-colon.",
-"input":"þ",
-"output": ["ParseError", ["Character", "\u00FE"]]},
-
-{"description": "Named entity: tilde with a semi-colon.",
-"input":"˜",
-"output": [["Character", "\u02DC"]]},
-
-{"description": "Named entity: times with a semi-colon.",
-"input":"×",
-"output": [["Character", "\u00D7"]]},
-
-{"description": "Named entity: times without a semi-colon.",
-"input":"×",
-"output": ["ParseError", ["Character", "\u00D7"]]},
-
-{"description": "Named entity: trade with a semi-colon.",
-"input":"™",
-"output": [["Character", "\u2122"]]},
-
-{"description": "Named entity: uArr with a semi-colon.",
-"input":"⇑",
-"output": [["Character", "\u21D1"]]},
-
-{"description": "Named entity: uacute with a semi-colon.",
-"input":"ú",
-"output": [["Character", "\u00FA"]]},
-
-{"description": "Named entity: uacute without a semi-colon.",
-"input":"ú",
-"output": ["ParseError", ["Character", "\u00FA"]]},
-
-{"description": "Named entity: uarr with a semi-colon.",
-"input":"↑",
-"output": [["Character", "\u2191"]]},
-
-{"description": "Named entity: ucirc with a semi-colon.",
-"input":"û",
-"output": [["Character", "\u00FB"]]},
-
-{"description": "Named entity: ucirc without a semi-colon.",
-"input":"û",
-"output": ["ParseError", ["Character", "\u00FB"]]},
-
-{"description": "Named entity: ugrave with a semi-colon.",
-"input":"ù",
-"output": [["Character", "\u00F9"]]},
-
-{"description": "Named entity: ugrave without a semi-colon.",
-"input":"ù",
-"output": ["ParseError", ["Character", "\u00F9"]]},
-
-{"description": "Named entity: uml with a semi-colon.",
-"input":"¨",
-"output": [["Character", "\u00A8"]]},
-
-{"description": "Named entity: uml without a semi-colon.",
-"input":"¨",
-"output": ["ParseError", ["Character", "\u00A8"]]},
-
-{"description": "Named entity: upsih with a semi-colon.",
-"input":"ϒ",
-"output": [["Character", "\u03D2"]]},
-
-{"description": "Named entity: upsilon with a semi-colon.",
-"input":"υ",
-"output": [["Character", "\u03C5"]]},
-
-{"description": "Named entity: uuml with a semi-colon.",
-"input":"ü",
-"output": [["Character", "\u00FC"]]},
-
-{"description": "Named entity: uuml without a semi-colon.",
-"input":"ü",
-"output": ["ParseError", ["Character", "\u00FC"]]},
-
-{"description": "Named entity: weierp with a semi-colon.",
-"input":"℘",
-"output": [["Character", "\u2118"]]},
-
-{"description": "Named entity: xi with a semi-colon.",
-"input":"ξ",
-"output": [["Character", "\u03BE"]]},
-
-{"description": "Named entity: yacute with a semi-colon.",
-"input":"ý",
-"output": [["Character", "\u00FD"]]},
-
-{"description": "Named entity: yacute without a semi-colon.",
-"input":"ý",
-"output": ["ParseError", ["Character", "\u00FD"]]},
-
-{"description": "Named entity: yen with a semi-colon.",
-"input":"¥",
-"output": [["Character", "\u00A5"]]},
-
-{"description": "Named entity: yen without a semi-colon.",
-"input":"¥",
-"output": ["ParseError", ["Character", "\u00A5"]]},
-
-{"description": "Named entity: yuml with a semi-colon.",
-"input":"ÿ",
-"output": [["Character", "\u00FF"]]},
-
-{"description": "Named entity: yuml without a semi-colon.",
-"input":"ÿ",
-"output": ["ParseError", ["Character", "\u00FF"]]},
-
-{"description": "Named entity: zeta with a semi-colon.",
-"input":"ζ",
-"output": [["Character", "\u03B6"]]},
-
-{"description": "Named entity: zwj with a semi-colon.",
-"input":"",
-"output": [["Character", "\u200D"]]},
-
-{"description": "Named entity: zwnj with a semi-colon.",
-"input":"",
-"output": [["Character", "\u200C"]]},
-
-{"description": "Bad named entity: Alpha without a semi-colon.",
-"input":"&Alpha",
-"output": ["ParseError", ["Character", "&Alpha"]]},
-
-{"description": "Bad named entity: alpha without a semi-colon.",
-"input":"&alpha",
-"output": ["ParseError", ["Character", "&alpha"]]},
-
-{"description": "Bad named entity: and without a semi-colon.",
-"input":"&and",
-"output": ["ParseError", ["Character", "&and"]]},
-
-{"description": "Bad named entity: ang without a semi-colon.",
-"input":"&ang",
-"output": ["ParseError", ["Character", "&ang"]]},
-
-{"description": "Bad named entity: apos without a semi-colon.",
-"input":"&apos",
-"output": ["ParseError", ["Character", "&apos"]]},
-
-{"description": "Bad named entity: asymp without a semi-colon.",
-"input":"&asymp",
-"output": ["ParseError", ["Character", "&asymp"]]},
-
-{"description": "Bad named entity: bdquo without a semi-colon.",
-"input":"&bdquo",
-"output": ["ParseError", ["Character", "&bdquo"]]},
-
-{"description": "Bad named entity: Beta without a semi-colon.",
-"input":"&Beta",
-"output": ["ParseError", ["Character", "&Beta"]]},
-
-{"description": "Bad named entity: beta without a semi-colon.",
-"input":"&beta",
-"output": ["ParseError", ["Character", "&beta"]]},
-
-{"description": "Bad named entity: bull without a semi-colon.",
-"input":"&bull",
-"output": ["ParseError", ["Character", "&bull"]]},
-
-{"description": "Bad named entity: cap without a semi-colon.",
-"input":"&cap",
-"output": ["ParseError", ["Character", "&cap"]]},
-
-{"description": "Bad named entity: Chi without a semi-colon.",
-"input":"&Chi",
-"output": ["ParseError", ["Character", "&Chi"]]},
-
-{"description": "Bad named entity: chi without a semi-colon.",
-"input":"&chi",
-"output": ["ParseError", ["Character", "&chi"]]},
-
-{"description": "Bad named entity: circ without a semi-colon.",
-"input":"&circ",
-"output": ["ParseError", ["Character", "&circ"]]},
-
-{"description": "Bad named entity: clubs without a semi-colon.",
-"input":"&clubs",
-"output": ["ParseError", ["Character", "&clubs"]]},
-
-{"description": "Bad named entity: cong without a semi-colon.",
-"input":"&cong",
-"output": ["ParseError", ["Character", "&cong"]]},
-
-{"description": "Bad named entity: crarr without a semi-colon.",
-"input":"&crarr",
-"output": ["ParseError", ["Character", "&crarr"]]},
-
-{"description": "Bad named entity: cup without a semi-colon.",
-"input":"&cup",
-"output": ["ParseError", ["Character", "&cup"]]},
-
-{"description": "Bad named entity: dagger without a semi-colon.",
-"input":"&dagger",
-"output": ["ParseError", ["Character", "&dagger"]]},
-
-{"description": "Bad named entity: dagger without a semi-colon.",
-"input":"&dagger",
-"output": ["ParseError", ["Character", "&dagger"]]},
-
-{"description": "Bad named entity: darr without a semi-colon.",
-"input":"&darr",
-"output": ["ParseError", ["Character", "&darr"]]},
-
-{"description": "Bad named entity: darr without a semi-colon.",
-"input":"&darr",
-"output": ["ParseError", ["Character", "&darr"]]},
-
-{"description": "Bad named entity: Delta without a semi-colon.",
-"input":"&Delta",
-"output": ["ParseError", ["Character", "&Delta"]]},
-
-{"description": "Bad named entity: delta without a semi-colon.",
-"input":"&delta",
-"output": ["ParseError", ["Character", "&delta"]]},
-
-{"description": "Bad named entity: diams without a semi-colon.",
-"input":"&diams",
-"output": ["ParseError", ["Character", "&diams"]]},
-
-{"description": "Bad named entity: empty without a semi-colon.",
-"input":"&empty",
-"output": ["ParseError", ["Character", "&empty"]]},
-
-{"description": "Bad named entity: emsp without a semi-colon.",
-"input":"&emsp",
-"output": ["ParseError", ["Character", "&emsp"]]},
-
-{"description": "Bad named entity: ensp without a semi-colon.",
-"input":"&ensp",
-"output": ["ParseError", ["Character", "&ensp"]]},
-
-{"description": "Bad named entity: Epsilon without a semi-colon.",
-"input":"&Epsilon",
-"output": ["ParseError", ["Character", "&Epsilon"]]},
-
-{"description": "Bad named entity: epsilon without a semi-colon.",
-"input":"&epsilon",
-"output": ["ParseError", ["Character", "&epsilon"]]},
-
-{"description": "Bad named entity: equiv without a semi-colon.",
-"input":"&equiv",
-"output": ["ParseError", ["Character", "&equiv"]]},
-
-{"description": "Bad named entity: Eta without a semi-colon.",
-"input":"&Eta",
-"output": ["ParseError", ["Character", "&Eta"]]},
-
-{"description": "Bad named entity: eta without a semi-colon.",
-"input":"&eta",
-"output": ["ParseError", ["Character", "&eta"]]},
-
-{"description": "Bad named entity: euro without a semi-colon.",
-"input":"&euro",
-"output": ["ParseError", ["Character", "&euro"]]},
-
-{"description": "Bad named entity: exist without a semi-colon.",
-"input":"&exist",
-"output": ["ParseError", ["Character", "&exist"]]},
-
-{"description": "Bad named entity: fnof without a semi-colon.",
-"input":"&fnof",
-"output": ["ParseError", ["Character", "&fnof"]]},
-
-{"description": "Bad named entity: forall without a semi-colon.",
-"input":"&forall",
-"output": ["ParseError", ["Character", "&forall"]]},
-
-{"description": "Bad named entity: frasl without a semi-colon.",
-"input":"&frasl",
-"output": ["ParseError", ["Character", "&frasl"]]},
-
-{"description": "Bad named entity: Gamma without a semi-colon.",
-"input":"&Gamma",
-"output": ["ParseError", ["Character", "&Gamma"]]},
-
-{"description": "Bad named entity: gamma without a semi-colon.",
-"input":"&gamma",
-"output": ["ParseError", ["Character", "&gamma"]]},
-
-{"description": "Bad named entity: ge without a semi-colon.",
-"input":"&ge",
-"output": ["ParseError", ["Character", "&ge"]]},
-
-{"description": "Bad named entity: harr without a semi-colon.",
-"input":"&harr",
-"output": ["ParseError", ["Character", "&harr"]]},
-
-{"description": "Bad named entity: harr without a semi-colon.",
-"input":"&harr",
-"output": ["ParseError", ["Character", "&harr"]]},
-
-{"description": "Bad named entity: hearts without a semi-colon.",
-"input":"&hearts",
-"output": ["ParseError", ["Character", "&hearts"]]},
-
-{"description": "Bad named entity: hellip without a semi-colon.",
-"input":"&hellip",
-"output": ["ParseError", ["Character", "&hellip"]]},
-
-{"description": "Bad named entity: image without a semi-colon.",
-"input":"&image",
-"output": ["ParseError", ["Character", "&image"]]},
-
-{"description": "Bad named entity: infin without a semi-colon.",
-"input":"&infin",
-"output": ["ParseError", ["Character", "&infin"]]},
-
-{"description": "Bad named entity: int without a semi-colon.",
-"input":"&int",
-"output": ["ParseError", ["Character", "&int"]]},
-
-{"description": "Bad named entity: Iota without a semi-colon.",
-"input":"&Iota",
-"output": ["ParseError", ["Character", "&Iota"]]},
-
-{"description": "Bad named entity: iota without a semi-colon.",
-"input":"&iota",
-"output": ["ParseError", ["Character", "&iota"]]},
-
-{"description": "Bad named entity: isin without a semi-colon.",
-"input":"&isin",
-"output": ["ParseError", ["Character", "&isin"]]},
-
-{"description": "Bad named entity: Kappa without a semi-colon.",
-"input":"&Kappa",
-"output": ["ParseError", ["Character", "&Kappa"]]},
-
-{"description": "Bad named entity: kappa without a semi-colon.",
-"input":"&kappa",
-"output": ["ParseError", ["Character", "&kappa"]]},
-
-{"description": "Bad named entity: Lambda without a semi-colon.",
-"input":"&Lambda",
-"output": ["ParseError", ["Character", "&Lambda"]]},
-
-{"description": "Bad named entity: lambda without a semi-colon.",
-"input":"&lambda",
-"output": ["ParseError", ["Character", "&lambda"]]},
-
-{"description": "Bad named entity: lang without a semi-colon.",
-"input":"&lang",
-"output": ["ParseError", ["Character", "&lang"]]},
-
-{"description": "Bad named entity: larr without a semi-colon.",
-"input":"&larr",
-"output": ["ParseError", ["Character", "&larr"]]},
-
-{"description": "Bad named entity: larr without a semi-colon.",
-"input":"&larr",
-"output": ["ParseError", ["Character", "&larr"]]},
-
-{"description": "Bad named entity: lceil without a semi-colon.",
-"input":"&lceil",
-"output": ["ParseError", ["Character", "&lceil"]]},
-
-{"description": "Bad named entity: ldquo without a semi-colon.",
-"input":"&ldquo",
-"output": ["ParseError", ["Character", "&ldquo"]]},
-
-{"description": "Bad named entity: le without a semi-colon.",
-"input":"&le",
-"output": ["ParseError", ["Character", "&le"]]},
-
-{"description": "Bad named entity: lfloor without a semi-colon.",
-"input":"&lfloor",
-"output": ["ParseError", ["Character", "&lfloor"]]},
-
-{"description": "Bad named entity: lowast without a semi-colon.",
-"input":"&lowast",
-"output": ["ParseError", ["Character", "&lowast"]]},
-
-{"description": "Bad named entity: loz without a semi-colon.",
-"input":"&loz",
-"output": ["ParseError", ["Character", "&loz"]]},
-
-{"description": "Bad named entity: lrm without a semi-colon.",
-"input":"&lrm",
-"output": ["ParseError", ["Character", "&lrm"]]},
-
-{"description": "Bad named entity: lsaquo without a semi-colon.",
-"input":"&lsaquo",
-"output": ["ParseError", ["Character", "&lsaquo"]]},
-
-{"description": "Bad named entity: lsquo without a semi-colon.",
-"input":"&lsquo",
-"output": ["ParseError", ["Character", "&lsquo"]]},
-
-{"description": "Bad named entity: mdash without a semi-colon.",
-"input":"&mdash",
-"output": ["ParseError", ["Character", "&mdash"]]},
-
-{"description": "Bad named entity: minus without a semi-colon.",
-"input":"&minus",
-"output": ["ParseError", ["Character", "&minus"]]},
-
-{"description": "Bad named entity: Mu without a semi-colon.",
-"input":"&Mu",
-"output": ["ParseError", ["Character", "&Mu"]]},
-
-{"description": "Bad named entity: mu without a semi-colon.",
-"input":"&mu",
-"output": ["ParseError", ["Character", "&mu"]]},
-
-{"description": "Bad named entity: nabla without a semi-colon.",
-"input":"&nabla",
-"output": ["ParseError", ["Character", "&nabla"]]},
-
-{"description": "Bad named entity: ndash without a semi-colon.",
-"input":"&ndash",
-"output": ["ParseError", ["Character", "&ndash"]]},
-
-{"description": "Bad named entity: ne without a semi-colon.",
-"input":"&ne",
-"output": ["ParseError", ["Character", "&ne"]]},
-
-{"description": "Bad named entity: ni without a semi-colon.",
-"input":"&ni",
-"output": ["ParseError", ["Character", "&ni"]]},
-
-{"description": "Bad named entity: notin without a semi-colon.",
-"input":"¬in",
-"output": ["ParseError", ["Character", "\u00ACin"]]},
-
-{"description": "Bad named entity: nsub without a semi-colon.",
-"input":"&nsub",
-"output": ["ParseError", ["Character", "&nsub"]]},
-
-{"description": "Bad named entity: Nu without a semi-colon.",
-"input":"&Nu",
-"output": ["ParseError", ["Character", "&Nu"]]},
-
-{"description": "Bad named entity: nu without a semi-colon.",
-"input":"&nu",
-"output": ["ParseError", ["Character", "&nu"]]},
-
-{"description": "Bad named entity: OElig without a semi-colon.",
-"input":"&OElig",
-"output": ["ParseError", ["Character", "&OElig"]]},
-
-{"description": "Bad named entity: oelig without a semi-colon.",
-"input":"&oelig",
-"output": ["ParseError", ["Character", "&oelig"]]},
-
-{"description": "Bad named entity: oline without a semi-colon.",
-"input":"&oline",
-"output": ["ParseError", ["Character", "&oline"]]},
-
-{"description": "Bad named entity: Omega without a semi-colon.",
-"input":"&Omega",
-"output": ["ParseError", ["Character", "&Omega"]]},
-
-{"description": "Bad named entity: omega without a semi-colon.",
-"input":"&omega",
-"output": ["ParseError", ["Character", "&omega"]]},
-
-{"description": "Bad named entity: Omicron without a semi-colon.",
-"input":"&Omicron",
-"output": ["ParseError", ["Character", "&Omicron"]]},
-
-{"description": "Bad named entity: omicron without a semi-colon.",
-"input":"&omicron",
-"output": ["ParseError", ["Character", "&omicron"]]},
-
-{"description": "Bad named entity: oplus without a semi-colon.",
-"input":"&oplus",
-"output": ["ParseError", ["Character", "&oplus"]]},
-
-{"description": "Bad named entity: or without a semi-colon.",
-"input":"&or",
-"output": ["ParseError", ["Character", "&or"]]},
-
-{"description": "Bad named entity: otimes without a semi-colon.",
-"input":"&otimes",
-"output": ["ParseError", ["Character", "&otimes"]]},
-
-{"description": "Bad named entity: part without a semi-colon.",
-"input":"&part",
-"output": ["ParseError", ["Character", "&part"]]},
-
-{"description": "Bad named entity: permil without a semi-colon.",
-"input":"&permil",
-"output": ["ParseError", ["Character", "&permil"]]},
-
-{"description": "Bad named entity: perp without a semi-colon.",
-"input":"&perp",
-"output": ["ParseError", ["Character", "&perp"]]},
-
-{"description": "Bad named entity: Phi without a semi-colon.",
-"input":"&Phi",
-"output": ["ParseError", ["Character", "&Phi"]]},
-
-{"description": "Bad named entity: phi without a semi-colon.",
-"input":"&phi",
-"output": ["ParseError", ["Character", "&phi"]]},
-
-{"description": "Bad named entity: Pi without a semi-colon.",
-"input":"&Pi",
-"output": ["ParseError", ["Character", "&Pi"]]},
-
-{"description": "Bad named entity: pi without a semi-colon.",
-"input":"&pi",
-"output": ["ParseError", ["Character", "&pi"]]},
-
-{"description": "Bad named entity: piv without a semi-colon.",
-"input":"&piv",
-"output": ["ParseError", ["Character", "&piv"]]},
-
-{"description": "Bad named entity: prime without a semi-colon.",
-"input":"&prime",
-"output": ["ParseError", ["Character", "&prime"]]},
-
-{"description": "Bad named entity: prime without a semi-colon.",
-"input":"&prime",
-"output": ["ParseError", ["Character", "&prime"]]},
-
-{"description": "Bad named entity: prod without a semi-colon.",
-"input":"&prod",
-"output": ["ParseError", ["Character", "&prod"]]},
-
-{"description": "Bad named entity: prop without a semi-colon.",
-"input":"&prop",
-"output": ["ParseError", ["Character", "&prop"]]},
-
-{"description": "Bad named entity: Psi without a semi-colon.",
-"input":"&Psi",
-"output": ["ParseError", ["Character", "&Psi"]]},
-
-{"description": "Bad named entity: psi without a semi-colon.",
-"input":"&psi",
-"output": ["ParseError", ["Character", "&psi"]]},
-
-{"description": "Bad named entity: radic without a semi-colon.",
-"input":"&radic",
-"output": ["ParseError", ["Character", "&radic"]]},
-
-{"description": "Bad named entity: rang without a semi-colon.",
-"input":"&rang",
-"output": ["ParseError", ["Character", "&rang"]]},
-
-{"description": "Bad named entity: rarr without a semi-colon.",
-"input":"&rarr",
-"output": ["ParseError", ["Character", "&rarr"]]},
-
-{"description": "Bad named entity: rarr without a semi-colon.",
-"input":"&rarr",
-"output": ["ParseError", ["Character", "&rarr"]]},
-
-{"description": "Bad named entity: rceil without a semi-colon.",
-"input":"&rceil",
-"output": ["ParseError", ["Character", "&rceil"]]},
-
-{"description": "Bad named entity: rdquo without a semi-colon.",
-"input":"&rdquo",
-"output": ["ParseError", ["Character", "&rdquo"]]},
-
-{"description": "Bad named entity: real without a semi-colon.",
-"input":"&real",
-"output": ["ParseError", ["Character", "&real"]]},
-
-{"description": "Bad named entity: rfloor without a semi-colon.",
-"input":"&rfloor",
-"output": ["ParseError", ["Character", "&rfloor"]]},
-
-{"description": "Bad named entity: Rho without a semi-colon.",
-"input":"&Rho",
-"output": ["ParseError", ["Character", "&Rho"]]},
-
-{"description": "Bad named entity: rho without a semi-colon.",
-"input":"&rho",
-"output": ["ParseError", ["Character", "&rho"]]},
-
-{"description": "Bad named entity: rlm without a semi-colon.",
-"input":"&rlm",
-"output": ["ParseError", ["Character", "&rlm"]]},
-
-{"description": "Bad named entity: rsaquo without a semi-colon.",
-"input":"&rsaquo",
-"output": ["ParseError", ["Character", "&rsaquo"]]},
-
-{"description": "Bad named entity: rsquo without a semi-colon.",
-"input":"&rsquo",
-"output": ["ParseError", ["Character", "&rsquo"]]},
-
-{"description": "Bad named entity: sbquo without a semi-colon.",
-"input":"&sbquo",
-"output": ["ParseError", ["Character", "&sbquo"]]},
-
-{"description": "Bad named entity: Scaron without a semi-colon.",
-"input":"&Scaron",
-"output": ["ParseError", ["Character", "&Scaron"]]},
-
-{"description": "Bad named entity: scaron without a semi-colon.",
-"input":"&scaron",
-"output": ["ParseError", ["Character", "&scaron"]]},
-
-{"description": "Bad named entity: sdot without a semi-colon.",
-"input":"&sdot",
-"output": ["ParseError", ["Character", "&sdot"]]},
-
-{"description": "Bad named entity: Sigma without a semi-colon.",
-"input":"&Sigma",
-"output": ["ParseError", ["Character", "&Sigma"]]},
-
-{"description": "Bad named entity: sigma without a semi-colon.",
-"input":"&sigma",
-"output": ["ParseError", ["Character", "&sigma"]]},
-
-{"description": "Bad named entity: sigmaf without a semi-colon.",
-"input":"&sigmaf",
-"output": ["ParseError", ["Character", "&sigmaf"]]},
-
-{"description": "Bad named entity: sim without a semi-colon.",
-"input":"&sim",
-"output": ["ParseError", ["Character", "&sim"]]},
-
-{"description": "Bad named entity: spades without a semi-colon.",
-"input":"&spades",
-"output": ["ParseError", ["Character", "&spades"]]},
-
-{"description": "Bad named entity: sub without a semi-colon.",
-"input":"&sub",
-"output": ["ParseError", ["Character", "&sub"]]},
-
-{"description": "Bad named entity: sube without a semi-colon.",
-"input":"&sube",
-"output": ["ParseError", ["Character", "&sube"]]},
-
-{"description": "Bad named entity: sum without a semi-colon.",
-"input":"&sum",
-"output": ["ParseError", ["Character", "&sum"]]},
-
-{"description": "Bad named entity: sup without a semi-colon.",
-"input":"&sup",
-"output": ["ParseError", ["Character", "&sup"]]},
-
-{"description": "Bad named entity: supe without a semi-colon.",
-"input":"&supe",
-"output": ["ParseError", ["Character", "&supe"]]},
-
-{"description": "Bad named entity: Tau without a semi-colon.",
-"input":"&Tau",
-"output": ["ParseError", ["Character", "&Tau"]]},
-
-{"description": "Bad named entity: tau without a semi-colon.",
-"input":"&tau",
-"output": ["ParseError", ["Character", "&tau"]]},
-
-{"description": "Bad named entity: there4 without a semi-colon.",
-"input":"&there4",
-"output": ["ParseError", ["Character", "&there4"]]},
-
-{"description": "Bad named entity: Theta without a semi-colon.",
-"input":"&Theta",
-"output": ["ParseError", ["Character", "&Theta"]]},
-
-{"description": "Bad named entity: theta without a semi-colon.",
-"input":"&theta",
-"output": ["ParseError", ["Character", "&theta"]]},
-
-{"description": "Bad named entity: thetasym without a semi-colon.",
-"input":"&thetasym",
-"output": ["ParseError", ["Character", "&thetasym"]]},
-
-{"description": "Bad named entity: thinsp without a semi-colon.",
-"input":"&thinsp",
-"output": ["ParseError", ["Character", "&thinsp"]]},
-
-{"description": "Bad named entity: tilde without a semi-colon.",
-"input":"&tilde",
-"output": ["ParseError", ["Character", "&tilde"]]},
-
-{"description": "Bad named entity: trade without a semi-colon.",
-"input":"&trade",
-"output": ["ParseError", ["Character", "&trade"]]},
-
-{"description": "Bad named entity: uarr without a semi-colon.",
-"input":"&uarr",
-"output": ["ParseError", ["Character", "&uarr"]]},
-
-{"description": "Bad named entity: uarr without a semi-colon.",
-"input":"&uarr",
-"output": ["ParseError", ["Character", "&uarr"]]},
-
-{"description": "Bad named entity: upsih without a semi-colon.",
-"input":"&upsih",
-"output": ["ParseError", ["Character", "&upsih"]]},
-
-{"description": "Bad named entity: Upsilon without a semi-colon.",
-"input":"&Upsilon",
-"output": ["ParseError", ["Character", "&Upsilon"]]},
-
-{"description": "Bad named entity: upsilon without a semi-colon.",
-"input":"&upsilon",
-"output": ["ParseError", ["Character", "&upsilon"]]},
-
-{"description": "Bad named entity: weierp without a semi-colon.",
-"input":"&weierp",
-"output": ["ParseError", ["Character", "&weierp"]]},
-
-{"description": "Bad named entity: Xi without a semi-colon.",
-"input":"&Xi",
-"output": ["ParseError", ["Character", "&Xi"]]},
-
-{"description": "Bad named entity: xi without a semi-colon.",
-"input":"&xi",
-"output": ["ParseError", ["Character", "&xi"]]},
-
-{"description": "Bad named entity: Yuml without a semi-colon.",
-"input":"&Yuml",
-"output": ["ParseError", ["Character", "&Yuml"]]},
-
-{"description": "Bad named entity: Zeta without a semi-colon.",
-"input":"&Zeta",
-"output": ["ParseError", ["Character", "&Zeta"]]},
-
-{"description": "Bad named entity: zeta without a semi-colon.",
-"input":"&zeta",
-"output": ["ParseError", ["Character", "&zeta"]]},
-
-{"description": "Bad named entity: zwj without a semi-colon.",
-"input":"&zwj",
-"output": ["ParseError", ["Character", "&zwj"]]},
-
-{"description": "Bad named entity: zwnj without a semi-colon.",
-"input":"&zwnj",
-"output": ["ParseError", ["Character", "&zwnj"]]},
-
-{"description": "Bad named entity: zwnj without a semi-colon.",
-"input":"&zwnj",
-"output": ["ParseError", ["Character", "&zwnj"]]},
-
-{"description": "CR as numeric entity",
-"input":"
",
-"output": ["ParseError", ["Character", "\n"]]},
-
-{"description": "CR as hexadecimal numeric entity",
-"input":"
",
-"output": ["ParseError", ["Character", "\n"]]},
-
-{"description": "Windows-1252 EURO SIGN numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u20AC"]]},
-
-{"description": "Windows-1252 REPLACEMENT CHAR numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\uFFFD"]]},
-
-{"description": "Windows-1252 SINGLE LOW-9 QUOTATION MARK numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u201A"]]},
-
-{"description": "Windows-1252 LATIN SMALL LETTER F WITH HOOK numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u0192"]]},
-
-{"description": "Windows-1252 DOUBLE LOW-9 QUOTATION MARK numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u201E"]]},
-
-{"description": "Windows-1252 HORIZONTAL ELLIPSIS numeric entity.",
-"input":"
",
-"output": ["ParseError", ["Character", "\u2026"]]},
-
-{"description": "Windows-1252 DAGGER numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2020"]]},
-
-{"description": "Windows-1252 DOUBLE DAGGER numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2021"]]},
-
-{"description": "Windows-1252 MODIFIER LETTER CIRCUMFLEX ACCENT numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u02C6"]]},
-
-{"description": "Windows-1252 PER MILLE SIGN numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2030"]]},
-
-{"description": "Windows-1252 LATIN CAPITAL LETTER S WITH CARON numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u0160"]]},
-
-{"description": "Windows-1252 SINGLE LEFT-POINTING ANGLE QUOTATION MARK numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2039"]]},
-
-{"description": "Windows-1252 LATIN CAPITAL LIGATURE OE numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u0152"]]},
-
-{"description": "Windows-1252 REPLACEMENT CHAR numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\uFFFD"]]},
-
-{"description": "Windows-1252 LATIN CAPITAL LETTER Z WITH CARON numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u017D"]]},
-
-{"description": "Windows-1252 REPLACEMENT CHAR numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\uFFFD"]]},
-
-{"description": "Windows-1252 REPLACEMENT CHAR numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\uFFFD"]]},
-
-{"description": "Windows-1252 LEFT SINGLE QUOTATION MARK numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2018"]]},
-
-{"description": "Windows-1252 RIGHT SINGLE QUOTATION MARK numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2019"]]},
-
-{"description": "Windows-1252 LEFT DOUBLE QUOTATION MARK numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u201C"]]},
-
-{"description": "Windows-1252 RIGHT DOUBLE QUOTATION MARK numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u201D"]]},
-
-{"description": "Windows-1252 BULLET numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2022"]]},
-
-{"description": "Windows-1252 EN DASH numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2013"]]},
-
-{"description": "Windows-1252 EM DASH numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2014"]]},
-
-{"description": "Windows-1252 SMALL TILDE numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u02DC"]]},
-
-{"description": "Windows-1252 TRADE MARK SIGN numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2122"]]},
-
-{"description": "Windows-1252 LATIN SMALL LETTER S WITH CARON numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u0161"]]},
-
-{"description": "Windows-1252 SINGLE RIGHT-POINTING ANGLE QUOTATION MARK numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u203A"]]},
-
-{"description": "Windows-1252 LATIN SMALL LIGATURE OE numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u0153"]]},
-
-{"description": "Windows-1252 REPLACEMENT CHAR numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\uFFFD"]]},
-
-{"description": "Windows-1252 EURO SIGN hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u20AC"]]},
-
-{"description": "Windows-1252 REPLACEMENT CHAR hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\uFFFD"]]},
-
-{"description": "Windows-1252 SINGLE LOW-9 QUOTATION MARK hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u201A"]]},
-
-{"description": "Windows-1252 LATIN SMALL LETTER F WITH HOOK hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u0192"]]},
-
-{"description": "Windows-1252 DOUBLE LOW-9 QUOTATION MARK hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u201E"]]},
-
-{"description": "Windows-1252 HORIZONTAL ELLIPSIS hexadecimal numeric entity.",
-"input":"
",
-"output": ["ParseError", ["Character", "\u2026"]]},
-
-{"description": "Windows-1252 DAGGER hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2020"]]},
-
-{"description": "Windows-1252 DOUBLE DAGGER hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2021"]]},
-
-{"description": "Windows-1252 MODIFIER LETTER CIRCUMFLEX ACCENT hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u02C6"]]},
-
-{"description": "Windows-1252 PER MILLE SIGN hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2030"]]},
-
-{"description": "Windows-1252 LATIN CAPITAL LETTER S WITH CARON hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u0160"]]},
-
-{"description": "Windows-1252 SINGLE LEFT-POINTING ANGLE QUOTATION MARK hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2039"]]},
-
-{"description": "Windows-1252 LATIN CAPITAL LIGATURE OE hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u0152"]]},
-
-{"description": "Windows-1252 REPLACEMENT CHAR hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\uFFFD"]]},
-
-{"description": "Windows-1252 LATIN CAPITAL LETTER Z WITH CARON hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u017D"]]},
-
-{"description": "Windows-1252 REPLACEMENT CHAR hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\uFFFD"]]},
-
-{"description": "Windows-1252 REPLACEMENT CHAR hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\uFFFD"]]},
-
-{"description": "Windows-1252 LEFT SINGLE QUOTATION MARK hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2018"]]},
-
-{"description": "Windows-1252 RIGHT SINGLE QUOTATION MARK hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2019"]]},
-
-{"description": "Windows-1252 LEFT DOUBLE QUOTATION MARK hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u201C"]]},
-
-{"description": "Windows-1252 RIGHT DOUBLE QUOTATION MARK hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u201D"]]},
-
-{"description": "Windows-1252 BULLET hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2022"]]},
-
-{"description": "Windows-1252 EN DASH hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2013"]]},
-
-{"description": "Windows-1252 EM DASH hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2014"]]},
-
-{"description": "Windows-1252 SMALL TILDE hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u02DC"]]},
-
-{"description": "Windows-1252 TRADE MARK SIGN hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u2122"]]},
-
-{"description": "Windows-1252 LATIN SMALL LETTER S WITH CARON hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u0161"]]},
-
-{"description": "Windows-1252 SINGLE RIGHT-POINTING ANGLE QUOTATION MARK hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u203A"]]},
-
-{"description": "Windows-1252 LATIN SMALL LIGATURE OE hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u0153"]]},
-
-{"description": "Windows-1252 REPLACEMENT CHAR hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\uFFFD"]]},
-
-{"description": "Windows-1252 LATIN SMALL LETTER Z WITH CARON hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u017E"]]},
-
-{"description": "Windows-1252 LATIN CAPITAL LETTER Y WITH DIAERESIS hexadecimal numeric entity.",
-"input":"",
-"output": ["ParseError", ["Character", "\u0178"]]}
-
-]}
+{"tests": [
+
+{"description": "Undefined named entity in attribute value ending in semicolon and whose name starts with a known entity name.",
+"input":"",
+"output": ["ParseError", ["StartTag", "h", {"a": "¬i;"}]]},
+
+{"description": "Named entity: AElig with a semi-colon.",
+"input":"Æ",
+"output": [["Character", "\u00C6"]]},
+
+{"description": "Named entity: AElig without a semi-colon.",
+"input":"Æ",
+"output": ["ParseError", ["Character", "\u00C6"]]},
+
+{"description": "Named entity: AMP with a semi-colon.",
+"input":"&",
+"output": [["Character", "\u0026"]]},
+
+{"description": "Named entity: AMP without a semi-colon.",
+"input":"&",
+"output": ["ParseError", ["Character", "\u0026"]]},
+
+{"description": "Named entity: Aacute with a semi-colon.",
+"input":"Á",
+"output": [["Character", "\u00C1"]]},
+
+{"description": "Named entity: Aacute without a semi-colon.",
+"input":"Á",
+"output": ["ParseError", ["Character", "\u00C1"]]},
+
+{"description": "Named entity: Acirc with a semi-colon.",
+"input":"Â",
+"output": [["Character", "\u00C2"]]},
+
+{"description": "Named entity: Acirc without a semi-colon.",
+"input":"Â",
+"output": ["ParseError", ["Character", "\u00C2"]]},
+
+{"description": "Named entity: Agrave with a semi-colon.",
+"input":"À",
+"output": [["Character", "\u00C0"]]},
+
+{"description": "Named entity: Agrave without a semi-colon.",
+"input":"À",
+"output": ["ParseError", ["Character", "\u00C0"]]},
+
+{"description": "Named entity: Alpha with a semi-colon.",
+"input":"Α",
+"output": [["Character", "\u0391"]]},
+
+{"description": "Named entity: Aring with a semi-colon.",
+"input":"Å",
+"output": [["Character", "\u00C5"]]},
+
+{"description": "Named entity: Aring without a semi-colon.",
+"input":"Å",
+"output": ["ParseError", ["Character", "\u00C5"]]},
+
+{"description": "Named entity: Atilde with a semi-colon.",
+"input":"Ã",
+"output": [["Character", "\u00C3"]]},
+
+{"description": "Named entity: Atilde without a semi-colon.",
+"input":"Ã",
+"output": ["ParseError", ["Character", "\u00C3"]]},
+
+{"description": "Named entity: Auml with a semi-colon.",
+"input":"Ä",
+"output": [["Character", "\u00C4"]]},
+
+{"description": "Named entity: Auml without a semi-colon.",
+"input":"Ä",
+"output": ["ParseError", ["Character", "\u00C4"]]},
+
+{"description": "Named entity: Beta with a semi-colon.",
+"input":"Β",
+"output": [["Character", "\u0392"]]},
+
+{"description": "Named entity: COPY with a semi-colon.",
+"input":"©",
+"output": [["Character", "\u00A9"]]},
+
+{"description": "Named entity: COPY without a semi-colon.",
+"input":"©",
+"output": ["ParseError", ["Character", "\u00A9"]]},
+
+{"description": "Named entity: Ccedil with a semi-colon.",
+"input":"Ç",
+"output": [["Character", "\u00C7"]]},
+
+{"description": "Named entity: Ccedil without a semi-colon.",
+"input":"Ç",
+"output": ["ParseError", ["Character", "\u00C7"]]},
+
+{"description": "Named entity: Chi with a semi-colon.",
+"input":"Χ",
+"output": [["Character", "\u03A7"]]},
+
+{"description": "Named entity: Dagger with a semi-colon.",
+"input":"‡",
+"output": [["Character", "\u2021"]]},
+
+{"description": "Named entity: Delta with a semi-colon.",
+"input":"Δ",
+"output": [["Character", "\u0394"]]},
+
+{"description": "Named entity: ETH with a semi-colon.",
+"input":"Ð",
+"output": [["Character", "\u00D0"]]},
+
+{"description": "Named entity: ETH without a semi-colon.",
+"input":"Ð",
+"output": ["ParseError", ["Character", "\u00D0"]]},
+
+{"description": "Named entity: Eacute with a semi-colon.",
+"input":"É",
+"output": [["Character", "\u00C9"]]},
+
+{"description": "Named entity: Eacute without a semi-colon.",
+"input":"É",
+"output": ["ParseError", ["Character", "\u00C9"]]},
+
+{"description": "Named entity: Ecirc with a semi-colon.",
+"input":"Ê",
+"output": [["Character", "\u00CA"]]},
+
+{"description": "Named entity: Ecirc without a semi-colon.",
+"input":"Ê",
+"output": ["ParseError", ["Character", "\u00CA"]]},
+
+{"description": "Named entity: Egrave with a semi-colon.",
+"input":"È",
+"output": [["Character", "\u00C8"]]},
+
+{"description": "Named entity: Egrave without a semi-colon.",
+"input":"È",
+"output": ["ParseError", ["Character", "\u00C8"]]},
+
+{"description": "Named entity: Epsilon with a semi-colon.",
+"input":"Ε",
+"output": [["Character", "\u0395"]]},
+
+{"description": "Named entity: Eta with a semi-colon.",
+"input":"Η",
+"output": [["Character", "\u0397"]]},
+
+{"description": "Named entity: Euml with a semi-colon.",
+"input":"Ë",
+"output": [["Character", "\u00CB"]]},
+
+{"description": "Named entity: Euml without a semi-colon.",
+"input":"Ë",
+"output": ["ParseError", ["Character", "\u00CB"]]},
+
+{"description": "Named entity: GT with a semi-colon.",
+"input":">",
+"output": [["Character", "\u003E"]]},
+
+{"description": "Named entity: GT without a semi-colon.",
+"input":">",
+"output": ["ParseError", ["Character", "\u003E"]]},
+
+{"description": "Named entity: Gamma with a semi-colon.",
+"input":"Γ",
+"output": [["Character", "\u0393"]]},
+
+{"description": "Named entity: Iacute with a semi-colon.",
+"input":"Í",
+"output": [["Character", "\u00CD"]]},
+
+{"description": "Named entity: Iacute without a semi-colon.",
+"input":"Í",
+"output": ["ParseError", ["Character", "\u00CD"]]},
+
+{"description": "Named entity: Icirc with a semi-colon.",
+"input":"Î",
+"output": [["Character", "\u00CE"]]},
+
+{"description": "Named entity: Icirc without a semi-colon.",
+"input":"Î",
+"output": ["ParseError", ["Character", "\u00CE"]]},
+
+{"description": "Named entity: Igrave with a semi-colon.",
+"input":"Ì",
+"output": [["Character", "\u00CC"]]},
+
+{"description": "Named entity: Igrave without a semi-colon.",
+"input":"Ì",
+"output": ["ParseError", ["Character", "\u00CC"]]},
+
+{"description": "Named entity: Iota with a semi-colon.",
+"input":"Ι",
+"output": [["Character", "\u0399"]]},
+
+{"description": "Named entity: Iuml with a semi-colon.",
+"input":"Ï",
+"output": [["Character", "\u00CF"]]},
+
+{"description": "Named entity: Iuml without a semi-colon.",
+"input":"Ï",
+"output": ["ParseError", ["Character", "\u00CF"]]},
+
+{"description": "Named entity: Kappa with a semi-colon.",
+"input":"Κ",
+"output": [["Character", "\u039A"]]},
+
+{"description": "Named entity: LT with a semi-colon.",
+"input":"<",
+"output": [["Character", "\u003C"]]},
+
+{"description": "Named entity: LT without a semi-colon.",
+"input":"<",
+"output": ["ParseError", ["Character", "\u003C"]]},
+
+{"description": "Named entity: Lambda with a semi-colon.",
+"input":"Λ",
+"output": [["Character", "\u039B"]]},
+
+{"description": "Named entity: Mu with a semi-colon.",
+"input":"Μ",
+"output": [["Character", "\u039C"]]},
+
+{"description": "Named entity: Ntilde with a semi-colon.",
+"input":"Ñ",
+"output": [["Character", "\u00D1"]]},
+
+{"description": "Named entity: Ntilde without a semi-colon.",
+"input":"Ñ",
+"output": ["ParseError", ["Character", "\u00D1"]]},
+
+{"description": "Named entity: Nu with a semi-colon.",
+"input":"Ν",
+"output": [["Character", "\u039D"]]},
+
+{"description": "Named entity: OElig with a semi-colon.",
+"input":"Œ",
+"output": [["Character", "\u0152"]]},
+
+{"description": "Named entity: Oacute with a semi-colon.",
+"input":"Ó",
+"output": [["Character", "\u00D3"]]},
+
+{"description": "Named entity: Oacute without a semi-colon.",
+"input":"Ó",
+"output": ["ParseError", ["Character", "\u00D3"]]},
+
+{"description": "Named entity: Ocirc with a semi-colon.",
+"input":"Ô",
+"output": [["Character", "\u00D4"]]},
+
+{"description": "Named entity: Ocirc without a semi-colon.",
+"input":"Ô",
+"output": ["ParseError", ["Character", "\u00D4"]]},
+
+{"description": "Named entity: Ograve with a semi-colon.",
+"input":"Ò",
+"output": [["Character", "\u00D2"]]},
+
+{"description": "Named entity: Ograve without a semi-colon.",
+"input":"Ò",
+"output": ["ParseError", ["Character", "\u00D2"]]},
+
+{"description": "Named entity: Omega with a semi-colon.",
+"input":"Ω",
+"output": [["Character", "\u03A9"]]},
+
+{"description": "Named entity: Omicron with a semi-colon.",
+"input":"Ο",
+"output": [["Character", "\u039F"]]},
+
+{"description": "Named entity: Oslash with a semi-colon.",
+"input":"Ø",
+"output": [["Character", "\u00D8"]]},
+
+{"description": "Named entity: Oslash without a semi-colon.",
+"input":"Ø",
+"output": ["ParseError", ["Character", "\u00D8"]]},
+
+{"description": "Named entity: Otilde with a semi-colon.",
+"input":"Õ",
+"output": [["Character", "\u00D5"]]},
+
+{"description": "Named entity: Otilde without a semi-colon.",
+"input":"Õ",
+"output": ["ParseError", ["Character", "\u00D5"]]},
+
+{"description": "Named entity: Ouml with a semi-colon.",
+"input":"Ö",
+"output": [["Character", "\u00D6"]]},
+
+{"description": "Named entity: Ouml without a semi-colon.",
+"input":"Ö",
+"output": ["ParseError", ["Character", "\u00D6"]]},
+
+{"description": "Named entity: Phi with a semi-colon.",
+"input":"Φ",
+"output": [["Character", "\u03A6"]]},
+
+{"description": "Named entity: Pi with a semi-colon.",
+"input":"Π",
+"output": [["Character", "\u03A0"]]},
+
+{"description": "Named entity: Prime with a semi-colon.",
+"input":"″",
+"output": [["Character", "\u2033"]]},
+
+{"description": "Named entity: Psi with a semi-colon.",
+"input":"Ψ",
+"output": [["Character", "\u03A8"]]},
+
+{"description": "Named entity: QUOT with a semi-colon.",
+"input":""",
+"output": [["Character", "\u0022"]]},
+
+{"description": "Named entity: QUOT without a semi-colon.",
+"input":""",
+"output": ["ParseError", ["Character", "\u0022"]]},
+
+{"description": "Named entity: REG with a semi-colon.",
+"input":"®",
+"output": [["Character", "\u00AE"]]},
+
+{"description": "Named entity: REG without a semi-colon.",
+"input":"®",
+"output": ["ParseError", ["Character", "\u00AE"]]},
+
+{"description": "Named entity: Rho with a semi-colon.",
+"input":"Ρ",
+"output": [["Character", "\u03A1"]]},
+
+{"description": "Named entity: Scaron with a semi-colon.",
+"input":"Š",
+"output": [["Character", "\u0160"]]},
+
+{"description": "Named entity: Sigma with a semi-colon.",
+"input":"Σ",
+"output": [["Character", "\u03A3"]]},
+
+{"description": "Named entity: THORN with a semi-colon.",
+"input":"Þ",
+"output": [["Character", "\u00DE"]]},
+
+{"description": "Named entity: THORN without a semi-colon.",
+"input":"Þ",
+"output": ["ParseError", ["Character", "\u00DE"]]},
+
+{"description": "Named entity: TRADE with a semi-colon.",
+"input":"™",
+"output": [["Character", "\u2122"]]},
+
+{"description": "Named entity: Tau with a semi-colon.",
+"input":"Τ",
+"output": [["Character", "\u03A4"]]},
+
+{"description": "Named entity: Theta with a semi-colon.",
+"input":"Θ",
+"output": [["Character", "\u0398"]]},
+
+{"description": "Named entity: Uacute with a semi-colon.",
+"input":"Ú",
+"output": [["Character", "\u00DA"]]},
+
+{"description": "Named entity: Uacute without a semi-colon.",
+"input":"Ú",
+"output": ["ParseError", ["Character", "\u00DA"]]},
+
+{"description": "Named entity: Ucirc with a semi-colon.",
+"input":"Û",
+"output": [["Character", "\u00DB"]]},
+
+{"description": "Named entity: Ucirc without a semi-colon.",
+"input":"Û",
+"output": ["ParseError", ["Character", "\u00DB"]]},
+
+{"description": "Named entity: Ugrave with a semi-colon.",
+"input":"Ù",
+"output": [["Character", "\u00D9"]]},
+
+{"description": "Named entity: Ugrave without a semi-colon.",
+"input":"Ù",
+"output": ["ParseError", ["Character", "\u00D9"]]},
+
+{"description": "Named entity: Upsilon with a semi-colon.",
+"input":"Υ",
+"output": [["Character", "\u03A5"]]},
+
+{"description": "Named entity: Uuml with a semi-colon.",
+"input":"Ü",
+"output": [["Character", "\u00DC"]]},
+
+{"description": "Named entity: Uuml without a semi-colon.",
+"input":"Ü",
+"output": ["ParseError", ["Character", "\u00DC"]]},
+
+{"description": "Named entity: Xi with a semi-colon.",
+"input":"Ξ",
+"output": [["Character", "\u039E"]]},
+
+{"description": "Named entity: Yacute with a semi-colon.",
+"input":"Ý",
+"output": [["Character", "\u00DD"]]},
+
+{"description": "Named entity: Yacute without a semi-colon.",
+"input":"Ý",
+"output": ["ParseError", ["Character", "\u00DD"]]},
+
+{"description": "Named entity: Yuml with a semi-colon.",
+"input":"Ÿ",
+"output": [["Character", "\u0178"]]},
+
+{"description": "Named entity: Zeta with a semi-colon.",
+"input":"Ζ",
+"output": [["Character", "\u0396"]]},
+
+{"description": "Named entity: aacute with a semi-colon.",
+"input":"á",
+"output": [["Character", "\u00E1"]]},
+
+{"description": "Named entity: aacute without a semi-colon.",
+"input":"á",
+"output": ["ParseError", ["Character", "\u00E1"]]},
+
+{"description": "Named entity: acirc with a semi-colon.",
+"input":"â",
+"output": [["Character", "\u00E2"]]},
+
+{"description": "Named entity: acirc without a semi-colon.",
+"input":"â",
+"output": ["ParseError", ["Character", "\u00E2"]]},
+
+{"description": "Named entity: acute with a semi-colon.",
+"input":"´",
+"output": [["Character", "\u00B4"]]},
+
+{"description": "Named entity: acute without a semi-colon.",
+"input":"´",
+"output": ["ParseError", ["Character", "\u00B4"]]},
+
+{"description": "Named entity: aelig with a semi-colon.",
+"input":"æ",
+"output": [["Character", "\u00E6"]]},
+
+{"description": "Named entity: aelig without a semi-colon.",
+"input":"æ",
+"output": ["ParseError", ["Character", "\u00E6"]]},
+
+{"description": "Named entity: agrave with a semi-colon.",
+"input":"à",
+"output": [["Character", "\u00E0"]]},
+
+{"description": "Named entity: agrave without a semi-colon.",
+"input":"à",
+"output": ["ParseError", ["Character", "\u00E0"]]},
+
+{"description": "Named entity: alefsym with a semi-colon.",
+"input":"ℵ",
+"output": [["Character", "\u2135"]]},
+
+{"description": "Named entity: alpha with a semi-colon.",
+"input":"α",
+"output": [["Character", "\u03B1"]]},
+
+{"description": "Named entity: amp with a semi-colon.",
+"input":"&",
+"output": [["Character", "\u0026"]]},
+
+{"description": "Named entity: amp without a semi-colon.",
+"input":"&",
+"output": ["ParseError", ["Character", "\u0026"]]},
+
+{"description": "Named entity: and with a semi-colon.",
+"input":"∧",
+"output": [["Character", "\u2227"]]},
+
+{"description": "Named entity: ang with a semi-colon.",
+"input":"∠",
+"output": [["Character", "\u2220"]]},
+
+{"description": "Named entity: apos with a semi-colon.",
+"input":"'",
+"output": [["Character", "\u0027"]]},
+
+{"description": "Named entity: aring with a semi-colon.",
+"input":"å",
+"output": [["Character", "\u00E5"]]},
+
+{"description": "Named entity: aring without a semi-colon.",
+"input":"å",
+"output": ["ParseError", ["Character", "\u00E5"]]},
+
+{"description": "Named entity: asymp with a semi-colon.",
+"input":"≈",
+"output": [["Character", "\u2248"]]},
+
+{"description": "Named entity: atilde with a semi-colon.",
+"input":"ã",
+"output": [["Character", "\u00E3"]]},
+
+{"description": "Named entity: atilde without a semi-colon.",
+"input":"ã",
+"output": ["ParseError", ["Character", "\u00E3"]]},
+
+{"description": "Named entity: auml with a semi-colon.",
+"input":"ä",
+"output": [["Character", "\u00E4"]]},
+
+{"description": "Named entity: auml without a semi-colon.",
+"input":"ä",
+"output": ["ParseError", ["Character", "\u00E4"]]},
+
+{"description": "Named entity: bdquo with a semi-colon.",
+"input":"„",
+"output": [["Character", "\u201E"]]},
+
+{"description": "Named entity: beta with a semi-colon.",
+"input":"β",
+"output": [["Character", "\u03B2"]]},
+
+{"description": "Named entity: brvbar with a semi-colon.",
+"input":"¦",
+"output": [["Character", "\u00A6"]]},
+
+{"description": "Named entity: brvbar without a semi-colon.",
+"input":"¦",
+"output": ["ParseError", ["Character", "\u00A6"]]},
+
+{"description": "Named entity: bull with a semi-colon.",
+"input":"•",
+"output": [["Character", "\u2022"]]},
+
+{"description": "Named entity: cap with a semi-colon.",
+"input":"∩",
+"output": [["Character", "\u2229"]]},
+
+{"description": "Named entity: ccedil with a semi-colon.",
+"input":"ç",
+"output": [["Character", "\u00E7"]]},
+
+{"description": "Named entity: ccedil without a semi-colon.",
+"input":"ç",
+"output": ["ParseError", ["Character", "\u00E7"]]},
+
+{"description": "Named entity: cedil with a semi-colon.",
+"input":"¸",
+"output": [["Character", "\u00B8"]]},
+
+{"description": "Named entity: cedil without a semi-colon.",
+"input":"¸",
+"output": ["ParseError", ["Character", "\u00B8"]]},
+
+{"description": "Named entity: cent with a semi-colon.",
+"input":"¢",
+"output": [["Character", "\u00A2"]]},
+
+{"description": "Named entity: cent without a semi-colon.",
+"input":"¢",
+"output": ["ParseError", ["Character", "\u00A2"]]},
+
+{"description": "Named entity: chi with a semi-colon.",
+"input":"χ",
+"output": [["Character", "\u03C7"]]},
+
+{"description": "Named entity: circ with a semi-colon.",
+"input":"ˆ",
+"output": [["Character", "\u02C6"]]},
+
+{"description": "Named entity: clubs with a semi-colon.",
+"input":"♣",
+"output": [["Character", "\u2663"]]},
+
+{"description": "Named entity: cong with a semi-colon.",
+"input":"≅",
+"output": [["Character", "\u2245"]]},
+
+{"description": "Named entity: copy with a semi-colon.",
+"input":"©",
+"output": [["Character", "\u00A9"]]},
+
+{"description": "Named entity: copy without a semi-colon.",
+"input":"©",
+"output": ["ParseError", ["Character", "\u00A9"]]},
+
+{"description": "Named entity: crarr with a semi-colon.",
+"input":"↵",
+"output": [["Character", "\u21B5"]]},
+
+{"description": "Named entity: cup with a semi-colon.",
+"input":"∪",
+"output": [["Character", "\u222A"]]},
+
+{"description": "Named entity: curren with a semi-colon.",
+"input":"¤",
+"output": [["Character", "\u00A4"]]},
+
+{"description": "Named entity: curren without a semi-colon.",
+"input":"¤",
+"output": ["ParseError", ["Character", "\u00A4"]]},
+
+{"description": "Named entity: dArr with a semi-colon.",
+"input":"⇓",
+"output": [["Character", "\u21D3"]]},
+
+{"description": "Named entity: dagger with a semi-colon.",
+"input":"†",
+"output": [["Character", "\u2020"]]},
+
+{"description": "Named entity: darr with a semi-colon.",
+"input":"↓",
+"output": [["Character", "\u2193"]]},
+
+{"description": "Named entity: deg with a semi-colon.",
+"input":"°",
+"output": [["Character", "\u00B0"]]},
+
+{"description": "Named entity: deg without a semi-colon.",
+"input":"°",
+"output": ["ParseError", ["Character", "\u00B0"]]},
+
+{"description": "Named entity: delta with a semi-colon.",
+"input":"δ",
+"output": [["Character", "\u03B4"]]},
+
+{"description": "Named entity: diams with a semi-colon.",
+"input":"♦",
+"output": [["Character", "\u2666"]]},
+
+{"description": "Named entity: divide with a semi-colon.",
+"input":"÷",
+"output": [["Character", "\u00F7"]]},
+
+{"description": "Named entity: divide without a semi-colon.",
+"input":"÷",
+"output": ["ParseError", ["Character", "\u00F7"]]},
+
+{"description": "Named entity: eacute with a semi-colon.",
+"input":"é",
+"output": [["Character", "\u00E9"]]},
+
+{"description": "Named entity: eacute without a semi-colon.",
+"input":"é",
+"output": ["ParseError", ["Character", "\u00E9"]]},
+
+{"description": "Named entity: ecirc with a semi-colon.",
+"input":"ê",
+"output": [["Character", "\u00EA"]]},
+
+{"description": "Named entity: ecirc without a semi-colon.",
+"input":"ê",
+"output": ["ParseError", ["Character", "\u00EA"]]},
+
+{"description": "Named entity: egrave with a semi-colon.",
+"input":"è",
+"output": [["Character", "\u00E8"]]},
+
+{"description": "Named entity: egrave without a semi-colon.",
+"input":"è",
+"output": ["ParseError", ["Character", "\u00E8"]]},
+
+{"description": "Named entity: empty with a semi-colon.",
+"input":"∅",
+"output": [["Character", "\u2205"]]},
+
+{"description": "Named entity: emsp with a semi-colon.",
+"input":" ",
+"output": [["Character", "\u2003"]]},
+
+{"description": "Named entity: ensp with a semi-colon.",
+"input":" ",
+"output": [["Character", "\u2002"]]},
+
+{"description": "Named entity: epsilon with a semi-colon.",
+"input":"ε",
+"output": [["Character", "\u03B5"]]},
+
+{"description": "Named entity: equiv with a semi-colon.",
+"input":"≡",
+"output": [["Character", "\u2261"]]},
+
+{"description": "Named entity: eta with a semi-colon.",
+"input":"η",
+"output": [["Character", "\u03B7"]]},
+
+{"description": "Named entity: eth with a semi-colon.",
+"input":"ð",
+"output": [["Character", "\u00F0"]]},
+
+{"description": "Named entity: eth without a semi-colon.",
+"input":"ð",
+"output": ["ParseError", ["Character", "\u00F0"]]},
+
+{"description": "Named entity: euml with a semi-colon.",
+"input":"ë",
+"output": [["Character", "\u00EB"]]},
+
+{"description": "Named entity: euml without a semi-colon.",
+"input":"ë",
+"output": ["ParseError", ["Character", "\u00EB"]]},
+
+{"description": "Named entity: euro with a semi-colon.",
+"input":"€",
+"output": [["Character", "\u20AC"]]},
+
+{"description": "Named entity: exist with a semi-colon.",
+"input":"∃",
+"output": [["Character", "\u2203"]]},
+
+{"description": "Named entity: fnof with a semi-colon.",
+"input":"ƒ",
+"output": [["Character", "\u0192"]]},
+
+{"description": "Named entity: forall with a semi-colon.",
+"input":"∀",
+"output": [["Character", "\u2200"]]},
+
+{"description": "Named entity: frac12 with a semi-colon.",
+"input":"½",
+"output": [["Character", "\u00BD"]]},
+
+{"description": "Named entity: frac12 without a semi-colon.",
+"input":"½",
+"output": ["ParseError", ["Character", "\u00BD"]]},
+
+{"description": "Named entity: frac14 with a semi-colon.",
+"input":"¼",
+"output": [["Character", "\u00BC"]]},
+
+{"description": "Named entity: frac14 without a semi-colon.",
+"input":"¼",
+"output": ["ParseError", ["Character", "\u00BC"]]},
+
+{"description": "Named entity: frac34 with a semi-colon.",
+"input":"¾",
+"output": [["Character", "\u00BE"]]},
+
+{"description": "Named entity: frac34 without a semi-colon.",
+"input":"¾",
+"output": ["ParseError", ["Character", "\u00BE"]]},
+
+{"description": "Named entity: frasl with a semi-colon.",
+"input":"⁄",
+"output": [["Character", "\u2044"]]},
+
+{"description": "Named entity: gamma with a semi-colon.",
+"input":"γ",
+"output": [["Character", "\u03B3"]]},
+
+{"description": "Named entity: ge with a semi-colon.",
+"input":"≥",
+"output": [["Character", "\u2265"]]},
+
+{"description": "Named entity: gt with a semi-colon.",
+"input":">",
+"output": [["Character", "\u003E"]]},
+
+{"description": "Named entity: gt without a semi-colon.",
+"input":">",
+"output": ["ParseError", ["Character", "\u003E"]]},
+
+{"description": "Named entity: hArr with a semi-colon.",
+"input":"⇔",
+"output": [["Character", "\u21D4"]]},
+
+{"description": "Named entity: harr with a semi-colon.",
+"input":"↔",
+"output": [["Character", "\u2194"]]},
+
+{"description": "Named entity: hearts with a semi-colon.",
+"input":"♥",
+"output": [["Character", "\u2665"]]},
+
+{"description": "Named entity: hellip with a semi-colon.",
+"input":"…",
+"output": [["Character", "\u2026"]]},
+
+{"description": "Named entity: iacute with a semi-colon.",
+"input":"í",
+"output": [["Character", "\u00ED"]]},
+
+{"description": "Named entity: iacute without a semi-colon.",
+"input":"í",
+"output": ["ParseError", ["Character", "\u00ED"]]},
+
+{"description": "Named entity: icirc with a semi-colon.",
+"input":"î",
+"output": [["Character", "\u00EE"]]},
+
+{"description": "Named entity: icirc without a semi-colon.",
+"input":"î",
+"output": ["ParseError", ["Character", "\u00EE"]]},
+
+{"description": "Named entity: iexcl with a semi-colon.",
+"input":"¡",
+"output": [["Character", "\u00A1"]]},
+
+{"description": "Named entity: iexcl without a semi-colon.",
+"input":"¡",
+"output": ["ParseError", ["Character", "\u00A1"]]},
+
+{"description": "Named entity: igrave with a semi-colon.",
+"input":"ì",
+"output": [["Character", "\u00EC"]]},
+
+{"description": "Named entity: igrave without a semi-colon.",
+"input":"ì",
+"output": ["ParseError", ["Character", "\u00EC"]]},
+
+{"description": "Named entity: image with a semi-colon.",
+"input":"ℑ",
+"output": [["Character", "\u2111"]]},
+
+{"description": "Named entity: infin with a semi-colon.",
+"input":"∞",
+"output": [["Character", "\u221E"]]},
+
+{"description": "Named entity: int with a semi-colon.",
+"input":"∫",
+"output": [["Character", "\u222B"]]},
+
+{"description": "Named entity: iota with a semi-colon.",
+"input":"ι",
+"output": [["Character", "\u03B9"]]},
+
+{"description": "Named entity: iquest with a semi-colon.",
+"input":"¿",
+"output": [["Character", "\u00BF"]]},
+
+{"description": "Named entity: iquest without a semi-colon.",
+"input":"¿",
+"output": ["ParseError", ["Character", "\u00BF"]]},
+
+{"description": "Named entity: isin with a semi-colon.",
+"input":"∈",
+"output": [["Character", "\u2208"]]},
+
+{"description": "Named entity: iuml with a semi-colon.",
+"input":"ï",
+"output": [["Character", "\u00EF"]]},
+
+{"description": "Named entity: iuml without a semi-colon.",
+"input":"ï",
+"output": ["ParseError", ["Character", "\u00EF"]]},
+
+{"description": "Named entity: kappa with a semi-colon.",
+"input":"κ",
+"output": [["Character", "\u03BA"]]},
+
+{"description": "Named entity: lArr with a semi-colon.",
+"input":"⇐",
+"output": [["Character", "\u21D0"]]},
+
+{"description": "Named entity: lambda with a semi-colon.",
+"input":"λ",
+"output": [["Character", "\u03BB"]]},
+
+{"description": "Named entity: lang with a semi-colon.",
+"input":"〈",
+"output": [["Character", "\u3008"]]},
+
+{"description": "Named entity: laquo with a semi-colon.",
+"input":"«",
+"output": [["Character", "\u00AB"]]},
+
+{"description": "Named entity: laquo without a semi-colon.",
+"input":"«",
+"output": ["ParseError", ["Character", "\u00AB"]]},
+
+{"description": "Named entity: larr with a semi-colon.",
+"input":"←",
+"output": [["Character", "\u2190"]]},
+
+{"description": "Named entity: lceil with a semi-colon.",
+"input":"⌈",
+"output": [["Character", "\u2308"]]},
+
+{"description": "Named entity: ldquo with a semi-colon.",
+"input":"“",
+"output": [["Character", "\u201C"]]},
+
+{"description": "Named entity: le with a semi-colon.",
+"input":"≤",
+"output": [["Character", "\u2264"]]},
+
+{"description": "Named entity: lfloor with a semi-colon.",
+"input":"⌊",
+"output": [["Character", "\u230A"]]},
+
+{"description": "Named entity: lowast with a semi-colon.",
+"input":"∗",
+"output": [["Character", "\u2217"]]},
+
+{"description": "Named entity: loz with a semi-colon.",
+"input":"◊",
+"output": [["Character", "\u25CA"]]},
+
+{"description": "Named entity: lrm with a semi-colon.",
+"input":"",
+"output": [["Character", "\u200E"]]},
+
+{"description": "Named entity: lsaquo with a semi-colon.",
+"input":"‹",
+"output": [["Character", "\u2039"]]},
+
+{"description": "Named entity: lsquo with a semi-colon.",
+"input":"‘",
+"output": [["Character", "\u2018"]]},
+
+{"description": "Named entity: lt with a semi-colon.",
+"input":"<",
+"output": [["Character", "\u003C"]]},
+
+{"description": "Named entity: lt without a semi-colon.",
+"input":"<",
+"output": ["ParseError", ["Character", "\u003C"]]},
+
+{"description": "Named entity: macr with a semi-colon.",
+"input":"¯",
+"output": [["Character", "\u00AF"]]},
+
+{"description": "Named entity: macr without a semi-colon.",
+"input":"¯",
+"output": ["ParseError", ["Character", "\u00AF"]]},
+
+{"description": "Named entity: mdash with a semi-colon.",
+"input":"—",
+"output": [["Character", "\u2014"]]},
+
+{"description": "Named entity: micro with a semi-colon.",
+"input":"µ",
+"output": [["Character", "\u00B5"]]},
+
+{"description": "Named entity: micro without a semi-colon.",
+"input":"µ",
+"output": ["ParseError", ["Character", "\u00B5"]]},
+
+{"description": "Named entity: middot with a semi-colon.",
+"input":"·",
+"output": [["Character", "\u00B7"]]},
+
+{"description": "Named entity: middot without a semi-colon.",
+"input":"·",
+"output": ["ParseError", ["Character", "\u00B7"]]},
+
+{"description": "Named entity: minus with a semi-colon.",
+"input":"−",
+"output": [["Character", "\u2212"]]},
+
+{"description": "Named entity: mu with a semi-colon.",
+"input":"μ",
+"output": [["Character", "\u03BC"]]},
+
+{"description": "Named entity: nabla with a semi-colon.",
+"input":"∇",
+"output": [["Character", "\u2207"]]},
+
+{"description": "Named entity: nbsp with a semi-colon.",
+"input":" ",
+"output": [["Character", "\u00A0"]]},
+
+{"description": "Named entity: nbsp without a semi-colon.",
+"input":" ",
+"output": ["ParseError", ["Character", "\u00A0"]]},
+
+{"description": "Named entity: ndash with a semi-colon.",
+"input":"–",
+"output": [["Character", "\u2013"]]},
+
+{"description": "Named entity: ne with a semi-colon.",
+"input":"≠",
+"output": [["Character", "\u2260"]]},
+
+{"description": "Named entity: ni with a semi-colon.",
+"input":"∋",
+"output": [["Character", "\u220B"]]},
+
+{"description": "Named entity: not with a semi-colon.",
+"input":"¬",
+"output": [["Character", "\u00AC"]]},
+
+{"description": "Named entity: not without a semi-colon.",
+"input":"¬",
+"output": ["ParseError", ["Character", "\u00AC"]]},
+
+{"description": "Named entity: notin with a semi-colon.",
+"input":"∉",
+"output": [["Character", "\u2209"]]},
+
+{"description": "Named entity: nsub with a semi-colon.",
+"input":"⊄",
+"output": [["Character", "\u2284"]]},
+
+{"description": "Named entity: ntilde with a semi-colon.",
+"input":"ñ",
+"output": [["Character", "\u00F1"]]},
+
+{"description": "Named entity: ntilde without a semi-colon.",
+"input":"ñ",
+"output": ["ParseError", ["Character", "\u00F1"]]},
+
+{"description": "Named entity: nu with a semi-colon.",
+"input":"ν",
+"output": [["Character", "\u03BD"]]},
+
+{"description": "Named entity: oacute with a semi-colon.",
+"input":"ó",
+"output": [["Character", "\u00F3"]]},
+
+{"description": "Named entity: oacute without a semi-colon.",
+"input":"ó",
+"output": ["ParseError", ["Character", "\u00F3"]]},
+
+{"description": "Named entity: ocirc with a semi-colon.",
+"input":"ô",
+"output": [["Character", "\u00F4"]]},
+
+{"description": "Named entity: ocirc without a semi-colon.",
+"input":"ô",
+"output": ["ParseError", ["Character", "\u00F4"]]},
+
+{"description": "Named entity: oelig with a semi-colon.",
+"input":"œ",
+"output": [["Character", "\u0153"]]},
+
+{"description": "Named entity: ograve with a semi-colon.",
+"input":"ò",
+"output": [["Character", "\u00F2"]]},
+
+{"description": "Named entity: ograve without a semi-colon.",
+"input":"ò",
+"output": ["ParseError", ["Character", "\u00F2"]]},
+
+{"description": "Named entity: oline with a semi-colon.",
+"input":"‾",
+"output": [["Character", "\u203E"]]},
+
+{"description": "Named entity: omega with a semi-colon.",
+"input":"ω",
+"output": [["Character", "\u03C9"]]},
+
+{"description": "Named entity: omicron with a semi-colon.",
+"input":"ο",
+"output": [["Character", "\u03BF"]]},
+
+{"description": "Named entity: oplus with a semi-colon.",
+"input":"⊕",
+"output": [["Character", "\u2295"]]},
+
+{"description": "Named entity: or with a semi-colon.",
+"input":"∨",
+"output": [["Character", "\u2228"]]},
+
+{"description": "Named entity: ordf with a semi-colon.",
+"input":"ª",
+"output": [["Character", "\u00AA"]]},
+
+{"description": "Named entity: ordf without a semi-colon.",
+"input":"ª",
+"output": ["ParseError", ["Character", "\u00AA"]]},
+
+{"description": "Named entity: ordm with a semi-colon.",
+"input":"º",
+"output": [["Character", "\u00BA"]]},
+
+{"description": "Named entity: ordm without a semi-colon.",
+"input":"º",
+"output": ["ParseError", ["Character", "\u00BA"]]},
+
+{"description": "Named entity: oslash with a semi-colon.",
+"input":"ø",
+"output": [["Character", "\u00F8"]]},
+
+{"description": "Named entity: oslash without a semi-colon.",
+"input":"ø",
+"output": ["ParseError", ["Character", "\u00F8"]]},
+
+{"description": "Named entity: otilde with a semi-colon.",
+"input":"õ",
+"output": [["Character", "\u00F5"]]},
+
+{"description": "Named entity: otilde without a semi-colon.",
+"input":"õ",
+"output": ["ParseError", ["Character", "\u00F5"]]},
+
+{"description": "Named entity: otimes with a semi-colon.",
+"input":"⊗",
+"output": [["Character", "\u2297"]]},
+
+{"description": "Named entity: ouml with a semi-colon.",
+"input":"ö",
+"output": [["Character", "\u00F6"]]},
+
+{"description": "Named entity: ouml without a semi-colon.",
+"input":"ö",
+"output": ["ParseError", ["Character", "\u00F6"]]},
+
+{"description": "Named entity: para with a semi-colon.",
+"input":"¶",
+"output": [["Character", "\u00B6"]]},
+
+{"description": "Named entity: para without a semi-colon.",
+"input":"¶",
+"output": ["ParseError", ["Character", "\u00B6"]]},
+
+{"description": "Named entity: part with a semi-colon.",
+"input":"∂",
+"output": [["Character", "\u2202"]]},
+
+{"description": "Named entity: permil with a semi-colon.",
+"input":"‰",
+"output": [["Character", "\u2030"]]},
+
+{"description": "Named entity: perp with a semi-colon.",
+"input":"⊥",
+"output": [["Character", "\u22A5"]]},
+
+{"description": "Named entity: phi with a semi-colon.",
+"input":"φ",
+"output": [["Character", "\u03C6"]]},
+
+{"description": "Named entity: pi with a semi-colon.",
+"input":"π",
+"output": [["Character", "\u03C0"]]},
+
+{"description": "Named entity: piv with a semi-colon.",
+"input":"ϖ",
+"output": [["Character", "\u03D6"]]},
+
+{"description": "Named entity: plusmn with a semi-colon.",
+"input":"±",
+"output": [["Character", "\u00B1"]]},
+
+{"description": "Named entity: plusmn without a semi-colon.",
+"input":"±",
+"output": ["ParseError", ["Character", "\u00B1"]]},
+
+{"description": "Named entity: pound with a semi-colon.",
+"input":"£",
+"output": [["Character", "\u00A3"]]},
+
+{"description": "Named entity: pound without a semi-colon.",
+"input":"£",
+"output": ["ParseError", ["Character", "\u00A3"]]},
+
+{"description": "Named entity: prime with a semi-colon.",
+"input":"′",
+"output": [["Character", "\u2032"]]},
+
+{"description": "Named entity: prod with a semi-colon.",
+"input":"∏",
+"output": [["Character", "\u220F"]]},
+
+{"description": "Named entity: prop with a semi-colon.",
+"input":"∝",
+"output": [["Character", "\u221D"]]},
+
+{"description": "Named entity: psi with a semi-colon.",
+"input":"ψ",
+"output": [["Character", "\u03C8"]]},
+
+{"description": "Named entity: quot with a semi-colon.",
+"input":""",
+"output": [["Character", "\u0022"]]},
+
+{"description": "Named entity: quot without a semi-colon.",
+"input":""",
+"output": ["ParseError", ["Character", "\u0022"]]},
+
+{"description": "Named entity: rArr with a semi-colon.",
+"input":"⇒",
+"output": [["Character", "\u21D2"]]},
+
+{"description": "Named entity: radic with a semi-colon.",
+"input":"√",
+"output": [["Character", "\u221A"]]},
+
+{"description": "Named entity: rang with a semi-colon.",
+"input":"〉",
+"output": [["Character", "\u3009"]]},
+
+{"description": "Named entity: raquo with a semi-colon.",
+"input":"»",
+"output": [["Character", "\u00BB"]]},
+
+{"description": "Named entity: raquo without a semi-colon.",
+"input":"»",
+"output": ["ParseError", ["Character", "\u00BB"]]},
+
+{"description": "Named entity: rarr with a semi-colon.",
+"input":"→",
+"output": [["Character", "\u2192"]]},
+
+{"description": "Named entity: rceil with a semi-colon.",
+"input":"⌉",
+"output": [["Character", "\u2309"]]},
+
+{"description": "Named entity: rdquo with a semi-colon.",
+"input":"”",
+"output": [["Character", "\u201D"]]},
+
+{"description": "Named entity: real with a semi-colon.",
+"input":"ℜ",
+"output": [["Character", "\u211C"]]},
+
+{"description": "Named entity: reg with a semi-colon.",
+"input":"®",
+"output": [["Character", "\u00AE"]]},
+
+{"description": "Named entity: reg without a semi-colon.",
+"input":"®",
+"output": ["ParseError", ["Character", "\u00AE"]]},
+
+{"description": "Named entity: rfloor with a semi-colon.",
+"input":"⌋",
+"output": [["Character", "\u230B"]]},
+
+{"description": "Named entity: rho with a semi-colon.",
+"input":"ρ",
+"output": [["Character", "\u03C1"]]},
+
+{"description": "Named entity: rlm with a semi-colon.",
+"input":"",
+"output": [["Character", "\u200F"]]},
+
+{"description": "Named entity: rsaquo with a semi-colon.",
+"input":"›",
+"output": [["Character", "\u203A"]]},
+
+{"description": "Named entity: rsquo with a semi-colon.",
+"input":"’",
+"output": [["Character", "\u2019"]]},
+
+{"description": "Named entity: sbquo with a semi-colon.",
+"input":"‚",
+"output": [["Character", "\u201A"]]},
+
+{"description": "Named entity: scaron with a semi-colon.",
+"input":"š",
+"output": [["Character", "\u0161"]]},
+
+{"description": "Named entity: sdot with a semi-colon.",
+"input":"⋅",
+"output": [["Character", "\u22C5"]]},
+
+{"description": "Named entity: sect with a semi-colon.",
+"input":"§",
+"output": [["Character", "\u00A7"]]},
+
+{"description": "Named entity: sect without a semi-colon.",
+"input":"§",
+"output": ["ParseError", ["Character", "\u00A7"]]},
+
+{"description": "Named entity: shy with a semi-colon.",
+"input":"",
+"output": [["Character", "\u00AD"]]},
+
+{"description": "Named entity: shy without a semi-colon.",
+"input":"­",
+"output": ["ParseError", ["Character", "\u00AD"]]},
+
+{"description": "Named entity: sigma with a semi-colon.",
+"input":"σ",
+"output": [["Character", "\u03C3"]]},
+
+{"description": "Named entity: sigmaf with a semi-colon.",
+"input":"ς",
+"output": [["Character", "\u03C2"]]},
+
+{"description": "Named entity: sim with a semi-colon.",
+"input":"∼",
+"output": [["Character", "\u223C"]]},
+
+{"description": "Named entity: spades with a semi-colon.",
+"input":"♠",
+"output": [["Character", "\u2660"]]},
+
+{"description": "Named entity: sub with a semi-colon.",
+"input":"⊂",
+"output": [["Character", "\u2282"]]},
+
+{"description": "Named entity: sube with a semi-colon.",
+"input":"⊆",
+"output": [["Character", "\u2286"]]},
+
+{"description": "Named entity: sum with a semi-colon.",
+"input":"∑",
+"output": [["Character", "\u2211"]]},
+
+{"description": "Named entity: sup1 with a semi-colon.",
+"input":"¹",
+"output": [["Character", "\u00B9"]]},
+
+{"description": "Named entity: sup1 without a semi-colon.",
+"input":"¹",
+"output": ["ParseError", ["Character", "\u00B9"]]},
+
+{"description": "Named entity: sup2 with a semi-colon.",
+"input":"²",
+"output": [["Character", "\u00B2"]]},
+
+{"description": "Named entity: sup2 without a semi-colon.",
+"input":"²",
+"output": ["ParseError", ["Character", "\u00B2"]]},
+
+{"description": "Named entity: sup3 with a semi-colon.",
+"input":"³",
+"output": [["Character", "\u00B3"]]},
+
+{"description": "Named entity: sup3 without a semi-colon.",
+"input":"³",
+"output": ["ParseError", ["Character", "\u00B3"]]},
+
+{"description": "Named entity: sup with a semi-colon.",
+"input":"⊃",
+"output": [["Character", "\u2283"]]},
+
+{"description": "Named entity: supe with a semi-colon.",
+"input":"⊇",
+"output": [["Character", "\u2287"]]},
+
+{"description": "Named entity: szlig with a semi-colon.",
+"input":"ß",
+"output": [["Character", "\u00DF"]]},
+
+{"description": "Named entity: szlig without a semi-colon.",
+"input":"ß",
+"output": ["ParseError", ["Character", "\u00DF"]]},
+
+{"description": "Named entity: tau with a semi-colon.",
+"input":"τ",
+"output": [["Character", "\u03C4"]]},
+
+{"description": "Named entity: there4 with a semi-colon.",
+"input":"∴",
+"output": [["Character", "\u2234"]]},
+
+{"description": "Named entity: theta with a semi-colon.",
+"input":"θ",
+"output": [["Character", "\u03B8"]]},
+
+{"description": "Named entity: thetasym with a semi-colon.",
+"input":"ϑ",
+"output": [["Character", "\u03D1"]]},
+
+{"description": "Named entity: thinsp with a semi-colon.",
+"input":" ",
+"output": [["Character", "\u2009"]]},
+
+{"description": "Named entity: thorn with a semi-colon.",
+"input":"þ",
+"output": [["Character", "\u00FE"]]},
+
+{"description": "Named entity: thorn without a semi-colon.",
+"input":"þ",
+"output": ["ParseError", ["Character", "\u00FE"]]},
+
+{"description": "Named entity: tilde with a semi-colon.",
+"input":"˜",
+"output": [["Character", "\u02DC"]]},
+
+{"description": "Named entity: times with a semi-colon.",
+"input":"×",
+"output": [["Character", "\u00D7"]]},
+
+{"description": "Named entity: times without a semi-colon.",
+"input":"×",
+"output": ["ParseError", ["Character", "\u00D7"]]},
+
+{"description": "Named entity: trade with a semi-colon.",
+"input":"™",
+"output": [["Character", "\u2122"]]},
+
+{"description": "Named entity: uArr with a semi-colon.",
+"input":"⇑",
+"output": [["Character", "\u21D1"]]},
+
+{"description": "Named entity: uacute with a semi-colon.",
+"input":"ú",
+"output": [["Character", "\u00FA"]]},
+
+{"description": "Named entity: uacute without a semi-colon.",
+"input":"ú",
+"output": ["ParseError", ["Character", "\u00FA"]]},
+
+{"description": "Named entity: uarr with a semi-colon.",
+"input":"↑",
+"output": [["Character", "\u2191"]]},
+
+{"description": "Named entity: ucirc with a semi-colon.",
+"input":"û",
+"output": [["Character", "\u00FB"]]},
+
+{"description": "Named entity: ucirc without a semi-colon.",
+"input":"û",
+"output": ["ParseError", ["Character", "\u00FB"]]},
+
+{"description": "Named entity: ugrave with a semi-colon.",
+"input":"ù",
+"output": [["Character", "\u00F9"]]},
+
+{"description": "Named entity: ugrave without a semi-colon.",
+"input":"ù",
+"output": ["ParseError", ["Character", "\u00F9"]]},
+
+{"description": "Named entity: uml with a semi-colon.",
+"input":"¨",
+"output": [["Character", "\u00A8"]]},
+
+{"description": "Named entity: uml without a semi-colon.",
+"input":"¨",
+"output": ["ParseError", ["Character", "\u00A8"]]},
+
+{"description": "Named entity: upsih with a semi-colon.",
+"input":"ϒ",
+"output": [["Character", "\u03D2"]]},
+
+{"description": "Named entity: upsilon with a semi-colon.",
+"input":"υ",
+"output": [["Character", "\u03C5"]]},
+
+{"description": "Named entity: uuml with a semi-colon.",
+"input":"ü",
+"output": [["Character", "\u00FC"]]},
+
+{"description": "Named entity: uuml without a semi-colon.",
+"input":"ü",
+"output": ["ParseError", ["Character", "\u00FC"]]},
+
+{"description": "Named entity: weierp with a semi-colon.",
+"input":"℘",
+"output": [["Character", "\u2118"]]},
+
+{"description": "Named entity: xi with a semi-colon.",
+"input":"ξ",
+"output": [["Character", "\u03BE"]]},
+
+{"description": "Named entity: yacute with a semi-colon.",
+"input":"ý",
+"output": [["Character", "\u00FD"]]},
+
+{"description": "Named entity: yacute without a semi-colon.",
+"input":"ý",
+"output": ["ParseError", ["Character", "\u00FD"]]},
+
+{"description": "Named entity: yen with a semi-colon.",
+"input":"¥",
+"output": [["Character", "\u00A5"]]},
+
+{"description": "Named entity: yen without a semi-colon.",
+"input":"¥",
+"output": ["ParseError", ["Character", "\u00A5"]]},
+
+{"description": "Named entity: yuml with a semi-colon.",
+"input":"ÿ",
+"output": [["Character", "\u00FF"]]},
+
+{"description": "Named entity: yuml without a semi-colon.",
+"input":"ÿ",
+"output": ["ParseError", ["Character", "\u00FF"]]},
+
+{"description": "Named entity: zeta with a semi-colon.",
+"input":"ζ",
+"output": [["Character", "\u03B6"]]},
+
+{"description": "Named entity: zwj with a semi-colon.",
+"input":"",
+"output": [["Character", "\u200D"]]},
+
+{"description": "Named entity: zwnj with a semi-colon.",
+"input":"",
+"output": [["Character", "\u200C"]]},
+
+{"description": "Bad named entity: Alpha without a semi-colon.",
+"input":"&Alpha",
+"output": ["ParseError", ["Character", "&Alpha"]]},
+
+{"description": "Bad named entity: alpha without a semi-colon.",
+"input":"&alpha",
+"output": ["ParseError", ["Character", "&alpha"]]},
+
+{"description": "Bad named entity: and without a semi-colon.",
+"input":"&and",
+"output": ["ParseError", ["Character", "&and"]]},
+
+{"description": "Bad named entity: ang without a semi-colon.",
+"input":"&ang",
+"output": ["ParseError", ["Character", "&ang"]]},
+
+{"description": "Bad named entity: apos without a semi-colon.",
+"input":"&apos",
+"output": ["ParseError", ["Character", "&apos"]]},
+
+{"description": "Bad named entity: asymp without a semi-colon.",
+"input":"&asymp",
+"output": ["ParseError", ["Character", "&asymp"]]},
+
+{"description": "Bad named entity: bdquo without a semi-colon.",
+"input":"&bdquo",
+"output": ["ParseError", ["Character", "&bdquo"]]},
+
+{"description": "Bad named entity: Beta without a semi-colon.",
+"input":"&Beta",
+"output": ["ParseError", ["Character", "&Beta"]]},
+
+{"description": "Bad named entity: beta without a semi-colon.",
+"input":"&beta",
+"output": ["ParseError", ["Character", "&beta"]]},
+
+{"description": "Bad named entity: bull without a semi-colon.",
+"input":"&bull",
+"output": ["ParseError", ["Character", "&bull"]]},
+
+{"description": "Bad named entity: cap without a semi-colon.",
+"input":"&cap",
+"output": ["ParseError", ["Character", "&cap"]]},
+
+{"description": "Bad named entity: Chi without a semi-colon.",
+"input":"&Chi",
+"output": ["ParseError", ["Character", "&Chi"]]},
+
+{"description": "Bad named entity: chi without a semi-colon.",
+"input":"&chi",
+"output": ["ParseError", ["Character", "&chi"]]},
+
+{"description": "Bad named entity: circ without a semi-colon.",
+"input":"&circ",
+"output": ["ParseError", ["Character", "&circ"]]},
+
+{"description": "Bad named entity: clubs without a semi-colon.",
+"input":"&clubs",
+"output": ["ParseError", ["Character", "&clubs"]]},
+
+{"description": "Bad named entity: cong without a semi-colon.",
+"input":"&cong",
+"output": ["ParseError", ["Character", "&cong"]]},
+
+{"description": "Bad named entity: crarr without a semi-colon.",
+"input":"&crarr",
+"output": ["ParseError", ["Character", "&crarr"]]},
+
+{"description": "Bad named entity: cup without a semi-colon.",
+"input":"&cup",
+"output": ["ParseError", ["Character", "&cup"]]},
+
+{"description": "Bad named entity: dagger without a semi-colon.",
+"input":"&dagger",
+"output": ["ParseError", ["Character", "&dagger"]]},
+
+{"description": "Bad named entity: dagger without a semi-colon.",
+"input":"&dagger",
+"output": ["ParseError", ["Character", "&dagger"]]},
+
+{"description": "Bad named entity: darr without a semi-colon.",
+"input":"&darr",
+"output": ["ParseError", ["Character", "&darr"]]},
+
+{"description": "Bad named entity: darr without a semi-colon.",
+"input":"&darr",
+"output": ["ParseError", ["Character", "&darr"]]},
+
+{"description": "Bad named entity: Delta without a semi-colon.",
+"input":"&Delta",
+"output": ["ParseError", ["Character", "&Delta"]]},
+
+{"description": "Bad named entity: delta without a semi-colon.",
+"input":"&delta",
+"output": ["ParseError", ["Character", "&delta"]]},
+
+{"description": "Bad named entity: diams without a semi-colon.",
+"input":"&diams",
+"output": ["ParseError", ["Character", "&diams"]]},
+
+{"description": "Bad named entity: empty without a semi-colon.",
+"input":"&empty",
+"output": ["ParseError", ["Character", "&empty"]]},
+
+{"description": "Bad named entity: emsp without a semi-colon.",
+"input":"&emsp",
+"output": ["ParseError", ["Character", "&emsp"]]},
+
+{"description": "Bad named entity: ensp without a semi-colon.",
+"input":"&ensp",
+"output": ["ParseError", ["Character", "&ensp"]]},
+
+{"description": "Bad named entity: Epsilon without a semi-colon.",
+"input":"&Epsilon",
+"output": ["ParseError", ["Character", "&Epsilon"]]},
+
+{"description": "Bad named entity: epsilon without a semi-colon.",
+"input":"&epsilon",
+"output": ["ParseError", ["Character", "&epsilon"]]},
+
+{"description": "Bad named entity: equiv without a semi-colon.",
+"input":"&equiv",
+"output": ["ParseError", ["Character", "&equiv"]]},
+
+{"description": "Bad named entity: Eta without a semi-colon.",
+"input":"&Eta",
+"output": ["ParseError", ["Character", "&Eta"]]},
+
+{"description": "Bad named entity: eta without a semi-colon.",
+"input":"&eta",
+"output": ["ParseError", ["Character", "&eta"]]},
+
+{"description": "Bad named entity: euro without a semi-colon.",
+"input":"&euro",
+"output": ["ParseError", ["Character", "&euro"]]},
+
+{"description": "Bad named entity: exist without a semi-colon.",
+"input":"&exist",
+"output": ["ParseError", ["Character", "&exist"]]},
+
+{"description": "Bad named entity: fnof without a semi-colon.",
+"input":"&fnof",
+"output": ["ParseError", ["Character", "&fnof"]]},
+
+{"description": "Bad named entity: forall without a semi-colon.",
+"input":"&forall",
+"output": ["ParseError", ["Character", "&forall"]]},
+
+{"description": "Bad named entity: frasl without a semi-colon.",
+"input":"&frasl",
+"output": ["ParseError", ["Character", "&frasl"]]},
+
+{"description": "Bad named entity: Gamma without a semi-colon.",
+"input":"&Gamma",
+"output": ["ParseError", ["Character", "&Gamma"]]},
+
+{"description": "Bad named entity: gamma without a semi-colon.",
+"input":"&gamma",
+"output": ["ParseError", ["Character", "&gamma"]]},
+
+{"description": "Bad named entity: ge without a semi-colon.",
+"input":"&ge",
+"output": ["ParseError", ["Character", "&ge"]]},
+
+{"description": "Bad named entity: harr without a semi-colon.",
+"input":"&harr",
+"output": ["ParseError", ["Character", "&harr"]]},
+
+{"description": "Bad named entity: harr without a semi-colon.",
+"input":"&harr",
+"output": ["ParseError", ["Character", "&harr"]]},
+
+{"description": "Bad named entity: hearts without a semi-colon.",
+"input":"&hearts",
+"output": ["ParseError", ["Character", "&hearts"]]},
+
+{"description": "Bad named entity: hellip without a semi-colon.",
+"input":"&hellip",
+"output": ["ParseError", ["Character", "&hellip"]]},
+
+{"description": "Bad named entity: image without a semi-colon.",
+"input":"&image",
+"output": ["ParseError", ["Character", "&image"]]},
+
+{"description": "Bad named entity: infin without a semi-colon.",
+"input":"&infin",
+"output": ["ParseError", ["Character", "&infin"]]},
+
+{"description": "Bad named entity: int without a semi-colon.",
+"input":"&int",
+"output": ["ParseError", ["Character", "&int"]]},
+
+{"description": "Bad named entity: Iota without a semi-colon.",
+"input":"&Iota",
+"output": ["ParseError", ["Character", "&Iota"]]},
+
+{"description": "Bad named entity: iota without a semi-colon.",
+"input":"&iota",
+"output": ["ParseError", ["Character", "&iota"]]},
+
+{"description": "Bad named entity: isin without a semi-colon.",
+"input":"&isin",
+"output": ["ParseError", ["Character", "&isin"]]},
+
+{"description": "Bad named entity: Kappa without a semi-colon.",
+"input":"&Kappa",
+"output": ["ParseError", ["Character", "&Kappa"]]},
+
+{"description": "Bad named entity: kappa without a semi-colon.",
+"input":"&kappa",
+"output": ["ParseError", ["Character", "&kappa"]]},
+
+{"description": "Bad named entity: Lambda without a semi-colon.",
+"input":"&Lambda",
+"output": ["ParseError", ["Character", "&Lambda"]]},
+
+{"description": "Bad named entity: lambda without a semi-colon.",
+"input":"&lambda",
+"output": ["ParseError", ["Character", "&lambda"]]},
+
+{"description": "Bad named entity: lang without a semi-colon.",
+"input":"&lang",
+"output": ["ParseError", ["Character", "&lang"]]},
+
+{"description": "Bad named entity: larr without a semi-colon.",
+"input":"&larr",
+"output": ["ParseError", ["Character", "&larr"]]},
+
+{"description": "Bad named entity: larr without a semi-colon.",
+"input":"&larr",
+"output": ["ParseError", ["Character", "&larr"]]},
+
+{"description": "Bad named entity: lceil without a semi-colon.",
+"input":"&lceil",
+"output": ["ParseError", ["Character", "&lceil"]]},
+
+{"description": "Bad named entity: ldquo without a semi-colon.",
+"input":"&ldquo",
+"output": ["ParseError", ["Character", "&ldquo"]]},
+
+{"description": "Bad named entity: le without a semi-colon.",
+"input":"&le",
+"output": ["ParseError", ["Character", "&le"]]},
+
+{"description": "Bad named entity: lfloor without a semi-colon.",
+"input":"&lfloor",
+"output": ["ParseError", ["Character", "&lfloor"]]},
+
+{"description": "Bad named entity: lowast without a semi-colon.",
+"input":"&lowast",
+"output": ["ParseError", ["Character", "&lowast"]]},
+
+{"description": "Bad named entity: loz without a semi-colon.",
+"input":"&loz",
+"output": ["ParseError", ["Character", "&loz"]]},
+
+{"description": "Bad named entity: lrm without a semi-colon.",
+"input":"&lrm",
+"output": ["ParseError", ["Character", "&lrm"]]},
+
+{"description": "Bad named entity: lsaquo without a semi-colon.",
+"input":"&lsaquo",
+"output": ["ParseError", ["Character", "&lsaquo"]]},
+
+{"description": "Bad named entity: lsquo without a semi-colon.",
+"input":"&lsquo",
+"output": ["ParseError", ["Character", "&lsquo"]]},
+
+{"description": "Bad named entity: mdash without a semi-colon.",
+"input":"&mdash",
+"output": ["ParseError", ["Character", "&mdash"]]},
+
+{"description": "Bad named entity: minus without a semi-colon.",
+"input":"&minus",
+"output": ["ParseError", ["Character", "&minus"]]},
+
+{"description": "Bad named entity: Mu without a semi-colon.",
+"input":"&Mu",
+"output": ["ParseError", ["Character", "&Mu"]]},
+
+{"description": "Bad named entity: mu without a semi-colon.",
+"input":"&mu",
+"output": ["ParseError", ["Character", "&mu"]]},
+
+{"description": "Bad named entity: nabla without a semi-colon.",
+"input":"&nabla",
+"output": ["ParseError", ["Character", "&nabla"]]},
+
+{"description": "Bad named entity: ndash without a semi-colon.",
+"input":"&ndash",
+"output": ["ParseError", ["Character", "&ndash"]]},
+
+{"description": "Bad named entity: ne without a semi-colon.",
+"input":"&ne",
+"output": ["ParseError", ["Character", "&ne"]]},
+
+{"description": "Bad named entity: ni without a semi-colon.",
+"input":"&ni",
+"output": ["ParseError", ["Character", "&ni"]]},
+
+{"description": "Bad named entity: notin without a semi-colon.",
+"input":"¬in",
+"output": ["ParseError", ["Character", "\u00ACin"]]},
+
+{"description": "Bad named entity: nsub without a semi-colon.",
+"input":"&nsub",
+"output": ["ParseError", ["Character", "&nsub"]]},
+
+{"description": "Bad named entity: Nu without a semi-colon.",
+"input":"&Nu",
+"output": ["ParseError", ["Character", "&Nu"]]},
+
+{"description": "Bad named entity: nu without a semi-colon.",
+"input":"&nu",
+"output": ["ParseError", ["Character", "&nu"]]},
+
+{"description": "Bad named entity: OElig without a semi-colon.",
+"input":"&OElig",
+"output": ["ParseError", ["Character", "&OElig"]]},
+
+{"description": "Bad named entity: oelig without a semi-colon.",
+"input":"&oelig",
+"output": ["ParseError", ["Character", "&oelig"]]},
+
+{"description": "Bad named entity: oline without a semi-colon.",
+"input":"&oline",
+"output": ["ParseError", ["Character", "&oline"]]},
+
+{"description": "Bad named entity: Omega without a semi-colon.",
+"input":"&Omega",
+"output": ["ParseError", ["Character", "&Omega"]]},
+
+{"description": "Bad named entity: omega without a semi-colon.",
+"input":"&omega",
+"output": ["ParseError", ["Character", "&omega"]]},
+
+{"description": "Bad named entity: Omicron without a semi-colon.",
+"input":"&Omicron",
+"output": ["ParseError", ["Character", "&Omicron"]]},
+
+{"description": "Bad named entity: omicron without a semi-colon.",
+"input":"&omicron",
+"output": ["ParseError", ["Character", "&omicron"]]},
+
+{"description": "Bad named entity: oplus without a semi-colon.",
+"input":"&oplus",
+"output": ["ParseError", ["Character", "&oplus"]]},
+
+{"description": "Bad named entity: or without a semi-colon.",
+"input":"&or",
+"output": ["ParseError", ["Character", "&or"]]},
+
+{"description": "Bad named entity: otimes without a semi-colon.",
+"input":"&otimes",
+"output": ["ParseError", ["Character", "&otimes"]]},
+
+{"description": "Bad named entity: part without a semi-colon.",
+"input":"&part",
+"output": ["ParseError", ["Character", "&part"]]},
+
+{"description": "Bad named entity: permil without a semi-colon.",
+"input":"&permil",
+"output": ["ParseError", ["Character", "&permil"]]},
+
+{"description": "Bad named entity: perp without a semi-colon.",
+"input":"&perp",
+"output": ["ParseError", ["Character", "&perp"]]},
+
+{"description": "Bad named entity: Phi without a semi-colon.",
+"input":"&Phi",
+"output": ["ParseError", ["Character", "&Phi"]]},
+
+{"description": "Bad named entity: phi without a semi-colon.",
+"input":"&phi",
+"output": ["ParseError", ["Character", "&phi"]]},
+
+{"description": "Bad named entity: Pi without a semi-colon.",
+"input":"&Pi",
+"output": ["ParseError", ["Character", "&Pi"]]},
+
+{"description": "Bad named entity: pi without a semi-colon.",
+"input":"&pi",
+"output": ["ParseError", ["Character", "&pi"]]},
+
+{"description": "Bad named entity: piv without a semi-colon.",
+"input":"&piv",
+"output": ["ParseError", ["Character", "&piv"]]},
+
+{"description": "Bad named entity: prime without a semi-colon.",
+"input":"&prime",
+"output": ["ParseError", ["Character", "&prime"]]},
+
+{"description": "Bad named entity: prime without a semi-colon.",
+"input":"&prime",
+"output": ["ParseError", ["Character", "&prime"]]},
+
+{"description": "Bad named entity: prod without a semi-colon.",
+"input":"&prod",
+"output": ["ParseError", ["Character", "&prod"]]},
+
+{"description": "Bad named entity: prop without a semi-colon.",
+"input":"&prop",
+"output": ["ParseError", ["Character", "&prop"]]},
+
+{"description": "Bad named entity: Psi without a semi-colon.",
+"input":"&Psi",
+"output": ["ParseError", ["Character", "&Psi"]]},
+
+{"description": "Bad named entity: psi without a semi-colon.",
+"input":"&psi",
+"output": ["ParseError", ["Character", "&psi"]]},
+
+{"description": "Bad named entity: radic without a semi-colon.",
+"input":"&radic",
+"output": ["ParseError", ["Character", "&radic"]]},
+
+{"description": "Bad named entity: rang without a semi-colon.",
+"input":"&rang",
+"output": ["ParseError", ["Character", "&rang"]]},
+
+{"description": "Bad named entity: rarr without a semi-colon.",
+"input":"&rarr",
+"output": ["ParseError", ["Character", "&rarr"]]},
+
+{"description": "Bad named entity: rarr without a semi-colon.",
+"input":"&rarr",
+"output": ["ParseError", ["Character", "&rarr"]]},
+
+{"description": "Bad named entity: rceil without a semi-colon.",
+"input":"&rceil",
+"output": ["ParseError", ["Character", "&rceil"]]},
+
+{"description": "Bad named entity: rdquo without a semi-colon.",
+"input":"&rdquo",
+"output": ["ParseError", ["Character", "&rdquo"]]},
+
+{"description": "Bad named entity: real without a semi-colon.",
+"input":"&real",
+"output": ["ParseError", ["Character", "&real"]]},
+
+{"description": "Bad named entity: rfloor without a semi-colon.",
+"input":"&rfloor",
+"output": ["ParseError", ["Character", "&rfloor"]]},
+
+{"description": "Bad named entity: Rho without a semi-colon.",
+"input":"&Rho",
+"output": ["ParseError", ["Character", "&Rho"]]},
+
+{"description": "Bad named entity: rho without a semi-colon.",
+"input":"&rho",
+"output": ["ParseError", ["Character", "&rho"]]},
+
+{"description": "Bad named entity: rlm without a semi-colon.",
+"input":"&rlm",
+"output": ["ParseError", ["Character", "&rlm"]]},
+
+{"description": "Bad named entity: rsaquo without a semi-colon.",
+"input":"&rsaquo",
+"output": ["ParseError", ["Character", "&rsaquo"]]},
+
+{"description": "Bad named entity: rsquo without a semi-colon.",
+"input":"&rsquo",
+"output": ["ParseError", ["Character", "&rsquo"]]},
+
+{"description": "Bad named entity: sbquo without a semi-colon.",
+"input":"&sbquo",
+"output": ["ParseError", ["Character", "&sbquo"]]},
+
+{"description": "Bad named entity: Scaron without a semi-colon.",
+"input":"&Scaron",
+"output": ["ParseError", ["Character", "&Scaron"]]},
+
+{"description": "Bad named entity: scaron without a semi-colon.",
+"input":"&scaron",
+"output": ["ParseError", ["Character", "&scaron"]]},
+
+{"description": "Bad named entity: sdot without a semi-colon.",
+"input":"&sdot",
+"output": ["ParseError", ["Character", "&sdot"]]},
+
+{"description": "Bad named entity: Sigma without a semi-colon.",
+"input":"&Sigma",
+"output": ["ParseError", ["Character", "&Sigma"]]},
+
+{"description": "Bad named entity: sigma without a semi-colon.",
+"input":"&sigma",
+"output": ["ParseError", ["Character", "&sigma"]]},
+
+{"description": "Bad named entity: sigmaf without a semi-colon.",
+"input":"&sigmaf",
+"output": ["ParseError", ["Character", "&sigmaf"]]},
+
+{"description": "Bad named entity: sim without a semi-colon.",
+"input":"&sim",
+"output": ["ParseError", ["Character", "&sim"]]},
+
+{"description": "Bad named entity: spades without a semi-colon.",
+"input":"&spades",
+"output": ["ParseError", ["Character", "&spades"]]},
+
+{"description": "Bad named entity: sub without a semi-colon.",
+"input":"&sub",
+"output": ["ParseError", ["Character", "&sub"]]},
+
+{"description": "Bad named entity: sube without a semi-colon.",
+"input":"&sube",
+"output": ["ParseError", ["Character", "&sube"]]},
+
+{"description": "Bad named entity: sum without a semi-colon.",
+"input":"&sum",
+"output": ["ParseError", ["Character", "&sum"]]},
+
+{"description": "Bad named entity: sup without a semi-colon.",
+"input":"&sup",
+"output": ["ParseError", ["Character", "&sup"]]},
+
+{"description": "Bad named entity: supe without a semi-colon.",
+"input":"&supe",
+"output": ["ParseError", ["Character", "&supe"]]},
+
+{"description": "Bad named entity: Tau without a semi-colon.",
+"input":"&Tau",
+"output": ["ParseError", ["Character", "&Tau"]]},
+
+{"description": "Bad named entity: tau without a semi-colon.",
+"input":"&tau",
+"output": ["ParseError", ["Character", "&tau"]]},
+
+{"description": "Bad named entity: there4 without a semi-colon.",
+"input":"&there4",
+"output": ["ParseError", ["Character", "&there4"]]},
+
+{"description": "Bad named entity: Theta without a semi-colon.",
+"input":"&Theta",
+"output": ["ParseError", ["Character", "&Theta"]]},
+
+{"description": "Bad named entity: theta without a semi-colon.",
+"input":"&theta",
+"output": ["ParseError", ["Character", "&theta"]]},
+
+{"description": "Bad named entity: thetasym without a semi-colon.",
+"input":"&thetasym",
+"output": ["ParseError", ["Character", "&thetasym"]]},
+
+{"description": "Bad named entity: thinsp without a semi-colon.",
+"input":"&thinsp",
+"output": ["ParseError", ["Character", "&thinsp"]]},
+
+{"description": "Bad named entity: tilde without a semi-colon.",
+"input":"&tilde",
+"output": ["ParseError", ["Character", "&tilde"]]},
+
+{"description": "Bad named entity: trade without a semi-colon.",
+"input":"&trade",
+"output": ["ParseError", ["Character", "&trade"]]},
+
+{"description": "Bad named entity: uarr without a semi-colon.",
+"input":"&uarr",
+"output": ["ParseError", ["Character", "&uarr"]]},
+
+{"description": "Bad named entity: uarr without a semi-colon.",
+"input":"&uarr",
+"output": ["ParseError", ["Character", "&uarr"]]},
+
+{"description": "Bad named entity: upsih without a semi-colon.",
+"input":"&upsih",
+"output": ["ParseError", ["Character", "&upsih"]]},
+
+{"description": "Bad named entity: Upsilon without a semi-colon.",
+"input":"&Upsilon",
+"output": ["ParseError", ["Character", "&Upsilon"]]},
+
+{"description": "Bad named entity: upsilon without a semi-colon.",
+"input":"&upsilon",
+"output": ["ParseError", ["Character", "&upsilon"]]},
+
+{"description": "Bad named entity: weierp without a semi-colon.",
+"input":"&weierp",
+"output": ["ParseError", ["Character", "&weierp"]]},
+
+{"description": "Bad named entity: Xi without a semi-colon.",
+"input":"&Xi",
+"output": ["ParseError", ["Character", "&Xi"]]},
+
+{"description": "Bad named entity: xi without a semi-colon.",
+"input":"&xi",
+"output": ["ParseError", ["Character", "&xi"]]},
+
+{"description": "Bad named entity: Yuml without a semi-colon.",
+"input":"&Yuml",
+"output": ["ParseError", ["Character", "&Yuml"]]},
+
+{"description": "Bad named entity: Zeta without a semi-colon.",
+"input":"&Zeta",
+"output": ["ParseError", ["Character", "&Zeta"]]},
+
+{"description": "Bad named entity: zeta without a semi-colon.",
+"input":"&zeta",
+"output": ["ParseError", ["Character", "&zeta"]]},
+
+{"description": "Bad named entity: zwj without a semi-colon.",
+"input":"&zwj",
+"output": ["ParseError", ["Character", "&zwj"]]},
+
+{"description": "Bad named entity: zwnj without a semi-colon.",
+"input":"&zwnj",
+"output": ["ParseError", ["Character", "&zwnj"]]},
+
+{"description": "Bad named entity: zwnj without a semi-colon.",
+"input":"&zwnj",
+"output": ["ParseError", ["Character", "&zwnj"]]},
+
+{"description": "CR as numeric entity",
+"input":"
",
+"output": ["ParseError", ["Character", "\n"]]},
+
+{"description": "CR as hexadecimal numeric entity",
+"input":"
",
+"output": ["ParseError", ["Character", "\n"]]},
+
+{"description": "Windows-1252 EURO SIGN numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u20AC"]]},
+
+{"description": "Windows-1252 REPLACEMENT CHAR numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\uFFFD"]]},
+
+{"description": "Windows-1252 SINGLE LOW-9 QUOTATION MARK numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u201A"]]},
+
+{"description": "Windows-1252 LATIN SMALL LETTER F WITH HOOK numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u0192"]]},
+
+{"description": "Windows-1252 DOUBLE LOW-9 QUOTATION MARK numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u201E"]]},
+
+{"description": "Windows-1252 HORIZONTAL ELLIPSIS numeric entity.",
+"input":"
",
+"output": ["ParseError", ["Character", "\u2026"]]},
+
+{"description": "Windows-1252 DAGGER numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2020"]]},
+
+{"description": "Windows-1252 DOUBLE DAGGER numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2021"]]},
+
+{"description": "Windows-1252 MODIFIER LETTER CIRCUMFLEX ACCENT numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u02C6"]]},
+
+{"description": "Windows-1252 PER MILLE SIGN numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2030"]]},
+
+{"description": "Windows-1252 LATIN CAPITAL LETTER S WITH CARON numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u0160"]]},
+
+{"description": "Windows-1252 SINGLE LEFT-POINTING ANGLE QUOTATION MARK numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2039"]]},
+
+{"description": "Windows-1252 LATIN CAPITAL LIGATURE OE numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u0152"]]},
+
+{"description": "Windows-1252 REPLACEMENT CHAR numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\uFFFD"]]},
+
+{"description": "Windows-1252 LATIN CAPITAL LETTER Z WITH CARON numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u017D"]]},
+
+{"description": "Windows-1252 REPLACEMENT CHAR numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\uFFFD"]]},
+
+{"description": "Windows-1252 REPLACEMENT CHAR numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\uFFFD"]]},
+
+{"description": "Windows-1252 LEFT SINGLE QUOTATION MARK numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2018"]]},
+
+{"description": "Windows-1252 RIGHT SINGLE QUOTATION MARK numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2019"]]},
+
+{"description": "Windows-1252 LEFT DOUBLE QUOTATION MARK numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u201C"]]},
+
+{"description": "Windows-1252 RIGHT DOUBLE QUOTATION MARK numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u201D"]]},
+
+{"description": "Windows-1252 BULLET numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2022"]]},
+
+{"description": "Windows-1252 EN DASH numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2013"]]},
+
+{"description": "Windows-1252 EM DASH numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2014"]]},
+
+{"description": "Windows-1252 SMALL TILDE numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u02DC"]]},
+
+{"description": "Windows-1252 TRADE MARK SIGN numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2122"]]},
+
+{"description": "Windows-1252 LATIN SMALL LETTER S WITH CARON numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u0161"]]},
+
+{"description": "Windows-1252 SINGLE RIGHT-POINTING ANGLE QUOTATION MARK numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u203A"]]},
+
+{"description": "Windows-1252 LATIN SMALL LIGATURE OE numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u0153"]]},
+
+{"description": "Windows-1252 REPLACEMENT CHAR numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\uFFFD"]]},
+
+{"description": "Windows-1252 EURO SIGN hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u20AC"]]},
+
+{"description": "Windows-1252 REPLACEMENT CHAR hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\uFFFD"]]},
+
+{"description": "Windows-1252 SINGLE LOW-9 QUOTATION MARK hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u201A"]]},
+
+{"description": "Windows-1252 LATIN SMALL LETTER F WITH HOOK hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u0192"]]},
+
+{"description": "Windows-1252 DOUBLE LOW-9 QUOTATION MARK hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u201E"]]},
+
+{"description": "Windows-1252 HORIZONTAL ELLIPSIS hexadecimal numeric entity.",
+"input":"
",
+"output": ["ParseError", ["Character", "\u2026"]]},
+
+{"description": "Windows-1252 DAGGER hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2020"]]},
+
+{"description": "Windows-1252 DOUBLE DAGGER hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2021"]]},
+
+{"description": "Windows-1252 MODIFIER LETTER CIRCUMFLEX ACCENT hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u02C6"]]},
+
+{"description": "Windows-1252 PER MILLE SIGN hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2030"]]},
+
+{"description": "Windows-1252 LATIN CAPITAL LETTER S WITH CARON hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u0160"]]},
+
+{"description": "Windows-1252 SINGLE LEFT-POINTING ANGLE QUOTATION MARK hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2039"]]},
+
+{"description": "Windows-1252 LATIN CAPITAL LIGATURE OE hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u0152"]]},
+
+{"description": "Windows-1252 REPLACEMENT CHAR hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\uFFFD"]]},
+
+{"description": "Windows-1252 LATIN CAPITAL LETTER Z WITH CARON hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u017D"]]},
+
+{"description": "Windows-1252 REPLACEMENT CHAR hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\uFFFD"]]},
+
+{"description": "Windows-1252 REPLACEMENT CHAR hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\uFFFD"]]},
+
+{"description": "Windows-1252 LEFT SINGLE QUOTATION MARK hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2018"]]},
+
+{"description": "Windows-1252 RIGHT SINGLE QUOTATION MARK hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2019"]]},
+
+{"description": "Windows-1252 LEFT DOUBLE QUOTATION MARK hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u201C"]]},
+
+{"description": "Windows-1252 RIGHT DOUBLE QUOTATION MARK hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u201D"]]},
+
+{"description": "Windows-1252 BULLET hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2022"]]},
+
+{"description": "Windows-1252 EN DASH hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2013"]]},
+
+{"description": "Windows-1252 EM DASH hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2014"]]},
+
+{"description": "Windows-1252 SMALL TILDE hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u02DC"]]},
+
+{"description": "Windows-1252 TRADE MARK SIGN hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u2122"]]},
+
+{"description": "Windows-1252 LATIN SMALL LETTER S WITH CARON hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u0161"]]},
+
+{"description": "Windows-1252 SINGLE RIGHT-POINTING ANGLE QUOTATION MARK hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u203A"]]},
+
+{"description": "Windows-1252 LATIN SMALL LIGATURE OE hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u0153"]]},
+
+{"description": "Windows-1252 REPLACEMENT CHAR hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\uFFFD"]]},
+
+{"description": "Windows-1252 LATIN SMALL LETTER Z WITH CARON hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u017E"]]},
+
+{"description": "Windows-1252 LATIN CAPITAL LETTER Y WITH DIAERESIS hexadecimal numeric entity.",
+"input":"",
+"output": ["ParseError", ["Character", "\u0178"]]}
+
+]}
diff --git a/vendor/plugins/HTML5lib/testdata/validator/base-href-attribute.test b/vendor/plugins/HTML5lib/testdata/validator/base-href-attribute.test
new file mode 100755
index 00000000..83a626a7
--- /dev/null
+++ b/vendor/plugins/HTML5lib/testdata/validator/base-href-attribute.test
@@ -0,0 +1,787 @@
+{"tests": [
+
+{"description": "base href contains invalid URI due to leading space",
+"input": " ",
+"fail-if": "invalid-browsing-context"},
+
+{"description": "valid base target attribute '_parent'",
+"input": " ",
+"fail-if": "invalid-browsing-context"},
+
+{"description": "valid base target attribute '_top'",
+"input": " ",
+"fail-if": "invalid-browsing-context"},
+
+{"description": "valid base target attribute '_blank'",
+"input": " ",
+"fail-if": "invalid-browsing-context"},
+
+{"description": "valid base target attribute 'foo'",
+"input": " ",
+"fail-if": "invalid-browsing-context"},
+
+{"description": "base target attribute may be blank",
+"input": " ",
+"fail-if": "invalid-browsing-context"},
+
+{"description": "invalid base target attribute '_'",
+"input": " ",
+"fail-unless": "invalid-browsing-context"},
+
+{"description": "invalid base target attribute '_foo'",
+"input": " ",
+"fail-unless": "invalid-browsing-context"}
+
+]}
\ No newline at end of file
diff --git a/vendor/plugins/HTML5lib/testdata/validator/blockquote-cite-attribute.test b/vendor/plugins/HTML5lib/testdata/validator/blockquote-cite-attribute.test
new file mode 100755
index 00000000..153c6e6a
--- /dev/null
+++ b/vendor/plugins/HTML5lib/testdata/validator/blockquote-cite-attribute.test
@@ -0,0 +1,7 @@
+{"tests": [
+
+{"description": "blockquote cite contains invalid URI due to space in domain",
+"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid single class attribute value with trailing tab",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid single class attribute value with leading and trailing tab",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid single class attribute value with leading LF",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid single class attribute value with trailing LF",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid single class attribute value with leading and trailing LF",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid single class attribute value with leading LT",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid single class attribute value with trailing LT",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid single class attribute value with leading and trailing LT",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid single class attribute value with leading FF",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid single class attribute value with trailing FF",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid single class attribute value with leading and trailing FF",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid single class attribute value with leading CR",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid single class attribute value with trailing CR",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid single class attribute value with leading and trailing CR",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid double class attribute value separated by space",
@@ -85,24 +81,23 @@ a
"fail-if": "invalid-attribute-value"},
{"description": "valid double class attribute value separated by tab",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid double class attribute value separated by LF",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid double class attribute value separated by LT",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid double class attribute value separated by FF",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "valid double class attribute value separated by CR",
-"input": "",
+"input": "",
"fail-if": "invalid-attribute-value"},
{"description": "invalid duplicated class attribute value separated by space",
@@ -110,24 +105,23 @@ b'>",
"fail-unless": "invalid-attribute-value"},
{"description": "invalid duplicated class attribute value separated by tab",
-"input": "",
+"input": "",
"fail-unless": "invalid-attribute-value"},
{"description": "invalid duplicated class attribute value separated by LF",
-"input": "",
+"input": "",
"fail-unless": "invalid-attribute-value"},
{"description": "invalid duplicated class attribute value separated by LT",
-"input": "",
+"input": "",
"fail-unless": "invalid-attribute-value"},
{"description": "invalid duplicated class attribute value separated by FF",
-"input": "",
+"input": "",
"fail-unless": "invalid-attribute-value"},
{"description": "invalid duplicated class attribute value separated by CR",
-"input": "",
+"input": "",
"fail-unless": "duplicate-value-in-token-list"},
{"description": "invalid duplicated class attribute value separated by space",
@@ -135,24 +129,23 @@ a'>",
"fail-unless": "duplicate-value-in-token-list"},
{"description": "invalid duplicated class attribute value separated by tab",
-"input": "",
+"input": "",
"fail-unless": "duplicate-value-in-token-list"},
{"description": "invalid duplicated class attribute value separated by LF",
-"input": "",
+"input": "",
"fail-unless": "duplicate-value-in-token-list"},
{"description": "invalid duplicated class attribute value separated by LT",
-"input": "",
+"input": "",
"fail-unless": "duplicate-value-in-token-list"},
{"description": "invalid duplicated class attribute value separated by FF",
-"input": "",
+"input": "",
"fail-unless": "duplicate-value-in-token-list"},
{"description": "invalid duplicated class attribute value separated by CR",
-"input": "",
+"input": "",
"fail-unless": "duplicate-value-in-token-list"}
]}
diff --git a/vendor/plugins/HTML5lib/testdata/validator/contenteditableattribute.test b/vendor/plugins/HTML5lib/testdata/validator/contenteditableattribute.test
index 66135836..b6ae1d27 100755
--- a/vendor/plugins/HTML5lib/testdata/validator/contenteditableattribute.test
+++ b/vendor/plugins/HTML5lib/testdata/validator/contenteditableattribute.test
@@ -34,26 +34,26 @@
{"description": "invalid contenteditable attribute value 'foo'",
"input": "",
-"fail-unless": "invalid-attribute-value"},
+"fail-unless": "invalid-enumerated-value"},
{"description": "invalid contenteditable attribute value '0'",
"input": "",
-"fail-unless": "invalid-attribute-value"},
+"fail-unless": "invalid-enumerated-value"},
{"description": "invalid contenteditable attribute value '1'",
"input": "",
-"fail-unless": "invalid-attribute-value"},
+"fail-unless": "invalid-enumerated-value"},
{"description": "invalid contenteditable attribute value 'yes'",
"input": "",
-"fail-unless": "invalid-attribute-value"},
+"fail-unless": "invalid-enumerated-value"},
{"description": "invalid contenteditable attribute value 'no'",
"input": "",
-"fail-unless": "invalid-attribute-value"},
+"fail-unless": "invalid-enumerated-value"},
{"description": "invalid contenteditable attribute value 'inherit'",
"input": "",
-"fail-unless": "invalid-attribute-value"}
+"fail-unless": "invalid-enumerated-value"}
]}
\ No newline at end of file
diff --git a/vendor/plugins/HTML5lib/testdata/validator/contextmenuattribute.test b/vendor/plugins/HTML5lib/testdata/validator/contextmenuattribute.test
index e9b2f3cc..59e4397c 100755
--- a/vendor/plugins/HTML5lib/testdata/validator/contextmenuattribute.test
+++ b/vendor/plugins/HTML5lib/testdata/validator/contextmenuattribute.test
@@ -53,66 +53,63 @@
"fail-unless": "space-in-id"},
{"description": "invalid ID because of leading tab",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of trailing tab",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of tab in value",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of leading LF",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of trailing LF",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of LF in value",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of leading LT",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of trailing LT",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of LT in value",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of leading FF",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of trailing FF",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of FF in value",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of leading CR",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of trailing CR",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of CR in value",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"}
-]}
\ No newline at end of file
+]}
diff --git a/vendor/plugins/HTML5lib/testdata/validator/dirattribute.test b/vendor/plugins/HTML5lib/testdata/validator/dirattribute.test
new file mode 100755
index 00000000..71883dc1
--- /dev/null
+++ b/vendor/plugins/HTML5lib/testdata/validator/dirattribute.test
@@ -0,0 +1,59 @@
+{"tests": [
+
+{"description": "valid dir attribute value 'ltr'",
+"input": "",
+"fail-if": "invalid-attribute-value"},
+
+{"description": "valid dir attribute value 'LTR'",
+"input": "",
+"fail-if": "invalid-attribute-value"},
+
+{"description": "valid dir attribute value 'LtR'",
+"input": "",
+"fail-if": "invalid-attribute-value"},
+
+{"description": "valid dir attribute value 'rtl'",
+"input": "",
+"fail-if": "invalid-attribute-value"},
+
+{"description": "valid dir attribute value 'RTL'",
+"input": "",
+"fail-if": "invalid-attribute-value"},
+
+{"description": "valid dir attribute value 'RtL'",
+"input": "",
+"fail-if": "invalid-attribute-value"},
+
+{"description": "invalid dir attribute value due to leading space",
+"input": "",
+"fail-unless": "invalid-enumerated-value"},
+
+{"description": "dir attribute value can not be blank",
+"input": "",
+"fail-unless": "attribute-value-can-not-be-blank"},
+
+{"description": "dir attribute value can not be blank (with quotes)",
+"input": "",
+"fail-unless": "attribute-value-can-not-be-blank"},
+
+{"description": "invalid dir attribute value 'left'",
+"input": "",
+"fail-unless": "invalid-enumerated-value"},
+
+{"description": "invalid dir attribute value 'right'",
+"input": "",
+"fail-unless": "invalid-enumerated-value"},
+
+{"description": "invalid dir attribute value 'lefttoright'",
+"input": "",
+"fail-unless": "invalid-enumerated-value"},
+
+{"description": "invalid dir attribute value 'righttoleft'",
+"input": "",
+"fail-unless": "invalid-enumerated-value"},
+
+{"description": "invalid dir attribute value 'inherit'",
+"input": "",
+"fail-unless": "invalid-enumerated-value"}
+
+]}
\ No newline at end of file
diff --git a/vendor/plugins/HTML5lib/testdata/validator/draggableattribute.test b/vendor/plugins/HTML5lib/testdata/validator/draggableattribute.test
new file mode 100755
index 00000000..49e692d9
--- /dev/null
+++ b/vendor/plugins/HTML5lib/testdata/validator/draggableattribute.test
@@ -0,0 +1,63 @@
+{"tests": [
+
+{"description": "valid draggable attribute value 'true'",
+"input": "",
+"fail-if": "invalid-attribute-value"},
+
+{"description": "valid draggable attribute value 'TRUE'",
+"input": "",
+"fail-if": "invalid-attribute-value"},
+
+{"description": "valid draggable attribute value 'TrUe'",
+"input": "",
+"fail-if": "invalid-attribute-value"},
+
+{"description": "valid draggable attribute value 'false'",
+"input": "",
+"fail-if": "invalid-attribute-value"},
+
+{"description": "valid draggable attribute value 'FALSE'",
+"input": "",
+"fail-if": "invalid-attribute-value"},
+
+{"description": "valid draggable attribute value 'FalSe'",
+"input": "",
+"fail-if": "invalid-attribute-value"},
+
+{"description": "invalid draggable attribute value ''",
+"input": "",
+"fail-unless": "attribute-value-can-not-be-blank"},
+
+{"description": "valid draggable attribute value (not specified)",
+"input": "",
+"fail-unless": "attribute-value-can-not-be-blank"},
+
+{"description": "invalid draggable attribute value 'foo'",
+"input": "",
+"fail-unless": "invalid-enumerated-value"},
+
+{"description": "invalid draggable attribute value '0'",
+"input": "",
+"fail-unless": "invalid-enumerated-value"},
+
+{"description": "invalid draggable attribute value '1'",
+"input": "",
+"fail-unless": "invalid-enumerated-value"},
+
+{"description": "invalid draggable attribute value 'yes'",
+"input": "",
+"fail-unless": "invalid-enumerated-value"},
+
+{"description": "invalid draggable attribute value 'no'",
+"input": "",
+"fail-unless": "invalid-enumerated-value"},
+
+{"description": "invalid draggable attribute value 'auto'",
+"input": "",
+"fail-unless": "invalid-enumerated-value"},
+
+{"description": "invalid draggable attribute value 'inherit'",
+"input": "",
+"fail-unless": "invalid-enumerated-value"}
+
+]}
\ No newline at end of file
diff --git a/vendor/plugins/HTML5lib/testdata/validator/html-xmlns-attribute.test b/vendor/plugins/HTML5lib/testdata/validator/html-xmlns-attribute.test
new file mode 100755
index 00000000..2ebd19eb
--- /dev/null
+++ b/vendor/plugins/HTML5lib/testdata/validator/html-xmlns-attribute.test
@@ -0,0 +1,23 @@
+{"tests": [
+
+{"description": "valid html xmlns attribute",
+"input": "",
+"fail-if": "invalid-root-namespace"},
+
+{"description": "invalid html xmlns attribute due to leading space",
+"input": "",
+"fail-unless": "invalid-root-namespace"},
+
+{"description": "invalid html xmlns attribute due to trailing space",
+"input": "",
+"fail-unless": "invalid-root-namespace"},
+
+{"description": "invalid html xmlns attribute due to uppercase",
+"input": "",
+"fail-unless": "invalid-root-namespace"},
+
+{"description": "invalid xmlns attribute on non-html element",
+"input": "",
+"fail-unless": "unknown-attribute"}
+
+]}
\ No newline at end of file
diff --git a/vendor/plugins/HTML5lib/testdata/validator/idattribute.test b/vendor/plugins/HTML5lib/testdata/validator/idattribute.test
index 76807d18..4058d521 100755
--- a/vendor/plugins/HTML5lib/testdata/validator/idattribute.test
+++ b/vendor/plugins/HTML5lib/testdata/validator/idattribute.test
@@ -33,66 +33,63 @@
"fail-unless": "space-in-id"},
{"description": "invalid ID because of leading tab",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of trailing tab",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of tab in value",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of leading LF",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of trailing LF",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of LF in value",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of leading LT",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of trailing LT",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of LT in value",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of leading FF",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of trailing FF",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of FF in value",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of leading CR",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of trailing CR",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "invalid ID because of CR in value",
-"input": "",
+"input": "",
"fail-unless": "space-in-id"},
{"description": "duplicate ID values",
@@ -115,4 +112,4 @@ b'>",
"input": "",
"fail-if": "duplicate-id"}
-]}
\ No newline at end of file
+]}
diff --git a/vendor/plugins/HTML5lib/testdata/validator/irrelevantattribute.test b/vendor/plugins/HTML5lib/testdata/validator/irrelevantattribute.test
new file mode 100755
index 00000000..fa406130
--- /dev/null
+++ b/vendor/plugins/HTML5lib/testdata/validator/irrelevantattribute.test
@@ -0,0 +1,63 @@
+{"tests": [
+
+{"description": "valid irrelevant attribute value 'irrelevant'",
+"input": "",
+"fail-if": "invalid-attribute-value"},
+
+{"description": "valid irrelevant attribute value ''",
+"input": "",
+"fail-if": "invalid-attribute-value"},
+
+{"description": "invalid irrelevant attribute value due to uppercase",
+"input": "",
+"fail-unless": "invalid-boolean-value"},
+
+{"description": "invalid irrelevant attribute value due to mixed case",
+"input": "",
+"fail-unless": "invalid-boolean-value"},
+
+{"description": "invalid irrelevant attribute value due to leading space",
+"input": "",
+"fail-unless": "invalid-boolean-value"},
+
+{"description": "invalid irrelevant attribute value due to trailing space",
+"input": "",
+"fail-unless": "invalid-boolean-value"},
+
+{"description": "invalid irrelevant attribute value 'foo'",
+"input": "",
+"fail-unless": "invalid-boolean-value"},
+
+{"description": "invalid irrelevant attribute value '0'",
+"input": "",
+"fail-unless": "invalid-boolean-value"},
+
+{"description": "invalid irrelevant attribute value '1'",
+"input": "",
+"fail-unless": "invalid-boolean-value"},
+
+{"description": "invalid irrelevant attribute value 'yes'",
+"input": "",
+"fail-unless": "invalid-boolean-value"},
+
+{"description": "invalid irrelevant attribute value 'no'",
+"input": "",
+"fail-unless": "invalid-boolean-value"},
+
+{"description": "invalid irrelevant attribute value 'true'",
+"input": "",
+"fail-unless": "invalid-boolean-value"},
+
+{"description": "invalid irrelevant attribute value 'false'",
+"input": "",
+"fail-unless": "invalid-boolean-value"},
+
+{"description": "invalid irrelevant attribute value 'auto'",
+"input": "",
+"fail-unless": "invalid-boolean-value"},
+
+{"description": "invalid irrelevant attribute value 'inherit'",
+"input": "",
+"fail-unless": "invalid-boolean-value"}
+
+]}
\ No newline at end of file
diff --git a/vendor/plugins/HTML5lib/testdata/validator/langattribute.test b/vendor/plugins/HTML5lib/testdata/validator/langattribute.test
new file mode 100755
index 00000000..6c831a17
--- /dev/null
+++ b/vendor/plugins/HTML5lib/testdata/validator/langattribute.test
@@ -0,0 +1,5579 @@
+{"tests": [
+
+{"description": "valid lang attribute 'roh'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'gv'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'gu'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'scn'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'rom'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'ron'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'alg'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'oss'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'ale'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'alb'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'sco'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'scc'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'mni'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'gd'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'per'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'ga'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'nwc'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'osa'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'gn'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'alt'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'gl'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'scr'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'mwr'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'ty'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'tw'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'tt'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'tr'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'ts'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'tn'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'to'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'tl'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'tk'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'th'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'ti'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'ven'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'tg'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'te'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'uga'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'ta'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'fas'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'fat'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'fan'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'fao'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'got'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'sme'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'din'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'hye'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'guj'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'cmc'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'srd'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'mdr'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'ml'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'div'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'zh'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'tem'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'xho'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'mno'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'roa'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'za'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'deu'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'mk'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'nbl'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'zu'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'ter'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'tet'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'mnc'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'sun'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'abk'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'suk'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'kur'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'kum'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'slo'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'sus'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'new'",
+"input": "",
+"fail-if": "invalid-lang-code"},
+
+{"description": "valid lang attribute 'kua'",
+"input": "