[inserttext.html]
  type: testharness
  [[["inserttext",""\]\] "foo[bar\]baz": execCommand("inserttext", false, "") return value]
    expected: FAIL

  [[["inserttext",""\]\] "foo[bar\]baz" compare innerHTML]
    expected: FAIL

  [[["inserttext","\\t"\]\] "foo[\]bar" compare innerHTML]
    expected: FAIL

  [[["defaultparagraphseparator","div"\],["inserttext","\\n"\]\] "foo[\]bar": execCommand("defaultparagraphseparator", false, "div") return value]
    expected: FAIL

  [[["defaultparagraphseparator","div"\],["inserttext","\\n"\]\] "foo[\]bar" compare innerHTML]
    expected: FAIL

  [[["defaultparagraphseparator","div"\],["inserttext","\\n"\]\] "foo[\]bar" queryCommandValue("defaultparagraphseparator") before]
    expected: FAIL

  [[["defaultparagraphseparator","div"\],["inserttext","\\n"\]\] "foo[\]bar" queryCommandValue("defaultparagraphseparator") after]
    expected: FAIL

  [[["defaultparagraphseparator","p"\],["inserttext","\\n"\]\] "foo[\]bar": execCommand("defaultparagraphseparator", false, "p") return value]
    expected: FAIL

  [[["defaultparagraphseparator","p"\],["inserttext","\\n"\]\] "foo[\]bar" compare innerHTML]
    expected: FAIL

  [[["defaultparagraphseparator","p"\],["inserttext","\\n"\]\] "foo[\]bar" queryCommandValue("defaultparagraphseparator") before]
    expected: FAIL

  [[["defaultparagraphseparator","p"\],["inserttext","\\n"\]\] "foo[\]bar" queryCommandValue("defaultparagraphseparator") after]
    expected: FAIL

  [[["defaultparagraphseparator","div"\],["inserttext","abc\\ndef"\]\] "foo[\]bar": execCommand("defaultparagraphseparator", false, "div") return value]
    expected: FAIL

  [[["defaultparagraphseparator","div"\],["inserttext","abc\\ndef"\]\] "foo[\]bar" compare innerHTML]
    expected: FAIL

  [[["defaultparagraphseparator","div"\],["inserttext","abc\\ndef"\]\] "foo[\]bar" queryCommandValue("defaultparagraphseparator") before]
    expected: FAIL

  [[["defaultparagraphseparator","div"\],["inserttext","abc\\ndef"\]\] "foo[\]bar" queryCommandValue("defaultparagraphseparator") after]
    expected: FAIL

  [[["defaultparagraphseparator","p"\],["inserttext","abc\\ndef"\]\] "foo[\]bar": execCommand("defaultparagraphseparator", false, "p") return value]
    expected: FAIL

  [[["defaultparagraphseparator","p"\],["inserttext","abc\\ndef"\]\] "foo[\]bar" compare innerHTML]
    expected: FAIL

  [[["defaultparagraphseparator","p"\],["inserttext","abc\\ndef"\]\] "foo[\]bar" queryCommandValue("defaultparagraphseparator") before]
    expected: FAIL

  [[["defaultparagraphseparator","p"\],["inserttext","abc\\ndef"\]\] "foo[\]bar" queryCommandValue("defaultparagraphseparator") after]
    expected: FAIL

  [[["inserttext"," "\]\] "foo[\] &nbsp;bar" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "foo&nbsp; [\]bar" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "foo&nbsp;&nbsp;[\]bar" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "foo[\]&nbsp;&nbsp;bar" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "foo [\]&nbsp;        bar" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "foo  [\]bar" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "foo[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "foo{}" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "foo&nbsp;[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "foo&nbsp;{}" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "foo&nbsp;&nbsp;[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "foo&nbsp;&nbsp;{}" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "foo[\] " compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] " foo   [\]   " compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] " [\]foo" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "   [\]   foo " compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "<span> </span>[\]foo" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] " <span> </span>[\]foo" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "{}<br>" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "<p>{}<br>" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "<p>foo[\]<p>bar" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "<p>foo&nbsp;[\]<p>bar" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "<p>foo[\]<p>&nbsp;bar" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "<div style=white-space:pre-line>foo[\]</div>" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "<div style=white-space:pre-line>foo&nbsp;[\]</div>" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "<div style=white-space:pre-line> foo   [\]   </div>" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "<div style=white-space:nowrap>foo[\]</div>" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "<div style=white-space:nowrap>foo&nbsp;[\]</div>" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "<div style=white-space:nowrap> foo   [\]   </div>" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "http://a[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "ftp://a[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "quasit://a[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] ".x-++-.://a[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "(http://a)[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "&lt;http://a>[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "http://a![\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "!\\"#$%&amp;'()*+,-./:;&lt;=>?^_`|~http://a!\\"#$%&amp;'()*+,-./:;&lt;=>?^_`|~[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "http://a!\\"'(),-.:;&lt;>`[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "http://a#$%&amp;*+/=?^_|~[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "mailto:a[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "a@b[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "a@[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "@b[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "#@x[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "a@.[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "!\\"#$%&amp;'()*+,-./:;&lt;=>?^_`|~a@b!\\"#$%&amp;'()*+,-./:;&lt;=>?^_`|~[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "<b>a@b</b>{}" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "<b>a</b><i>@</i><u>b</u>{}" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "a@b<b>[\]c</b>" compare innerHTML]
    expected: FAIL

  [[["inserttext","\\t"\]\] "http://a[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext","\\f"\]\] "http://a[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext"," "\]\] "http://a[\]" compare innerHTML]
    expected: FAIL

  [[["inserttext","   "\]\] "foo[\]" compare innerHTML]
    expected: FAIL

  [[["defaultparagraphseparator","div"\],["inserttext","a"\]\] "<p>fo[o<p>b\]ar": execCommand("defaultparagraphseparator", false, "div") return value]
    expected: FAIL

  [[["defaultparagraphseparator","div"\],["inserttext","a"\]\] "<p>fo[o<p>b\]ar" queryCommandValue("defaultparagraphseparator") before]
    expected: FAIL

  [[["defaultparagraphseparator","div"\],["inserttext","a"\]\] "<p>fo[o<p>b\]ar" queryCommandValue("defaultparagraphseparator") after]
    expected: FAIL

  [[["defaultparagraphseparator","p"\],["inserttext","a"\]\] "<p>fo[o<p>b\]ar": execCommand("defaultparagraphseparator", false, "p") return value]
    expected: FAIL

  [[["defaultparagraphseparator","p"\],["inserttext","a"\]\] "<p>fo[o<p>b\]ar" queryCommandValue("defaultparagraphseparator") before]
    expected: FAIL

  [[["defaultparagraphseparator","p"\],["inserttext","a"\]\] "<p>fo[o<p>b\]ar" queryCommandValue("defaultparagraphseparator") after]
    expected: FAIL

  [[["defaultparagraphseparator","div"\],["inserttext","a"\]\] "<p>fo[o<p>bar<p>b\]az": execCommand("defaultparagraphseparator", false, "div") return value]
    expected: FAIL

  [[["defaultparagraphseparator","div"\],["inserttext","a"\]\] "<p>fo[o<p>bar<p>b\]az" queryCommandValue("defaultparagraphseparator") before]
    expected: FAIL

  [[["defaultparagraphseparator","div"\],["inserttext","a"\]\] "<p>fo[o<p>bar<p>b\]az" queryCommandValue("defaultparagraphseparator") after]
    expected: FAIL

  [[["defaultparagraphseparator","p"\],["inserttext","a"\]\] "<p>fo[o<p>bar<p>b\]az": execCommand("defaultparagraphseparator", false, "p") return value]
    expected: FAIL

  [[["defaultparagraphseparator","p"\],["inserttext","a"\]\] "<p>fo[o<p>bar<p>b\]az" queryCommandValue("defaultparagraphseparator") before]
    expected: FAIL

  [[["defaultparagraphseparator","p"\],["inserttext","a"\]\] "<p>fo[o<p>bar<p>b\]az" queryCommandValue("defaultparagraphseparator") after]
    expected: FAIL

  [[["inserttext","a"\]\] "{}<br>" compare innerHTML]
    expected: FAIL

  [[["inserttext","a"\]\] "<p>{}<br>" compare innerHTML]
    expected: FAIL

  [[["inserttext","a"\]\] "<p><span>{}<br></span>" compare innerHTML]
    expected: FAIL

  [[["inserttext","a"\]\] "<p>foo{<span style=color:#aBcDeF>bar</span>}baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "<p>[foo<span style=color:#aBcDeF>bar\]</span>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "<p>[foo<span style=color:#aBcDeF>bar\]</span>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "<p>{foo<span style=color:#aBcDeF>bar}</span>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "<p>{foo<span style=color:#aBcDeF>bar}</span>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "<p>foo<span style=color:#aBcDeF>[bar</span><span style=color:#fEdCbA>baz\]</span>quz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "<p>foo<span style=color:#aBcDeF>[bar</span><span style=color:#fEdCbA>baz\]</span>quz" compare innerHTML]
    expected: FAIL

  [[["inserttext","a"\]\] "foo<font color=brown><a href=http://www.google.com>[bar\]</a></font>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<b>bar\]</b>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<b>bar\]</b>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<i>bar\]</i>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<i>bar\]</i>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<s>bar\]</s>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<s>bar\]</s>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<sub>bar\]</sub>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<sub>bar\]</sub>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<sup>bar\]</sup>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<sup>bar\]</sup>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<u>bar\]</u>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<u>bar\]</u>baz" compare innerHTML]
    expected: FAIL

  [[["inserttext","a"\]\] "[foo<a href=http://www.google.com>bar\]</a>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<font face=sans-serif>bar\]</font>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<font face=sans-serif>bar\]</font>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<font size=4>bar\]</font>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<font size=4>bar\]</font>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<font color=#0000FF>bar\]</font>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<font color=#0000FF>bar\]</font>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<span style=background-color:#00FFFF>bar\]</span>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<span style=background-color:#00FFFF>bar\]</span>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<a href=http://www.google.com><font color=blue>bar\]</font></a>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<a href=http://www.google.com><font color=blue>bar\]</font></a>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<font color=blue><a href=http://www.google.com>bar\]</a></font>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<font color=blue><a href=http://www.google.com>bar\]</a></font>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<a href=http://www.google.com><font color=brown>bar\]</font></a>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<a href=http://www.google.com><font color=brown>bar\]</font></a>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<font color=brown><a href=http://www.google.com>bar\]</a></font>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<font color=brown><a href=http://www.google.com>bar\]</a></font>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<a href=http://www.google.com><font color=black>bar\]</font></a>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<a href=http://www.google.com><font color=black>bar\]</font></a>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<a href=http://www.google.com><u>bar\]</u></a>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<a href=http://www.google.com><u>bar\]</u></a>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<u><a href=http://www.google.com>bar\]</a></u>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<u><a href=http://www.google.com>bar\]</a></u>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<sub><font size=2>bar\]</font></sub>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<sub><font size=2>bar\]</font></sub>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<font size=2><sub>bar\]</sub></font>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<font size=2><sub>bar\]</sub></font>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<sub><font size=3>bar\]</font></sub>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<sub><font size=3>bar\]</font></sub>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","true"\],["inserttext","a"\]\] "[foo<font size=3><sub>bar\]</sub></font>baz" compare innerHTML]
    expected: FAIL

  [[["stylewithcss","false"\],["inserttext","a"\]\] "[foo<font size=3><sub>bar\]</sub></font>baz" compare innerHTML]
    expected: FAIL

