<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[181525] trunk</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/181525">181525</a></dd>
<dt>Author</dt> <dd>benjamin@webkit.org</dd>
<dt>Date</dt> <dd>2015-03-15 23:51:44 -0700 (Sun, 15 Mar 2015)</dd>
</dl>

<h3>Log Message</h3>
<pre>CSS: fix the case-insensitive matching of the attribute selectors Begin, End and Hyphen
https://bugs.webkit.org/show_bug.cgi?id=142715

Reviewed by Brent Fulgham.

Source/WebCore:

Fix attribute matching with:
-Begin: [a^=b].
-End: [a$=b].
-Hyphen: [a|=b].

Tests: fast/selectors/attribute-endswith-value-matching-is-ascii-case-insensitive.html
       fast/selectors/attribute-hyphen-value-matching-is-ascii-case-insensitive.html
       fast/selectors/attribute-startswith-value-matching-is-ascii-case-insensitive.html

* css/SelectorChecker.cpp:
(WebCore::attributeValueMatches):
I forgot to change CSSSelector::Exact in my last patch.
The tests could not catch that since we use the CSS JIT almost everywhere.

* cssjit/SelectorCompiler.cpp:
(WebCore::SelectorCompiler::attributeValueBeginsWith):
(WebCore::SelectorCompiler::attributeValueEndsWith):
(WebCore::SelectorCompiler::attributeValueMatchHyphenRule):

Source/WTF:

Add the necessary infrastructure to test startsWith() and endsWith() with
ASCII case-insentive comparisons.

* wtf/text/AtomicString.h:
(WTF::AtomicString::startsWith):
(WTF::AtomicString::startsWithIgnoringASCIICase):
(WTF::AtomicString::endsWith):
(WTF::AtomicString::endsWithIgnoringASCIICase):

* wtf/text/StringCommon.h:
(WTF::loadUnaligned):
(WTF::equal):
I moved the low level equal() code from StringImpl to StringCommon
since it is used by both StringImpl and StringView.

(WTF::equalCommon):
(WTF::equalIgnoringASCIICaseCommon):
Ideally we should drop the &quot;Common&quot; part of the name but StringView
wants this inline for some reason. I prefered keeping the current behavior
since I don't know how StringView's matching performance was evaluated.

(WTF::startsWith):
(WTF::startsWithIgnoringASCIICase):
(WTF::endsWith):
(WTF::endsWithIgnoringASCIICase):
Make all that code shared between StringView and Stringimpl.

* wtf/text/StringImpl.cpp:
(WTF::StringImpl::startsWith):
(WTF::StringImpl::startsWithIgnoringASCIICase):
(WTF::StringImpl::endsWith):
(WTF::StringImpl::endsWithIgnoringASCIICase):
(WTF::equal):
(WTF::stringImplContentEqual): Deleted.
* wtf/text/StringImpl.h:
(WTF::loadUnaligned): Deleted.
(WTF::equal): Deleted.

* wtf/text/StringView.cpp:
(WTF::StringView::startsWith):
(WTF::StringView::startsWithIgnoringASCIICase):
(WTF::StringView::endsWith):
(WTF::StringView::endsWithIgnoringASCIICase):
* wtf/text/StringView.h:
Since those are new, we can safely make them out-of-line and
evaluate the inlining impact as needed.

* wtf/text/WTFString.h:
(WTF::String::startsWithIgnoringASCIICase):
(WTF::String::endsWith):
(WTF::String::endsWithIgnoringASCIICase):

Tools:

* TestWebKitAPI/Tests/WTF/StringImpl.cpp:
(TestWebKitAPI::TEST):

LayoutTests:

* fast/selectors/attribute-endswith-value-matching-is-ascii-case-insensitive-expected.txt: Added.
* fast/selectors/attribute-endswith-value-matching-is-ascii-case-insensitive.html: Added.
* fast/selectors/attribute-hyphen-value-matching-is-ascii-case-insensitive-expected.txt: Added.
* fast/selectors/attribute-hyphen-value-matching-is-ascii-case-insensitive.html: Added.
* fast/selectors/attribute-startswith-value-matching-is-ascii-case-insensitive-expected.txt: Added.
* fast/selectors/attribute-startswith-value-matching-is-ascii-case-insensitive.html: Added.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsChangeLog">trunk/LayoutTests/ChangeLog</a></li>
<li><a href="#trunkSourceWTFChangeLog">trunk/Source/WTF/ChangeLog</a></li>
<li><a href="#trunkSourceWTFwtftextAtomicStringh">trunk/Source/WTF/wtf/text/AtomicString.h</a></li>
<li><a href="#trunkSourceWTFwtftextStringCommonh">trunk/Source/WTF/wtf/text/StringCommon.h</a></li>
<li><a href="#trunkSourceWTFwtftextStringImplcpp">trunk/Source/WTF/wtf/text/StringImpl.cpp</a></li>
<li><a href="#trunkSourceWTFwtftextStringImplh">trunk/Source/WTF/wtf/text/StringImpl.h</a></li>
<li><a href="#trunkSourceWTFwtftextStringViewcpp">trunk/Source/WTF/wtf/text/StringView.cpp</a></li>
<li><a href="#trunkSourceWTFwtftextStringViewh">trunk/Source/WTF/wtf/text/StringView.h</a></li>
<li><a href="#trunkSourceWTFwtftextWTFStringh">trunk/Source/WTF/wtf/text/WTFString.h</a></li>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCorecssSelectorCheckercpp">trunk/Source/WebCore/css/SelectorChecker.cpp</a></li>
<li><a href="#trunkSourceWebCorecssjitSelectorCompilercpp">trunk/Source/WebCore/cssjit/SelectorCompiler.cpp</a></li>
<li><a href="#trunkToolsChangeLog">trunk/Tools/ChangeLog</a></li>
<li><a href="#trunkToolsTestWebKitAPITestsWTFStringImplcpp">trunk/Tools/TestWebKitAPI/Tests/WTF/StringImpl.cpp</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsfastselectorsattributeendswithvaluematchingisasciicaseinsensitiveexpectedtxt">trunk/LayoutTests/fast/selectors/attribute-endswith-value-matching-is-ascii-case-insensitive-expected.txt</a></li>
<li><a href="#trunkLayoutTestsfastselectorsattributeendswithvaluematchingisasciicaseinsensitivehtml">trunk/LayoutTests/fast/selectors/attribute-endswith-value-matching-is-ascii-case-insensitive.html</a></li>
<li><a href="#trunkLayoutTestsfastselectorsattributehyphenvaluematchingisasciicaseinsensitiveexpectedtxt">trunk/LayoutTests/fast/selectors/attribute-hyphen-value-matching-is-ascii-case-insensitive-expected.txt</a></li>
<li><a href="#trunkLayoutTestsfastselectorsattributehyphenvaluematchingisasciicaseinsensitivehtml">trunk/LayoutTests/fast/selectors/attribute-hyphen-value-matching-is-ascii-case-insensitive.html</a></li>
<li><a href="#trunkLayoutTestsfastselectorsattributestartswithvaluematchingisasciicaseinsensitiveexpectedtxt">trunk/LayoutTests/fast/selectors/attribute-startswith-value-matching-is-ascii-case-insensitive-expected.txt</a></li>
<li><a href="#trunkLayoutTestsfastselectorsattributestartswithvaluematchingisasciicaseinsensitivehtml">trunk/LayoutTests/fast/selectors/attribute-startswith-value-matching-is-ascii-case-insensitive.html</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkLayoutTestsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/ChangeLog (181524 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/ChangeLog        2015-03-16 06:28:46 UTC (rev 181524)
+++ trunk/LayoutTests/ChangeLog        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -1,3 +1,17 @@
</span><ins>+2015-03-15  Benjamin Poulain  &lt;benjamin@webkit.org&gt;
+
+        CSS: fix the case-insensitive matching of the attribute selectors Begin, End and Hyphen
+        https://bugs.webkit.org/show_bug.cgi?id=142715
+
+        Reviewed by Brent Fulgham.
+
+        * fast/selectors/attribute-endswith-value-matching-is-ascii-case-insensitive-expected.txt: Added.
+        * fast/selectors/attribute-endswith-value-matching-is-ascii-case-insensitive.html: Added.
+        * fast/selectors/attribute-hyphen-value-matching-is-ascii-case-insensitive-expected.txt: Added.
+        * fast/selectors/attribute-hyphen-value-matching-is-ascii-case-insensitive.html: Added.
+        * fast/selectors/attribute-startswith-value-matching-is-ascii-case-insensitive-expected.txt: Added.
+        * fast/selectors/attribute-startswith-value-matching-is-ascii-case-insensitive.html: Added.
+
</ins><span class="cx"> 2015-03-15  Brent Fulgham  &lt;bfulgham@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Scroll snap points are not supported on iframe content
</span></span></pre></div>
<a id="trunkLayoutTestsfastselectorsattributeendswithvaluematchingisasciicaseinsensitiveexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/selectors/attribute-endswith-value-matching-is-ascii-case-insensitive-expected.txt (0 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/selectors/attribute-endswith-value-matching-is-ascii-case-insensitive-expected.txt                                (rev 0)
+++ trunk/LayoutTests/fast/selectors/attribute-endswith-value-matching-is-ascii-case-insensitive-expected.txt        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -0,0 +1,417 @@
</span><ins>+When matching attributes case insensitively, it should be ASCII case insensitive. This test verifies the behavior when matching the end of the values (e.g. [a$=&quot;b&quot;])
+
+On success, you will see a series of &quot;PASS&quot; messages, followed by &quot;TEST COMPLETE&quot;.
+
+
+Testing &quot;[data-attribute$=Web-É-Kit]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=Web-É-Kit]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute$=Web-É-Kit]')[0].id is &quot;target1&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute$=É-Kit]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=É-Kit]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute$=É-Kit]')[0].id is &quot;target1&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute$=web-É-kit]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=web-É-kit]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute$=web-É-kit]')[0].id is &quot;target2&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute$=É-kit]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=É-kit]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute$=É-kit]')[0].id is &quot;target2&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute$=WEB-É-KIT]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=WEB-É-KIT]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute$=WEB-É-KIT]')[0].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute$=É-KIT]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=É-KIT]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute$=É-KIT]')[0].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute$=Web-é-Kit]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=Web-é-Kit]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute$=Web-é-Kit]')[0].id is &quot;target4&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute$=é-Kit]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=é-Kit]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute$=é-Kit]')[0].id is &quot;target4&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute$=web-é-kit]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=web-é-kit]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute$=web-é-kit]')[0].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[data-attribute$=é-kit]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=é-kit]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute$=é-kit]')[0].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[data-attribute$=Web-É-Kit i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=Web-É-Kit i]').length is 3
+PASS document.querySelectorAll('#test-root [data-attribute$=Web-É-Kit i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=Web-É-Kit i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=Web-É-Kit i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute$=É-Kit i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=É-Kit i]').length is 3
+PASS document.querySelectorAll('#test-root [data-attribute$=É-Kit i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=É-Kit i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=É-Kit i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute$=web-É-kit i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=web-É-kit i]').length is 3
+PASS document.querySelectorAll('#test-root [data-attribute$=web-É-kit i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=web-É-kit i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=web-É-kit i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute$=É-kit i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=É-kit i]').length is 3
+PASS document.querySelectorAll('#test-root [data-attribute$=É-kit i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=É-kit i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=É-kit i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute$=WEB-É-KIT i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=WEB-É-KIT i]').length is 3
+PASS document.querySelectorAll('#test-root [data-attribute$=WEB-É-KIT i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=WEB-É-KIT i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=WEB-É-KIT i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute$=É-KIT i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=É-KIT i]').length is 3
+PASS document.querySelectorAll('#test-root [data-attribute$=É-KIT i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=É-KIT i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=É-KIT i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute$=Web-é-Kit i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=Web-é-Kit i]').length is 2
+PASS document.querySelectorAll('#test-root [data-attribute$=Web-é-Kit i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=Web-é-Kit i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[data-attribute$=é-Kit i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=é-Kit i]').length is 2
+PASS document.querySelectorAll('#test-root [data-attribute$=é-Kit i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=é-Kit i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[data-attribute$=web-é-kit i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=web-é-kit i]').length is 2
+PASS document.querySelectorAll('#test-root [data-attribute$=web-é-kit i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=web-é-kit i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[data-attribute$=é-kit i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=é-kit i]').length is 2
+PASS document.querySelectorAll('#test-root [data-attribute$=é-kit i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [data-attribute$=é-kit i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple$=WEB-é-KIT]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=WEB-é-KIT]').length is 3
+PASS document.querySelectorAll('#test-root [multiple$=WEB-é-KIT]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple$=WEB-é-KIT]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple$=WEB-é-KIT]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple$=é-KIT]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=é-KIT]').length is 3
+PASS document.querySelectorAll('#test-root [multiple$=é-KIT]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple$=é-KIT]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple$=é-KIT]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple$=Web-é-Kit]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=Web-é-Kit]').length is 3
+PASS document.querySelectorAll('#test-root [multiple$=Web-é-Kit]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple$=Web-é-Kit]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple$=Web-é-Kit]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple$=é-Kit]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=é-Kit]').length is 3
+PASS document.querySelectorAll('#test-root [multiple$=é-Kit]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple$=é-Kit]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple$=é-Kit]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple$=Web-é-kit]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=Web-é-kit]').length is 3
+PASS document.querySelectorAll('#test-root [multiple$=Web-é-kit]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple$=Web-é-kit]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple$=Web-é-kit]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple$=é-kit]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=é-kit]').length is 3
+PASS document.querySelectorAll('#test-root [multiple$=é-kit]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple$=é-kit]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple$=é-kit]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple$=web-É-kit]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=web-É-kit]').length is 2
+PASS document.querySelectorAll('#test-root [multiple$=web-É-kit]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple$=web-É-kit]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple$=É-kit]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=É-kit]').length is 2
+PASS document.querySelectorAll('#test-root [multiple$=É-kit]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple$=É-kit]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple$=web-É-Kit]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=web-É-Kit]').length is 2
+PASS document.querySelectorAll('#test-root [multiple$=web-É-Kit]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple$=web-É-Kit]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple$=É-Kit]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=É-Kit]').length is 2
+PASS document.querySelectorAll('#test-root [multiple$=É-Kit]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple$=É-Kit]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple$=WEB-é-KIT i]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=WEB-é-KIT i]').length is 3
+PASS document.querySelectorAll('#test-root [multiple$=WEB-é-KIT i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple$=WEB-é-KIT i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple$=WEB-é-KIT i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple$=é-KIT i]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=é-KIT i]').length is 3
+PASS document.querySelectorAll('#test-root [multiple$=é-KIT i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple$=é-KIT i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple$=é-KIT i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple$=Web-é-Kit i]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=Web-é-Kit i]').length is 3
+PASS document.querySelectorAll('#test-root [multiple$=Web-é-Kit i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple$=Web-é-Kit i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple$=Web-é-Kit i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple$=é-Kit i]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=é-Kit i]').length is 3
+PASS document.querySelectorAll('#test-root [multiple$=é-Kit i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple$=é-Kit i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple$=é-Kit i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple$=Web-é-kit i]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=Web-é-kit i]').length is 3
+PASS document.querySelectorAll('#test-root [multiple$=Web-é-kit i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple$=Web-é-kit i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple$=Web-é-kit i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple$=é-kit i]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=é-kit i]').length is 3
+PASS document.querySelectorAll('#test-root [multiple$=é-kit i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple$=é-kit i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple$=é-kit i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple$=web-É-kit i]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=web-É-kit i]').length is 2
+PASS document.querySelectorAll('#test-root [multiple$=web-É-kit i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple$=web-É-kit i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple$=É-kit i]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=É-kit i]').length is 2
+PASS document.querySelectorAll('#test-root [multiple$=É-kit i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple$=É-kit i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple$=web-É-Kit i]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=web-É-Kit i]').length is 2
+PASS document.querySelectorAll('#test-root [multiple$=web-É-Kit i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple$=web-É-Kit i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple$=É-Kit i]&quot;
+PASS document.querySelectorAll('#test-root [multiple$=É-Kit i]').length is 2
+PASS document.querySelectorAll('#test-root [multiple$=É-Kit i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple$=É-Kit i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+PASS successfullyParsed is true
+
+TEST COMPLETE
+
</ins></span></pre></div>
<a id="trunkLayoutTestsfastselectorsattributeendswithvaluematchingisasciicaseinsensitivehtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/selectors/attribute-endswith-value-matching-is-ascii-case-insensitive.html (0 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/selectors/attribute-endswith-value-matching-is-ascii-case-insensitive.html                                (rev 0)
+++ trunk/LayoutTests/fast/selectors/attribute-endswith-value-matching-is-ascii-case-insensitive.html        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -0,0 +1,122 @@
</span><ins>+&lt;!doctype html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;meta charset=&quot;utf-8&quot;&gt;
+&lt;script src=&quot;../../resources/js-test-pre.js&quot;&gt;&lt;/script&gt;
+&lt;style&gt;
+#test-root * {
+    background-color: red;
+}
+&lt;/style&gt;
+&lt;style id=&quot;style&quot;&gt;
+&lt;/style&gt;
+&lt;/head&gt;
+&lt;body&gt;
+    &lt;div style=&quot;display:none&quot; id=&quot;test-root&quot;&gt;
+        &lt;div data-attribute=&quot;Web-É-Kit&quot; multiple=&quot;WEB-é-KIT&quot; id=&quot;target1&quot;&gt;&lt;/div&gt;
+        &lt;div data-attribute=&quot;web-É-kit&quot; multiple=&quot;Web-é-Kit&quot; id=&quot;target2&quot;&gt;&lt;/div&gt;
+        &lt;div data-attribute=&quot;WEB-É-KIT&quot; multiple=&quot;Web-é-kit&quot; id=&quot;target3&quot;&gt;&lt;/div&gt;
+        &lt;div data-attribute=&quot;Web-é-Kit&quot; multiple=&quot;web-É-kit&quot; id=&quot;target4&quot;&gt;&lt;/div&gt;
+        &lt;div data-attribute=&quot;web-é-kit&quot; multiple=&quot;web-É-Kit&quot; id=&quot;target5&quot;&gt;&lt;/div&gt;
+    &lt;/div&gt;
+&lt;/body&gt;
+&lt;script&gt;
+description('When matching attributes case insensitively, it should be ASCII case insensitive. This test verifies the behavior when matching the end of the values (e.g. [a$=&quot;b&quot;])');
+
+function testQuerySelector(selector, expectedIds) {
+    shouldBe(&quot;document.querySelectorAll('&quot; + selector + &quot;').length&quot;, '' + expectedIds.length);
+    for (var i = 0; i &lt; expectedIds.length; ++i)
+        shouldBeEqualToString(&quot;document.querySelectorAll('&quot; + selector + &quot;')[&quot; + i + &quot;].id&quot;, 'target' + expectedIds[i]);
+}
+
+function testStyling(selector, expectedIds) {
+    var stylingElement = document.getElementById(&quot;style&quot;);
+    stylingElement.innerHTML = '' + selector + ' { background-color: rgb(10, 100, 200); }';
+
+    var allTestCases = document.querySelectorAll(&quot;#test-root *&quot;);
+    for (var i = 0; i &lt; allTestCases.length; ++i) {
+        var expectMatch = expectedIds.indexOf(parseInt(allTestCases[i].id.replace('target', ''))) &gt;= 0;
+        shouldBeEqualToString('getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[' + i + ']).backgroundColor', expectMatch ? 'rgb(10, 100, 200)' : 'rgb(255, 0, 0)');
+    }
+
+    stylingElement.innerHTML = '';
+}
+
+function testSelector(selector, expectedIds) {
+    debug(&quot;Testing \&quot;&quot; + selector + &quot;\&quot;&quot;);
+    testQuerySelector(&quot;#test-root &quot; + selector, expectedIds);
+    testStyling(&quot;#test-root &quot; + selector, expectedIds);
+    debug(&quot;&quot;);
+}
+
+var testCases = [
+    // Regular attribute matching is case sensitive.
+    ['[data-attribute$=Web-É-Kit]', [1]],
+    ['[data-attribute$=É-Kit]', [1]],
+
+    ['[data-attribute$=web-É-kit]', [2]],
+    ['[data-attribute$=É-kit]', [2]],
+
+    ['[data-attribute$=WEB-É-KIT]', [3]],
+    ['[data-attribute$=É-KIT]', [3]],
+
+    ['[data-attribute$=Web-é-Kit]', [4]],
+    ['[data-attribute$=é-Kit]', [4]],
+
+    ['[data-attribute$=web-é-kit]', [5]],
+    ['[data-attribute$=é-kit]', [5]],
+
+    // Same selectors with the case-insensitive flag.
+    ['[data-attribute$=Web-É-Kit i]', [1, 2, 3]],
+    ['[data-attribute$=É-Kit i]', [1, 2, 3]],
+
+    ['[data-attribute$=web-É-kit i]', [1, 2, 3]],
+    ['[data-attribute$=É-kit i]', [1, 2, 3]],
+
+    ['[data-attribute$=WEB-É-KIT i]', [1, 2, 3]],
+    ['[data-attribute$=É-KIT i]', [1, 2, 3]],
+
+    ['[data-attribute$=Web-é-Kit i]', [4, 5]],
+    ['[data-attribute$=é-Kit i]', [4, 5]],
+
+    ['[data-attribute$=web-é-kit i]', [4, 5]],
+    ['[data-attribute$=é-kit i]', [4, 5]],
+
+    // &quot;multiple&quot; is one of those weird legacy exception: it is always case insensitive in HTML.
+    ['[multiple$=WEB-é-KIT]', [1, 2, 3]],
+    ['[multiple$=é-KIT]', [1, 2, 3]],
+
+    ['[multiple$=Web-é-Kit]', [1, 2, 3]],
+    ['[multiple$=é-Kit]', [1, 2, 3]],
+
+    ['[multiple$=Web-é-kit]', [1, 2, 3]],
+    ['[multiple$=é-kit]', [1, 2, 3]],
+
+    ['[multiple$=web-É-kit]', [4, 5]],
+    ['[multiple$=É-kit]', [4, 5]],
+
+    ['[multiple$=web-É-Kit]', [4, 5]],
+    ['[multiple$=É-Kit]', [4, 5]],
+
+    ['[multiple$=WEB-é-KIT i]', [1, 2, 3]],
+    ['[multiple$=é-KIT i]', [1, 2, 3]],
+
+    ['[multiple$=Web-é-Kit i]', [1, 2, 3]],
+    ['[multiple$=é-Kit i]', [1, 2, 3]],
+
+    ['[multiple$=Web-é-kit i]', [1, 2, 3]],
+    ['[multiple$=é-kit i]', [1, 2, 3]],
+
+    ['[multiple$=web-É-kit i]', [4, 5]],
+    ['[multiple$=É-kit i]', [4, 5]],
+
+    ['[multiple$=web-É-Kit i]', [4, 5]],
+    ['[multiple$=É-Kit i]', [4, 5]],
+];
+
+for (var testCase of testCases) {
+    testSelector(testCase[0], testCase[1]);
+}
+&lt;/script&gt;
+&lt;script src=&quot;../../resources/js-test-post.js&quot;&gt;&lt;/script&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="trunkLayoutTestsfastselectorsattributehyphenvaluematchingisasciicaseinsensitiveexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/selectors/attribute-hyphen-value-matching-is-ascii-case-insensitive-expected.txt (0 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/selectors/attribute-hyphen-value-matching-is-ascii-case-insensitive-expected.txt                                (rev 0)
+++ trunk/LayoutTests/fast/selectors/attribute-hyphen-value-matching-is-ascii-case-insensitive-expected.txt        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -0,0 +1,349 @@
</span><ins>+When matching attributes case insensitively, it should be ASCII case insensitive. This test verifies the behavior when doing hyphen matching on the value (e.g. [a|=&quot;b&quot;])
+
+On success, you will see a series of &quot;PASS&quot; messages, followed by &quot;TEST COMPLETE&quot;.
+
+
+Testing &quot;[data-attribute|=Web-É-Kit]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=Web-É-Kit]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute|=Web-É-Kit]')[0].id is &quot;target1&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute|=Web-É]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=Web-É]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute|=Web-É]')[0].id is &quot;target1&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute|=web-É]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=web-É]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute|=web-É]')[0].id is &quot;target2&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute|=WEB-É-KIT]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=WEB-É-KIT]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute|=WEB-É-KIT]')[0].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute|=WEB-É]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=WEB-É]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute|=WEB-É]')[0].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute|=Web-é]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=Web-é]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute|=Web-é]')[0].id is &quot;target4&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute|=web-é-kit]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=web-é-kit]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute|=web-é-kit]')[0].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[data-attribute|=web-é]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=web-é]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute|=web-é]')[0].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[data-attribute|=Web-É-Kit i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=Web-É-Kit i]').length is 2
+PASS document.querySelectorAll('#test-root [data-attribute|=Web-É-Kit i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=Web-É-Kit i]')[1].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute|=Web-É i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=Web-É i]').length is 3
+PASS document.querySelectorAll('#test-root [data-attribute|=Web-É i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=Web-É i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=Web-É i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute|=web-É i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=web-É i]').length is 3
+PASS document.querySelectorAll('#test-root [data-attribute|=web-É i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=web-É i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=web-É i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute|=WEB-É i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=WEB-É i]').length is 3
+PASS document.querySelectorAll('#test-root [data-attribute|=WEB-É i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=WEB-É i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=WEB-É i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute|=Web-é i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=Web-é i]').length is 2
+PASS document.querySelectorAll('#test-root [data-attribute|=Web-é i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=Web-é i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[data-attribute|=web-é-kit i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=web-é-kit i]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute|=web-é-kit i]')[0].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[data-attribute|=web-é i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=web-é i]').length is 2
+PASS document.querySelectorAll('#test-root [data-attribute|=web-é i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [data-attribute|=web-é i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple|=WEB-é-KIT]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=WEB-é-KIT]').length is 1
+PASS document.querySelectorAll('#test-root [multiple|=WEB-é-KIT]')[0].id is &quot;target2&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple|=WEB-é]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=WEB-é]').length is 3
+PASS document.querySelectorAll('#test-root [multiple|=WEB-é]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple|=WEB-é]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple|=WEB-é]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple|=Web-é-Kit]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=Web-é-Kit]').length is 1
+PASS document.querySelectorAll('#test-root [multiple|=Web-é-Kit]')[0].id is &quot;target2&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple|=Web-é]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=Web-é]').length is 3
+PASS document.querySelectorAll('#test-root [multiple|=Web-é]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple|=Web-é]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple|=Web-é]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple|=Web-é-kit]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=Web-é-kit]').length is 1
+PASS document.querySelectorAll('#test-root [multiple|=Web-é-kit]')[0].id is &quot;target2&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple|=Web-é]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=Web-é]').length is 3
+PASS document.querySelectorAll('#test-root [multiple|=Web-é]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple|=Web-é]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple|=Web-é]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple|=web-É-kit]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=web-É-kit]').length is 1
+PASS document.querySelectorAll('#test-root [multiple|=web-É-kit]')[0].id is &quot;target4&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple|=web-É]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=web-É]').length is 2
+PASS document.querySelectorAll('#test-root [multiple|=web-É]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple|=web-É]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple|=web-É-Kit]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=web-É-Kit]').length is 1
+PASS document.querySelectorAll('#test-root [multiple|=web-É-Kit]')[0].id is &quot;target4&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple|=web-É]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=web-É]').length is 2
+PASS document.querySelectorAll('#test-root [multiple|=web-É]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple|=web-É]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple|=WEB-é-KIT i]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=WEB-é-KIT i]').length is 1
+PASS document.querySelectorAll('#test-root [multiple|=WEB-é-KIT i]')[0].id is &quot;target2&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple|=WEB-é i]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=WEB-é i]').length is 3
+PASS document.querySelectorAll('#test-root [multiple|=WEB-é i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple|=WEB-é i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple|=WEB-é i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple|=Web-é-Kit i]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=Web-é-Kit i]').length is 1
+PASS document.querySelectorAll('#test-root [multiple|=Web-é-Kit i]')[0].id is &quot;target2&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple|=Web-é i]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=Web-é i]').length is 3
+PASS document.querySelectorAll('#test-root [multiple|=Web-é i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple|=Web-é i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple|=Web-é i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple|=Web-é-kit i]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=Web-é-kit i]').length is 1
+PASS document.querySelectorAll('#test-root [multiple|=Web-é-kit i]')[0].id is &quot;target2&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple|=Web-é i]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=Web-é i]').length is 3
+PASS document.querySelectorAll('#test-root [multiple|=Web-é i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple|=Web-é i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple|=Web-é i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple|=web-É-kit i]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=web-É-kit i]').length is 1
+PASS document.querySelectorAll('#test-root [multiple|=web-É-kit i]')[0].id is &quot;target4&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple|=web-É i]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=web-É i]').length is 2
+PASS document.querySelectorAll('#test-root [multiple|=web-É i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple|=web-É i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple|=web-É-Kit i]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=web-É-Kit i]').length is 1
+PASS document.querySelectorAll('#test-root [multiple|=web-É-Kit i]')[0].id is &quot;target4&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple|=web-É i]&quot;
+PASS document.querySelectorAll('#test-root [multiple|=web-É i]').length is 2
+PASS document.querySelectorAll('#test-root [multiple|=web-É i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple|=web-É i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+PASS successfullyParsed is true
+
+TEST COMPLETE
+
</ins></span></pre></div>
<a id="trunkLayoutTestsfastselectorsattributehyphenvaluematchingisasciicaseinsensitivehtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/selectors/attribute-hyphen-value-matching-is-ascii-case-insensitive.html (0 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/selectors/attribute-hyphen-value-matching-is-ascii-case-insensitive.html                                (rev 0)
+++ trunk/LayoutTests/fast/selectors/attribute-hyphen-value-matching-is-ascii-case-insensitive.html        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -0,0 +1,117 @@
</span><ins>+&lt;!doctype html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;meta charset=&quot;utf-8&quot;&gt;
+&lt;script src=&quot;../../resources/js-test-pre.js&quot;&gt;&lt;/script&gt;
+&lt;style&gt;
+#test-root * {
+    background-color: red;
+}
+&lt;/style&gt;
+&lt;style id=&quot;style&quot;&gt;
+&lt;/style&gt;
+&lt;/head&gt;
+&lt;body&gt;
+    &lt;div style=&quot;display:none&quot; id=&quot;test-root&quot;&gt;
+        &lt;div data-attribute=&quot;Web-É-Kit&quot; multiple=&quot;WEB-é&quot; id=&quot;target1&quot;&gt;&lt;/div&gt;
+        &lt;div data-attribute=&quot;web-É&quot; multiple=&quot;Web-é-Kit&quot; id=&quot;target2&quot;&gt;&lt;/div&gt;
+        &lt;div data-attribute=&quot;WEB-É-KIT&quot; multiple=&quot;Web-é&quot; id=&quot;target3&quot;&gt;&lt;/div&gt;
+        &lt;div data-attribute=&quot;Web-é&quot; multiple=&quot;web-É-kit&quot; id=&quot;target4&quot;&gt;&lt;/div&gt;
+        &lt;div data-attribute=&quot;web-é-kit&quot; multiple=&quot;web-É&quot; id=&quot;target5&quot;&gt;&lt;/div&gt;
+    &lt;/div&gt;
+&lt;/body&gt;
+&lt;script&gt;
+description('When matching attributes case insensitively, it should be ASCII case insensitive. This test verifies the behavior when doing hyphen matching on the value (e.g. [a|=&quot;b&quot;])');
+
+function testQuerySelector(selector, expectedIds) {
+    shouldBe(&quot;document.querySelectorAll('&quot; + selector + &quot;').length&quot;, '' + expectedIds.length);
+    for (var i = 0; i &lt; expectedIds.length; ++i)
+        shouldBeEqualToString(&quot;document.querySelectorAll('&quot; + selector + &quot;')[&quot; + i + &quot;].id&quot;, 'target' + expectedIds[i]);
+}
+
+function testStyling(selector, expectedIds) {
+    var stylingElement = document.getElementById(&quot;style&quot;);
+    stylingElement.innerHTML = '' + selector + ' { background-color: rgb(10, 100, 200); }';
+
+    var allTestCases = document.querySelectorAll(&quot;#test-root *&quot;);
+    for (var i = 0; i &lt; allTestCases.length; ++i) {
+        var expectMatch = expectedIds.indexOf(parseInt(allTestCases[i].id.replace('target', ''))) &gt;= 0;
+        shouldBeEqualToString('getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[' + i + ']).backgroundColor', expectMatch ? 'rgb(10, 100, 200)' : 'rgb(255, 0, 0)');
+    }
+
+    stylingElement.innerHTML = '';
+}
+
+function testSelector(selector, expectedIds) {
+    debug(&quot;Testing \&quot;&quot; + selector + &quot;\&quot;&quot;);
+    testQuerySelector(&quot;#test-root &quot; + selector, expectedIds);
+    testStyling(&quot;#test-root &quot; + selector, expectedIds);
+    debug(&quot;&quot;);
+}
+
+var testCases = [
+    // Regular attribute matching is case sensitive.
+    ['[data-attribute|=Web-É-Kit]', [1]],
+    ['[data-attribute|=Web-É]', [1]],
+
+    ['[data-attribute|=web-É]', [2]],
+
+    ['[data-attribute|=WEB-É-KIT]', [3]],
+    ['[data-attribute|=WEB-É]', [3]],
+
+    ['[data-attribute|=Web-é]', [4]],
+
+    ['[data-attribute|=web-é-kit]', [5]],
+    ['[data-attribute|=web-é]', [5]],
+
+    // Same selectors with the case-insensitive flag.
+    ['[data-attribute|=Web-É-Kit i]', [1, 3]],
+    ['[data-attribute|=Web-É i]', [1, 2, 3]],
+
+    ['[data-attribute|=web-É i]', [1, 2, 3]],
+
+    ['[data-attribute|=WEB-É i]', [1, 2, 3]],
+
+    ['[data-attribute|=Web-é i]', [4, 5]],
+
+    ['[data-attribute|=web-é-kit i]', [5]],
+    ['[data-attribute|=web-é i]', [4, 5]],
+
+    // &quot;multiple&quot; is one of those weird legacy exception: it is always case insensitive in HTML.
+    ['[multiple|=WEB-é-KIT]', [2]],
+    ['[multiple|=WEB-é]', [1, 2, 3]],
+
+    ['[multiple|=Web-é-Kit]', [2]],
+    ['[multiple|=Web-é]', [1, 2, 3]],
+
+    ['[multiple|=Web-é-kit]', [2]],
+    ['[multiple|=Web-é]', [1, 2, 3]],
+
+    ['[multiple|=web-É-kit]', [4]],
+    ['[multiple|=web-É]', [4, 5]],
+
+    ['[multiple|=web-É-Kit]', [4]],
+    ['[multiple|=web-É]', [4, 5]],
+
+    ['[multiple|=WEB-é-KIT i]', [2]],
+    ['[multiple|=WEB-é i]', [1, 2, 3]],
+
+    ['[multiple|=Web-é-Kit i]', [2]],
+    ['[multiple|=Web-é i]', [1, 2, 3]],
+
+    ['[multiple|=Web-é-kit i]', [2]],
+    ['[multiple|=Web-é i]', [1, 2, 3]],
+
+    ['[multiple|=web-É-kit i]', [4]],
+    ['[multiple|=web-É i]', [4, 5]],
+
+    ['[multiple|=web-É-Kit i]', [4]],
+    ['[multiple|=web-É i]', [4, 5]],
+];
+
+for (var testCase of testCases) {
+    testSelector(testCase[0], testCase[1]);
+}
+&lt;/script&gt;
+&lt;script src=&quot;../../resources/js-test-post.js&quot;&gt;&lt;/script&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="trunkLayoutTestsfastselectorsattributestartswithvaluematchingisasciicaseinsensitiveexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/selectors/attribute-startswith-value-matching-is-ascii-case-insensitive-expected.txt (0 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/selectors/attribute-startswith-value-matching-is-ascii-case-insensitive-expected.txt                                (rev 0)
+++ trunk/LayoutTests/fast/selectors/attribute-startswith-value-matching-is-ascii-case-insensitive-expected.txt        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -0,0 +1,417 @@
</span><ins>+When matching attributes case insensitively, it should be ASCII case insensitive. This test verifies the behavior when matching the start of the values (e.g. [a^=&quot;b&quot;])
+
+On success, you will see a series of &quot;PASS&quot; messages, followed by &quot;TEST COMPLETE&quot;.
+
+
+Testing &quot;[data-attribute^=Web-É-Kit]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-É-Kit]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-É-Kit]')[0].id is &quot;target1&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute^=Web-É]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-É]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-É]')[0].id is &quot;target1&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute^=web-É-kit]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=web-É-kit]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute^=web-É-kit]')[0].id is &quot;target2&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute^=web-É]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=web-É]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute^=web-É]')[0].id is &quot;target2&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute^=WEB-É-KIT]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=WEB-É-KIT]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute^=WEB-É-KIT]')[0].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute^=WEB-É]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=WEB-É]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute^=WEB-É]')[0].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute^=Web-é-Kit]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-é-Kit]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-é-Kit]')[0].id is &quot;target4&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute^=Web-é]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-é]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-é]')[0].id is &quot;target4&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute^=web-é-kit]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=web-é-kit]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute^=web-é-kit]')[0].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[data-attribute^=web-é]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=web-é]').length is 1
+PASS document.querySelectorAll('#test-root [data-attribute^=web-é]')[0].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[data-attribute^=Web-É-Kit i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-É-Kit i]').length is 3
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-É-Kit i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-É-Kit i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-É-Kit i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute^=Web-É i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-É i]').length is 3
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-É i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-É i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-É i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute^=web-É-kit i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=web-É-kit i]').length is 3
+PASS document.querySelectorAll('#test-root [data-attribute^=web-É-kit i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=web-É-kit i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=web-É-kit i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute^=web-É i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=web-É i]').length is 3
+PASS document.querySelectorAll('#test-root [data-attribute^=web-É i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=web-É i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=web-É i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute^=WEB-É-KIT i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=WEB-É-KIT i]').length is 3
+PASS document.querySelectorAll('#test-root [data-attribute^=WEB-É-KIT i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=WEB-É-KIT i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=WEB-É-KIT i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute^=WEB-É i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=WEB-É i]').length is 3
+PASS document.querySelectorAll('#test-root [data-attribute^=WEB-É i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=WEB-É i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=WEB-É i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[data-attribute^=Web-é-Kit i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-é-Kit i]').length is 2
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-é-Kit i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-é-Kit i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[data-attribute^=Web-é i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-é i]').length is 2
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-é i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=Web-é i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[data-attribute^=web-é-kit i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=web-é-kit i]').length is 2
+PASS document.querySelectorAll('#test-root [data-attribute^=web-é-kit i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=web-é-kit i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[data-attribute^=web-é i]&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=web-é i]').length is 2
+PASS document.querySelectorAll('#test-root [data-attribute^=web-é i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [data-attribute^=web-é i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple^=WEB-é-KIT]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=WEB-é-KIT]').length is 3
+PASS document.querySelectorAll('#test-root [multiple^=WEB-é-KIT]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple^=WEB-é-KIT]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple^=WEB-é-KIT]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple^=WEB-é]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=WEB-é]').length is 3
+PASS document.querySelectorAll('#test-root [multiple^=WEB-é]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple^=WEB-é]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple^=WEB-é]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple^=Web-é-Kit]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é-Kit]').length is 3
+PASS document.querySelectorAll('#test-root [multiple^=Web-é-Kit]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é-Kit]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é-Kit]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple^=Web-é]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é]').length is 3
+PASS document.querySelectorAll('#test-root [multiple^=Web-é]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple^=Web-é-kit]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é-kit]').length is 3
+PASS document.querySelectorAll('#test-root [multiple^=Web-é-kit]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é-kit]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é-kit]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple^=Web-é]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é]').length is 3
+PASS document.querySelectorAll('#test-root [multiple^=Web-é]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple^=web-É-kit]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=web-É-kit]').length is 2
+PASS document.querySelectorAll('#test-root [multiple^=web-É-kit]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple^=web-É-kit]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple^=web-É]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=web-É]').length is 2
+PASS document.querySelectorAll('#test-root [multiple^=web-É]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple^=web-É]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple^=web-É-Kit]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=web-É-Kit]').length is 2
+PASS document.querySelectorAll('#test-root [multiple^=web-É-Kit]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple^=web-É-Kit]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple^=web-É]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=web-É]').length is 2
+PASS document.querySelectorAll('#test-root [multiple^=web-É]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple^=web-É]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple^=WEB-é-KIT i]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=WEB-é-KIT i]').length is 3
+PASS document.querySelectorAll('#test-root [multiple^=WEB-é-KIT i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple^=WEB-é-KIT i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple^=WEB-é-KIT i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple^=WEB-é i]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=WEB-é i]').length is 3
+PASS document.querySelectorAll('#test-root [multiple^=WEB-é i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple^=WEB-é i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple^=WEB-é i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple^=Web-é-Kit i]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é-Kit i]').length is 3
+PASS document.querySelectorAll('#test-root [multiple^=Web-é-Kit i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é-Kit i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é-Kit i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple^=Web-é i]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é i]').length is 3
+PASS document.querySelectorAll('#test-root [multiple^=Web-é i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple^=Web-é-kit i]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é-kit i]').length is 3
+PASS document.querySelectorAll('#test-root [multiple^=Web-é-kit i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é-kit i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é-kit i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple^=Web-é i]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é i]').length is 3
+PASS document.querySelectorAll('#test-root [multiple^=Web-é i]')[0].id is &quot;target1&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é i]')[1].id is &quot;target2&quot;
+PASS document.querySelectorAll('#test-root [multiple^=Web-é i]')[2].id is &quot;target3&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+
+Testing &quot;[multiple^=web-É-kit i]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=web-É-kit i]').length is 2
+PASS document.querySelectorAll('#test-root [multiple^=web-É-kit i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple^=web-É-kit i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple^=web-É i]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=web-É i]').length is 2
+PASS document.querySelectorAll('#test-root [multiple^=web-É i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple^=web-É i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple^=web-É-Kit i]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=web-É-Kit i]').length is 2
+PASS document.querySelectorAll('#test-root [multiple^=web-É-Kit i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple^=web-É-Kit i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+Testing &quot;[multiple^=web-É i]&quot;
+PASS document.querySelectorAll('#test-root [multiple^=web-É i]').length is 2
+PASS document.querySelectorAll('#test-root [multiple^=web-É i]')[0].id is &quot;target4&quot;
+PASS document.querySelectorAll('#test-root [multiple^=web-É i]')[1].id is &quot;target5&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[0]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[1]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[2]).backgroundColor is &quot;rgb(255, 0, 0)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[3]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+PASS getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[4]).backgroundColor is &quot;rgb(10, 100, 200)&quot;
+
+PASS successfullyParsed is true
+
+TEST COMPLETE
+
</ins></span></pre></div>
<a id="trunkLayoutTestsfastselectorsattributestartswithvaluematchingisasciicaseinsensitivehtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/selectors/attribute-startswith-value-matching-is-ascii-case-insensitive.html (0 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/selectors/attribute-startswith-value-matching-is-ascii-case-insensitive.html                                (rev 0)
+++ trunk/LayoutTests/fast/selectors/attribute-startswith-value-matching-is-ascii-case-insensitive.html        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -0,0 +1,122 @@
</span><ins>+&lt;!doctype html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;meta charset=&quot;utf-8&quot;&gt;
+&lt;script src=&quot;../../resources/js-test-pre.js&quot;&gt;&lt;/script&gt;
+&lt;style&gt;
+#test-root * {
+    background-color: red;
+}
+&lt;/style&gt;
+&lt;style id=&quot;style&quot;&gt;
+&lt;/style&gt;
+&lt;/head&gt;
+&lt;body&gt;
+    &lt;div style=&quot;display:none&quot; id=&quot;test-root&quot;&gt;
+        &lt;div data-attribute=&quot;Web-É-Kit&quot; multiple=&quot;WEB-é-KIT&quot; id=&quot;target1&quot;&gt;&lt;/div&gt;
+        &lt;div data-attribute=&quot;web-É-kit&quot; multiple=&quot;Web-é-Kit&quot; id=&quot;target2&quot;&gt;&lt;/div&gt;
+        &lt;div data-attribute=&quot;WEB-É-KIT&quot; multiple=&quot;Web-é-kit&quot; id=&quot;target3&quot;&gt;&lt;/div&gt;
+        &lt;div data-attribute=&quot;Web-é-Kit&quot; multiple=&quot;web-É-kit&quot; id=&quot;target4&quot;&gt;&lt;/div&gt;
+        &lt;div data-attribute=&quot;web-é-kit&quot; multiple=&quot;web-É-Kit&quot; id=&quot;target5&quot;&gt;&lt;/div&gt;
+    &lt;/div&gt;
+&lt;/body&gt;
+&lt;script&gt;
+description('When matching attributes case insensitively, it should be ASCII case insensitive. This test verifies the behavior when matching the start of the values (e.g. [a^=&quot;b&quot;])');
+
+function testQuerySelector(selector, expectedIds) {
+    shouldBe(&quot;document.querySelectorAll('&quot; + selector + &quot;').length&quot;, '' + expectedIds.length);
+    for (var i = 0; i &lt; expectedIds.length; ++i)
+        shouldBeEqualToString(&quot;document.querySelectorAll('&quot; + selector + &quot;')[&quot; + i + &quot;].id&quot;, 'target' + expectedIds[i]);
+}
+
+function testStyling(selector, expectedIds) {
+    var stylingElement = document.getElementById(&quot;style&quot;);
+    stylingElement.innerHTML = '' + selector + ' { background-color: rgb(10, 100, 200); }';
+
+    var allTestCases = document.querySelectorAll(&quot;#test-root *&quot;);
+    for (var i = 0; i &lt; allTestCases.length; ++i) {
+        var expectMatch = expectedIds.indexOf(parseInt(allTestCases[i].id.replace('target', ''))) &gt;= 0;
+        shouldBeEqualToString('getComputedStyle(document.querySelectorAll(&quot;#test-root *&quot;)[' + i + ']).backgroundColor', expectMatch ? 'rgb(10, 100, 200)' : 'rgb(255, 0, 0)');
+    }
+
+    stylingElement.innerHTML = '';
+}
+
+function testSelector(selector, expectedIds) {
+    debug(&quot;Testing \&quot;&quot; + selector + &quot;\&quot;&quot;);
+    testQuerySelector(&quot;#test-root &quot; + selector, expectedIds);
+    testStyling(&quot;#test-root &quot; + selector, expectedIds);
+    debug(&quot;&quot;);
+}
+
+var testCases = [
+    // Regular attribute matching is case sensitive.
+    ['[data-attribute^=Web-É-Kit]', [1]],
+    ['[data-attribute^=Web-É]', [1]],
+
+    ['[data-attribute^=web-É-kit]', [2]],
+    ['[data-attribute^=web-É]', [2]],
+
+    ['[data-attribute^=WEB-É-KIT]', [3]],
+    ['[data-attribute^=WEB-É]', [3]],
+
+    ['[data-attribute^=Web-é-Kit]', [4]],
+    ['[data-attribute^=Web-é]', [4]],
+
+    ['[data-attribute^=web-é-kit]', [5]],
+    ['[data-attribute^=web-é]', [5]],
+
+    // Same selectors with the case-insensitive flag.
+    ['[data-attribute^=Web-É-Kit i]', [1, 2, 3]],
+    ['[data-attribute^=Web-É i]', [1, 2, 3]],
+
+    ['[data-attribute^=web-É-kit i]', [1, 2, 3]],
+    ['[data-attribute^=web-É i]', [1, 2, 3]],
+
+    ['[data-attribute^=WEB-É-KIT i]', [1, 2, 3]],
+    ['[data-attribute^=WEB-É i]', [1, 2, 3]],
+
+    ['[data-attribute^=Web-é-Kit i]', [4, 5]],
+    ['[data-attribute^=Web-é i]', [4, 5]],
+
+    ['[data-attribute^=web-é-kit i]', [4, 5]],
+    ['[data-attribute^=web-é i]', [4, 5]],
+
+    // &quot;multiple&quot; is one of those weird legacy exception: it is always case insensitive in HTML.
+    ['[multiple^=WEB-é-KIT]', [1, 2, 3]],
+    ['[multiple^=WEB-é]', [1, 2, 3]],
+
+    ['[multiple^=Web-é-Kit]', [1, 2, 3]],
+    ['[multiple^=Web-é]', [1, 2, 3]],
+
+    ['[multiple^=Web-é-kit]', [1, 2, 3]],
+    ['[multiple^=Web-é]', [1, 2, 3]],
+
+    ['[multiple^=web-É-kit]', [4, 5]],
+    ['[multiple^=web-É]', [4, 5]],
+
+    ['[multiple^=web-É-Kit]', [4, 5]],
+    ['[multiple^=web-É]', [4, 5]],
+
+    ['[multiple^=WEB-é-KIT i]', [1, 2, 3]],
+    ['[multiple^=WEB-é i]', [1, 2, 3]],
+
+    ['[multiple^=Web-é-Kit i]', [1, 2, 3]],
+    ['[multiple^=Web-é i]', [1, 2, 3]],
+
+    ['[multiple^=Web-é-kit i]', [1, 2, 3]],
+    ['[multiple^=Web-é i]', [1, 2, 3]],
+
+    ['[multiple^=web-É-kit i]', [4, 5]],
+    ['[multiple^=web-É i]', [4, 5]],
+
+    ['[multiple^=web-É-Kit i]', [4, 5]],
+    ['[multiple^=web-É i]', [4, 5]],
+];
+
+for (var testCase of testCases) {
+    testSelector(testCase[0], testCase[1]);
+}
+&lt;/script&gt;
+&lt;script src=&quot;../../resources/js-test-post.js&quot;&gt;&lt;/script&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="trunkSourceWTFChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WTF/ChangeLog (181524 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WTF/ChangeLog        2015-03-16 06:28:46 UTC (rev 181524)
+++ trunk/Source/WTF/ChangeLog        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -1,3 +1,62 @@
</span><ins>+2015-03-15  Benjamin Poulain  &lt;benjamin@webkit.org&gt;
+
+        CSS: fix the case-insensitive matching of the attribute selectors Begin, End and Hyphen
+        https://bugs.webkit.org/show_bug.cgi?id=142715
+
+        Reviewed by Brent Fulgham.
+
+        Add the necessary infrastructure to test startsWith() and endsWith() with
+        ASCII case-insentive comparisons.
+
+        * wtf/text/AtomicString.h:
+        (WTF::AtomicString::startsWith):
+        (WTF::AtomicString::startsWithIgnoringASCIICase):
+        (WTF::AtomicString::endsWith):
+        (WTF::AtomicString::endsWithIgnoringASCIICase):
+
+        * wtf/text/StringCommon.h:
+        (WTF::loadUnaligned):
+        (WTF::equal):
+        I moved the low level equal() code from StringImpl to StringCommon
+        since it is used by both StringImpl and StringView.
+
+        (WTF::equalCommon):
+        (WTF::equalIgnoringASCIICaseCommon):
+        Ideally we should drop the &quot;Common&quot; part of the name but StringView
+        wants this inline for some reason. I prefered keeping the current behavior
+        since I don't know how StringView's matching performance was evaluated.
+
+        (WTF::startsWith):
+        (WTF::startsWithIgnoringASCIICase):
+        (WTF::endsWith):
+        (WTF::endsWithIgnoringASCIICase):
+        Make all that code shared between StringView and Stringimpl.
+
+        * wtf/text/StringImpl.cpp:
+        (WTF::StringImpl::startsWith):
+        (WTF::StringImpl::startsWithIgnoringASCIICase):
+        (WTF::StringImpl::endsWith):
+        (WTF::StringImpl::endsWithIgnoringASCIICase):
+        (WTF::equal):
+        (WTF::stringImplContentEqual): Deleted.
+        * wtf/text/StringImpl.h:
+        (WTF::loadUnaligned): Deleted.
+        (WTF::equal): Deleted.
+
+        * wtf/text/StringView.cpp:
+        (WTF::StringView::startsWith):
+        (WTF::StringView::startsWithIgnoringASCIICase):
+        (WTF::StringView::endsWith):
+        (WTF::StringView::endsWithIgnoringASCIICase):
+        * wtf/text/StringView.h:
+        Since those are new, we can safely make them out-of-line and
+        evaluate the inlining impact as needed.
+
+        * wtf/text/WTFString.h:
+        (WTF::String::startsWithIgnoringASCIICase):
+        (WTF::String::endsWith):
+        (WTF::String::endsWithIgnoringASCIICase):
+
</ins><span class="cx"> 2015-03-15  Benjamin Poulain  &lt;bpoulain@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Change the exact attribute matching to be ASCII case-insensitive
</span></span></pre></div>
<a id="trunkSourceWTFwtftextAtomicStringh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WTF/wtf/text/AtomicString.h (181524 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WTF/wtf/text/AtomicString.h        2015-03-16 06:28:46 UTC (rev 181524)
+++ trunk/Source/WTF/wtf/text/AtomicString.h        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -126,7 +126,11 @@
</span><span class="cx">     size_t find(CharacterMatchFunctionPtr matchFunction, unsigned start = 0) const
</span><span class="cx">         { return m_string.find(matchFunction, start); }
</span><span class="cx"> 
</span><del>-    bool startsWith(const String&amp; s, bool caseSensitive = true) const
</del><ins>+    bool startsWith(const String&amp; s) const
+        { return m_string.startsWith(s); }
+    bool startsWithIgnoringASCIICase(const String&amp; s) const
+        { return m_string.startsWithIgnoringASCIICase(s); }
+    bool startsWith(const String&amp; s, bool caseSensitive) const
</ins><span class="cx">         { return m_string.startsWith(s, caseSensitive); }
</span><span class="cx">     bool startsWith(UChar character) const
</span><span class="cx">         { return m_string.startsWith(character); }
</span><span class="lines">@@ -134,7 +138,11 @@
</span><span class="cx">     bool startsWith(const char (&amp;prefix)[matchLength], bool caseSensitive = true) const
</span><span class="cx">         { return m_string.startsWith&lt;matchLength&gt;(prefix, caseSensitive); }
</span><span class="cx"> 
</span><del>-    bool endsWith(const String&amp; s, bool caseSensitive = true) const
</del><ins>+    bool endsWith(const String&amp; s) const
+        { return m_string.endsWith(s); }
+    bool endsWithIgnoringASCIICase(const String&amp; s) const
+        { return m_string.endsWithIgnoringASCIICase(s); }
+    bool endsWith(const String&amp; s, bool caseSensitive) const
</ins><span class="cx">         { return m_string.endsWith(s, caseSensitive); }
</span><span class="cx">     bool endsWith(UChar character) const
</span><span class="cx">         { return m_string.endsWith(character); }
</span></span></pre></div>
<a id="trunkSourceWTFwtftextStringCommonh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WTF/wtf/text/StringCommon.h (181524 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WTF/wtf/text/StringCommon.h        2015-03-16 06:28:46 UTC (rev 181524)
+++ trunk/Source/WTF/wtf/text/StringCommon.h        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -31,6 +31,288 @@
</span><span class="cx"> 
</span><span class="cx"> namespace WTF {
</span><span class="cx"> 
</span><ins>+template&lt;typename T&gt;
+inline T loadUnaligned(const char* s)
+{
+#if COMPILER(CLANG)
+    T tmp;
+    memcpy(&amp;tmp, s, sizeof(T));
+    return tmp;
+#else
+    // This may result in undefined behavior due to unaligned access.
+    return *reinterpret_cast&lt;const T*&gt;(s);
+#endif
+}
+
+// Do comparisons 8 or 4 bytes-at-a-time on architectures where it's safe.
+#if (CPU(X86_64) || CPU(ARM64)) &amp;&amp; !ASAN_ENABLED
+ALWAYS_INLINE bool equal(const LChar* aLChar, const LChar* bLChar, unsigned length)
+{
+    unsigned dwordLength = length &gt;&gt; 3;
+
+    const char* a = reinterpret_cast&lt;const char*&gt;(aLChar);
+    const char* b = reinterpret_cast&lt;const char*&gt;(bLChar);
+
+    if (dwordLength) {
+        for (unsigned i = 0; i != dwordLength; ++i) {
+            if (loadUnaligned&lt;uint64_t&gt;(a) != loadUnaligned&lt;uint64_t&gt;(b))
+                return false;
+
+            a += sizeof(uint64_t);
+            b += sizeof(uint64_t);
+        }
+    }
+
+    if (length &amp; 4) {
+        if (loadUnaligned&lt;uint32_t&gt;(a) != loadUnaligned&lt;uint32_t&gt;(b))
+            return false;
+
+        a += sizeof(uint32_t);
+        b += sizeof(uint32_t);
+    }
+
+    if (length &amp; 2) {
+        if (loadUnaligned&lt;uint16_t&gt;(a) != loadUnaligned&lt;uint16_t&gt;(b))
+            return false;
+
+        a += sizeof(uint16_t);
+        b += sizeof(uint16_t);
+    }
+
+    if (length &amp; 1 &amp;&amp; (*reinterpret_cast&lt;const LChar*&gt;(a) != *reinterpret_cast&lt;const LChar*&gt;(b)))
+        return false;
+
+    return true;
+}
+
+ALWAYS_INLINE bool equal(const UChar* aUChar, const UChar* bUChar, unsigned length)
+{
+    unsigned dwordLength = length &gt;&gt; 2;
+
+    const char* a = reinterpret_cast&lt;const char*&gt;(aUChar);
+    const char* b = reinterpret_cast&lt;const char*&gt;(bUChar);
+
+    if (dwordLength) {
+        for (unsigned i = 0; i != dwordLength; ++i) {
+            if (loadUnaligned&lt;uint64_t&gt;(a) != loadUnaligned&lt;uint64_t&gt;(b))
+                return false;
+
+            a += sizeof(uint64_t);
+            b += sizeof(uint64_t);
+        }
+    }
+
+    if (length &amp; 2) {
+        if (loadUnaligned&lt;uint32_t&gt;(a) != loadUnaligned&lt;uint32_t&gt;(b))
+            return false;
+
+        a += sizeof(uint32_t);
+        b += sizeof(uint32_t);
+    }
+
+    if (length &amp; 1 &amp;&amp; (*reinterpret_cast&lt;const UChar*&gt;(a) != *reinterpret_cast&lt;const UChar*&gt;(b)))
+        return false;
+
+    return true;
+}
+#elif CPU(X86) &amp;&amp; !ASAN_ENABLED
+ALWAYS_INLINE bool equal(const LChar* aLChar, const LChar* bLChar, unsigned length)
+{
+    const char* a = reinterpret_cast&lt;const char*&gt;(aLChar);
+    const char* b = reinterpret_cast&lt;const char*&gt;(bLChar);
+
+    unsigned wordLength = length &gt;&gt; 2;
+    for (unsigned i = 0; i != wordLength; ++i) {
+        if (loadUnaligned&lt;uint32_t&gt;(a) != loadUnaligned&lt;uint32_t&gt;(b))
+            return false;
+        a += sizeof(uint32_t);
+        b += sizeof(uint32_t);
+    }
+
+    length &amp;= 3;
+
+    if (length) {
+        const LChar* aRemainder = reinterpret_cast&lt;const LChar*&gt;(a);
+        const LChar* bRemainder = reinterpret_cast&lt;const LChar*&gt;(b);
+
+        for (unsigned i = 0; i &lt;  length; ++i) {
+            if (aRemainder[i] != bRemainder[i])
+                return false;
+        }
+    }
+
+    return true;
+}
+
+ALWAYS_INLINE bool equal(const UChar* aUChar, const UChar* bUChar, unsigned length)
+{
+    const char* a = reinterpret_cast&lt;const char*&gt;(aUChar);
+    const char* b = reinterpret_cast&lt;const char*&gt;(bUChar);
+
+    unsigned wordLength = length &gt;&gt; 1;
+    for (unsigned i = 0; i != wordLength; ++i) {
+        if (loadUnaligned&lt;uint32_t&gt;(a) != loadUnaligned&lt;uint32_t&gt;(b))
+            return false;
+        a += sizeof(uint32_t);
+        b += sizeof(uint32_t);
+    }
+
+    if (length &amp; 1 &amp;&amp; *reinterpret_cast&lt;const UChar*&gt;(a) != *reinterpret_cast&lt;const UChar*&gt;(b))
+        return false;
+
+    return true;
+}
+#elif PLATFORM(IOS) &amp;&amp; WTF_ARM_ARCH_AT_LEAST(7) &amp;&amp; !ASAN_ENABLED
+ALWAYS_INLINE bool equal(const LChar* a, const LChar* b, unsigned length)
+{
+    bool isEqual = false;
+    uint32_t aValue;
+    uint32_t bValue;
+    asm(&quot;subs   %[length], #4\n&quot;
+        &quot;blo    2f\n&quot;
+
+        &quot;0:\n&quot; // Label 0 = Start of loop over 32 bits.
+        &quot;ldr    %[aValue], [%[a]], #4\n&quot;
+        &quot;ldr    %[bValue], [%[b]], #4\n&quot;
+        &quot;cmp    %[aValue], %[bValue]\n&quot;
+        &quot;bne    66f\n&quot;
+        &quot;subs   %[length], #4\n&quot;
+        &quot;bhs    0b\n&quot;
+
+        // At this point, length can be:
+        // -0: 00000000000000000000000000000000 (0 bytes left)
+        // -1: 11111111111111111111111111111111 (3 bytes left)
+        // -2: 11111111111111111111111111111110 (2 bytes left)
+        // -3: 11111111111111111111111111111101 (1 byte left)
+        // -4: 11111111111111111111111111111100 (length was 0)
+        // The pointers are at the correct position.
+        &quot;2:\n&quot; // Label 2 = End of loop over 32 bits, check for pair of characters.
+        &quot;tst    %[length], #2\n&quot;
+        &quot;beq    1f\n&quot;
+        &quot;ldrh   %[aValue], [%[a]], #2\n&quot;
+        &quot;ldrh   %[bValue], [%[b]], #2\n&quot;
+        &quot;cmp    %[aValue], %[bValue]\n&quot;
+        &quot;bne    66f\n&quot;
+
+        &quot;1:\n&quot; // Label 1 = Check for a single character left.
+        &quot;tst    %[length], #1\n&quot;
+        &quot;beq    42f\n&quot;
+        &quot;ldrb   %[aValue], [%[a]]\n&quot;
+        &quot;ldrb   %[bValue], [%[b]]\n&quot;
+        &quot;cmp    %[aValue], %[bValue]\n&quot;
+        &quot;bne    66f\n&quot;
+
+        &quot;42:\n&quot; // Label 42 = Success.
+        &quot;mov    %[isEqual], #1\n&quot;
+        &quot;66:\n&quot; // Label 66 = End without changing isEqual to 1.
+        : [length]&quot;+r&quot;(length), [isEqual]&quot;+r&quot;(isEqual), [a]&quot;+r&quot;(a), [b]&quot;+r&quot;(b), [aValue]&quot;+r&quot;(aValue), [bValue]&quot;+r&quot;(bValue)
+        :
+        :
+        );
+    return isEqual;
+}
+
+ALWAYS_INLINE bool equal(const UChar* a, const UChar* b, unsigned length)
+{
+    bool isEqual = false;
+    uint32_t aValue;
+    uint32_t bValue;
+    asm(&quot;subs   %[length], #2\n&quot;
+        &quot;blo    1f\n&quot;
+
+        &quot;0:\n&quot; // Label 0 = Start of loop over 32 bits.
+        &quot;ldr    %[aValue], [%[a]], #4\n&quot;
+        &quot;ldr    %[bValue], [%[b]], #4\n&quot;
+        &quot;cmp    %[aValue], %[bValue]\n&quot;
+        &quot;bne    66f\n&quot;
+        &quot;subs   %[length], #2\n&quot;
+        &quot;bhs    0b\n&quot;
+
+        // At this point, length can be:
+        // -0: 00000000000000000000000000000000 (0 bytes left)
+        // -1: 11111111111111111111111111111111 (1 character left, 2 bytes)
+        // -2: 11111111111111111111111111111110 (length was zero)
+        // The pointers are at the correct position.
+        &quot;1:\n&quot; // Label 1 = Check for a single character left.
+        &quot;tst    %[length], #1\n&quot;
+        &quot;beq    42f\n&quot;
+        &quot;ldrh   %[aValue], [%[a]]\n&quot;
+        &quot;ldrh   %[bValue], [%[b]]\n&quot;
+        &quot;cmp    %[aValue], %[bValue]\n&quot;
+        &quot;bne    66f\n&quot;
+
+        &quot;42:\n&quot; // Label 42 = Success.
+        &quot;mov    %[isEqual], #1\n&quot;
+        &quot;66:\n&quot; // Label 66 = End without changing isEqual to 1.
+        : [length]&quot;+r&quot;(length), [isEqual]&quot;+r&quot;(isEqual), [a]&quot;+r&quot;(a), [b]&quot;+r&quot;(b), [aValue]&quot;+r&quot;(aValue), [bValue]&quot;+r&quot;(bValue)
+        :
+        :
+        );
+    return isEqual;
+}
+#elif !ASAN_ENABLED
+ALWAYS_INLINE bool equal(const LChar* a, const LChar* b, unsigned length) { return !memcmp(a, b, length); }
+ALWAYS_INLINE bool equal(const UChar* a, const UChar* b, unsigned length) { return !memcmp(a, b, length * sizeof(UChar)); }
+#else
+ALWAYS_INLINE bool equal(const LChar* a, const LChar* b, unsigned length)
+{
+    for (unsigned i = 0; i &lt; length; ++i) {
+        if (a[i] != b[i])
+            return false;
+    }
+    return true;
+}
+ALWAYS_INLINE bool equal(const UChar* a, const UChar* b, unsigned length)
+{
+    for (unsigned i = 0; i &lt; length; ++i) {
+        if (a[i] != b[i])
+            return false;
+    }
+    return true;
+}
+#endif
+
+ALWAYS_INLINE bool equal(const LChar* a, const UChar* b, unsigned length)
+{
+    for (unsigned i = 0; i &lt; length; ++i) {
+        if (a[i] != b[i])
+            return false;
+    }
+    return true;
+}
+
+ALWAYS_INLINE bool equal(const UChar* a, const LChar* b, unsigned length) { return equal(b, a, length); }
+
+template&lt;typename StringClassA, typename StringClassB&gt;
+ALWAYS_INLINE bool equalCommon(const StringClassA&amp; a, const StringClassB&amp; b)
+{
+    unsigned length = a.length();
+    if (length != b.length())
+        return false;
+
+    if (a.is8Bit()) {
+        if (b.is8Bit())
+            return equal(a.characters8(), b.characters8(), length);
+
+        return equal(a.characters8(), b.characters16(), length);
+    }
+
+    if (b.is8Bit())
+        return equal(a.characters16(), b.characters8(), length);
+
+    return equal(a.characters16(), b.characters16(), length);
+}
+
+template&lt;typename StringClassA, typename StringClassB&gt;
+ALWAYS_INLINE bool equalCommon(const StringClassA* a, const StringClassB* b)
+{
+    if (a == b)
+        return true;
+    if (!a || !b)
+        return false;
+    return equal(*a, *b);
+}
+
</ins><span class="cx"> template&lt;typename CharacterTypeA, typename CharacterTypeB&gt;
</span><span class="cx"> inline bool equalIgnoringASCIICase(const CharacterTypeA* a, const CharacterTypeB* b, unsigned length)
</span><span class="cx"> {
</span><span class="lines">@@ -41,8 +323,8 @@
</span><span class="cx">     return true;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-template&lt;typename StringClass&gt;
-bool equalIgnoringASCIICaseCommon(const StringClass&amp; a, const StringClass&amp; b)
</del><ins>+template&lt;typename StringClassA, typename StringClassB&gt;
+bool equalIgnoringASCIICaseCommon(const StringClassA&amp; a, const StringClassB&amp; b)
</ins><span class="cx"> {
</span><span class="cx">     unsigned length = a.length();
</span><span class="cx">     if (length != b.length())
</span><span class="lines">@@ -61,6 +343,80 @@
</span><span class="cx">     return equalIgnoringASCIICase(a.characters16(), b.characters16(), length);
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+template&lt;typename StringClassA, typename StringClassB&gt;
+bool startsWith(const StringClassA&amp; reference, const StringClassB&amp; prefix)
+{
+    unsigned prefixLength = prefix.length();
+    if (prefixLength &gt; reference.length())
+        return false;
+
+    if (reference.is8Bit()) {
+        if (prefix.is8Bit())
+            return equal(reference.characters8(), prefix.characters8(), prefixLength);
+        return equal(reference.characters8(), prefix.characters16(), prefixLength);
+    }
+    if (prefix.is8Bit())
+        return equal(reference.characters16(), prefix.characters8(), prefixLength);
+    return equal(reference.characters16(), prefix.characters16(), prefixLength);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><ins>+template&lt;typename StringClassA, typename StringClassB&gt;
+bool startsWithIgnoringASCIICase(const StringClassA&amp; reference, const StringClassB&amp; prefix)
+{
+    unsigned prefixLength = prefix.length();
+    if (prefixLength &gt; reference.length())
+        return false;
+
+    if (reference.is8Bit()) {
+        if (prefix.is8Bit())
+            return equalIgnoringASCIICase(reference.characters8(), prefix.characters8(), prefixLength);
+        return equalIgnoringASCIICase(reference.characters8(), prefix.characters16(), prefixLength);
+    }
+    if (prefix.is8Bit())
+        return equalIgnoringASCIICase(reference.characters16(), prefix.characters8(), prefixLength);
+    return equalIgnoringASCIICase(reference.characters16(), prefix.characters16(), prefixLength);
+}
+
+template&lt;typename StringClassA, typename StringClassB&gt;
+bool endsWith(const StringClassA&amp; reference, const StringClassB&amp; suffix)
+{
+    unsigned suffixLength = suffix.length();
+    unsigned referenceLength = reference.length();
+    if (suffixLength &gt; referenceLength)
+        return false;
+
+    unsigned startOffset = referenceLength - suffixLength;
+
+    if (reference.is8Bit()) {
+        if (suffix.is8Bit())
+            return equal(reference.characters8() + startOffset, suffix.characters8(), suffixLength);
+        return equal(reference.characters8() + startOffset, suffix.characters16(), suffixLength);
+    }
+    if (suffix.is8Bit())
+        return equal(reference.characters16() + startOffset, suffix.characters8(), suffixLength);
+    return equal(reference.characters16() + startOffset, suffix.characters16(), suffixLength);
+}
+
+template&lt;typename StringClassA, typename StringClassB&gt;
+bool endsWithIgnoringASCIICase(const StringClassA&amp; reference, const StringClassB&amp; suffix)
+{
+    unsigned suffixLength = suffix.length();
+    unsigned referenceLength = reference.length();
+    if (suffixLength &gt; referenceLength)
+        return false;
+
+    unsigned startOffset = referenceLength - suffixLength;
+
+    if (reference.is8Bit()) {
+        if (suffix.is8Bit())
+            return equalIgnoringASCIICase(reference.characters8() + startOffset, suffix.characters8(), suffixLength);
+        return equalIgnoringASCIICase(reference.characters8() + startOffset, suffix.characters16(), suffixLength);
+    }
+    if (suffix.is8Bit())
+        return equalIgnoringASCIICase(reference.characters16() + startOffset, suffix.characters8(), suffixLength);
+    return equalIgnoringASCIICase(reference.characters16() + startOffset, suffix.characters16(), suffixLength);
+}
+
+}
+
</ins><span class="cx"> #endif // StringCommon_h
</span></span></pre></div>
<a id="trunkSourceWTFwtftextStringImplcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WTF/wtf/text/StringImpl.cpp (181524 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WTF/wtf/text/StringImpl.cpp        2015-03-16 06:28:46 UTC (rev 181524)
+++ trunk/Source/WTF/wtf/text/StringImpl.cpp        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -1380,20 +1380,27 @@
</span><span class="cx"> {
</span><span class="cx">     if (!str)
</span><span class="cx">         return false;
</span><ins>+    return ::WTF::startsWith(*this, *str);
+}
</ins><span class="cx"> 
</span><del>-    if (str-&gt;length() &gt; length())
</del><ins>+bool StringImpl::startsWith(const StringImpl&amp; str) const
+{
+    return ::WTF::startsWith(*this, str);
+}
+
+bool StringImpl::startsWithIgnoringASCIICase(const StringImpl* prefix) const
+{
+    if (!prefix)
</ins><span class="cx">         return false;
</span><span class="cx"> 
</span><del>-    if (is8Bit()) {
-        if (str-&gt;is8Bit())
-            return equal(characters8(), str-&gt;characters8(), str-&gt;length());
-        return equal(characters8(), str-&gt;characters16(), str-&gt;length());
-    }
-    if (str-&gt;is8Bit())
-        return equal(characters16(), str-&gt;characters8(), str-&gt;length());
-    return equal(characters16(), str-&gt;characters16(), str-&gt;length());
</del><ins>+    return ::WTF::startsWithIgnoringASCIICase(*this, *prefix);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><ins>+bool StringImpl::startsWithIgnoringASCIICase(const StringImpl&amp; prefix) const
+{
+    return ::WTF::startsWithIgnoringASCIICase(*this, prefix);
+}
+
</ins><span class="cx"> bool StringImpl::startsWith(UChar character) const
</span><span class="cx"> {
</span><span class="cx">     return m_length &amp;&amp; (*this)[0] == character;
</span><span class="lines">@@ -1412,6 +1419,19 @@
</span><span class="cx">     return equalInner(*this, startOffset, matchString);
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+bool StringImpl::endsWith(StringImpl* suffix)
+{
+    if (!suffix)
+        return false;
+
+    return ::WTF::endsWith(*this, *suffix);
+}
+
+bool StringImpl::endsWith(StringImpl&amp; suffix)
+{
+    return ::WTF::endsWith(*this, suffix);
+}
+
</ins><span class="cx"> bool StringImpl::endsWith(StringImpl* matchString, bool caseSensitive)
</span><span class="cx"> {
</span><span class="cx">     ASSERT(matchString);
</span><span class="lines">@@ -1422,6 +1442,19 @@
</span><span class="cx">     return false;
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+bool StringImpl::endsWithIgnoringASCIICase(const StringImpl* suffix) const
+{
+    if (!suffix)
+        return false;
+
+    return ::WTF::endsWithIgnoringASCIICase(*this, *suffix);
+}
+
+bool StringImpl::endsWithIgnoringASCIICase(const StringImpl&amp; suffix) const
+{
+    return ::WTF::endsWithIgnoringASCIICase(*this, suffix);
+}
+
</ins><span class="cx"> bool StringImpl::endsWith(UChar character) const
</span><span class="cx"> {
</span><span class="cx">     return m_length &amp;&amp; (*this)[m_length - 1] == character;
</span><span class="lines">@@ -1824,34 +1857,9 @@
</span><span class="cx">     return newImpl;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-static ALWAYS_INLINE bool stringImplContentEqual(const StringImpl&amp; a, const StringImpl&amp; b)
-{
-    unsigned aLength = a.length();
-    unsigned bLength = b.length();
-    if (aLength != bLength)
-        return false;
-
-    if (a.is8Bit()) {
-        if (b.is8Bit())
-            return equal(a.characters8(), b.characters8(), aLength);
-
-        return equal(a.characters8(), b.characters16(), aLength);
-    }
-
-    if (b.is8Bit())
-        return equal(a.characters16(), b.characters8(), aLength);
-
-    return equal(a.characters16(), b.characters16(), aLength);
-}
-
</del><span class="cx"> bool equal(const StringImpl* a, const StringImpl* b)
</span><span class="cx"> {
</span><del>-    if (a == b)
-        return true;
-    if (!a || !b)
-        return false;
-
-    return stringImplContentEqual(*a, *b);
</del><ins>+    return equalCommon(a, b);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> template &lt;typename CharType&gt;
</span><span class="lines">@@ -1916,10 +1924,7 @@
</span><span class="cx"> 
</span><span class="cx"> bool equal(const StringImpl&amp; a, const StringImpl&amp; b)
</span><span class="cx"> {
</span><del>-    if (&amp;a == &amp;b)
-        return true;
-
-    return stringImplContentEqual(a, b);
</del><ins>+    return equalCommon(a, b);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> bool equalIgnoringCase(const StringImpl* a, const StringImpl* b)
</span></span></pre></div>
<a id="trunkSourceWTFwtftextStringImplh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WTF/wtf/text/StringImpl.h (181524 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WTF/wtf/text/StringImpl.h        2015-03-16 06:28:46 UTC (rev 181524)
+++ trunk/Source/WTF/wtf/text/StringImpl.h        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -669,6 +669,9 @@
</span><span class="cx">     WTF_EXPORT_STRING_API size_t reverseFindIgnoringCase(StringImpl*, unsigned index = UINT_MAX);
</span><span class="cx"> 
</span><span class="cx">     WTF_EXPORT_STRING_API bool startsWith(const StringImpl*) const;
</span><ins>+    WTF_EXPORT_STRING_API bool startsWith(const StringImpl&amp;) const;
+    WTF_EXPORT_STRING_API bool startsWithIgnoringASCIICase(const StringImpl*) const;
+    WTF_EXPORT_STRING_API bool startsWithIgnoringASCIICase(const StringImpl&amp;) const;
</ins><span class="cx">     bool startsWith(StringImpl* str, bool caseSensitive) { return caseSensitive ? startsWith(str) : (reverseFindIgnoringCase(str, 0) == 0); }
</span><span class="cx">     WTF_EXPORT_STRING_API bool startsWith(UChar) const;
</span><span class="cx">     WTF_EXPORT_STRING_API bool startsWith(const char*, unsigned matchLength, bool caseSensitive) const;
</span><span class="lines">@@ -676,7 +679,11 @@
</span><span class="cx">     bool startsWith(const char (&amp;prefix)[matchLength], bool caseSensitive = true) const { return startsWith(prefix, matchLength - 1, caseSensitive); }
</span><span class="cx">     WTF_EXPORT_STRING_API bool hasInfixStartingAt(const StringImpl&amp;, unsigned startOffset) const;
</span><span class="cx"> 
</span><del>-    WTF_EXPORT_STRING_API bool endsWith(StringImpl*, bool caseSensitive = true);
</del><ins>+    WTF_EXPORT_STRING_API bool endsWith(StringImpl*);
+    WTF_EXPORT_STRING_API bool endsWith(StringImpl&amp;);
+    WTF_EXPORT_STRING_API bool endsWithIgnoringASCIICase(const StringImpl*) const;
+    WTF_EXPORT_STRING_API bool endsWithIgnoringASCIICase(const StringImpl&amp;) const;
+    WTF_EXPORT_STRING_API bool endsWith(StringImpl*, bool caseSensitive);
</ins><span class="cx">     WTF_EXPORT_STRING_API bool endsWith(UChar) const;
</span><span class="cx">     WTF_EXPORT_STRING_API bool endsWith(const char*, unsigned matchLength, bool caseSensitive) const;
</span><span class="cx">     template&lt;unsigned matchLength&gt;
</span><span class="lines">@@ -861,258 +868,6 @@
</span><span class="cx"> inline bool equal(const char* a, StringImpl* b) { return equal(b, reinterpret_cast&lt;const LChar*&gt;(a)); }
</span><span class="cx"> WTF_EXPORT_STRING_API bool equal(const StringImpl&amp; a, const StringImpl&amp; b);
</span><span class="cx"> 
</span><del>-template&lt;typename T&gt;
-inline T loadUnaligned(const char* s)
-{
-#if COMPILER(CLANG)
-    T tmp;
-    memcpy(&amp;tmp, s, sizeof(T));
-    return tmp;
-#else
-    // This may result in undefined behavior due to unaligned access.
-    return *reinterpret_cast&lt;const T*&gt;(s);
-#endif
-}
-
-// Do comparisons 8 or 4 bytes-at-a-time on architectures where it's safe.
-#if (CPU(X86_64) || CPU(ARM64)) &amp;&amp; !ASAN_ENABLED
-ALWAYS_INLINE bool equal(const LChar* aLChar, const LChar* bLChar, unsigned length)
-{
-    unsigned dwordLength = length &gt;&gt; 3;
-
-    const char* a = reinterpret_cast&lt;const char*&gt;(aLChar);
-    const char* b = reinterpret_cast&lt;const char*&gt;(bLChar);
-
-    if (dwordLength) {
-        for (unsigned i = 0; i != dwordLength; ++i) {
-            if (loadUnaligned&lt;uint64_t&gt;(a) != loadUnaligned&lt;uint64_t&gt;(b))
-                return false;
-
-            a += sizeof(uint64_t);
-            b += sizeof(uint64_t);
-        }
-    }
-
-    if (length &amp; 4) {
-        if (loadUnaligned&lt;uint32_t&gt;(a) != loadUnaligned&lt;uint32_t&gt;(b))
-            return false;
-
-        a += sizeof(uint32_t);
-        b += sizeof(uint32_t);
-    }
-
-    if (length &amp; 2) {
-        if (loadUnaligned&lt;uint16_t&gt;(a) != loadUnaligned&lt;uint16_t&gt;(b))
-            return false;
-
-        a += sizeof(uint16_t);
-        b += sizeof(uint16_t);
-    }
-
-    if (length &amp; 1 &amp;&amp; (*reinterpret_cast&lt;const LChar*&gt;(a) != *reinterpret_cast&lt;const LChar*&gt;(b)))
-        return false;
-
-    return true;
-}
-
-ALWAYS_INLINE bool equal(const UChar* aUChar, const UChar* bUChar, unsigned length)
-{
-    unsigned dwordLength = length &gt;&gt; 2;
-
-    const char* a = reinterpret_cast&lt;const char*&gt;(aUChar);
-    const char* b = reinterpret_cast&lt;const char*&gt;(bUChar);
-
-    if (dwordLength) {
-        for (unsigned i = 0; i != dwordLength; ++i) {
-            if (loadUnaligned&lt;uint64_t&gt;(a) != loadUnaligned&lt;uint64_t&gt;(b))
-                return false;
-
-            a += sizeof(uint64_t);
-            b += sizeof(uint64_t);
-        }
-    }
-
-    if (length &amp; 2) {
-        if (loadUnaligned&lt;uint32_t&gt;(a) != loadUnaligned&lt;uint32_t&gt;(b))
-            return false;
-
-        a += sizeof(uint32_t);
-        b += sizeof(uint32_t);
-    }
-
-    if (length &amp; 1 &amp;&amp; (*reinterpret_cast&lt;const UChar*&gt;(a) != *reinterpret_cast&lt;const UChar*&gt;(b)))
-        return false;
-
-    return true;
-}
-#elif CPU(X86) &amp;&amp; !ASAN_ENABLED
-ALWAYS_INLINE bool equal(const LChar* aLChar, const LChar* bLChar, unsigned length)
-{
-    const char* a = reinterpret_cast&lt;const char*&gt;(aLChar);
-    const char* b = reinterpret_cast&lt;const char*&gt;(bLChar);
-
-    unsigned wordLength = length &gt;&gt; 2;
-    for (unsigned i = 0; i != wordLength; ++i) {
-        if (loadUnaligned&lt;uint32_t&gt;(a) != loadUnaligned&lt;uint32_t&gt;(b))
-            return false;
-        a += sizeof(uint32_t);
-        b += sizeof(uint32_t);
-    }
-
-    length &amp;= 3;
-
-    if (length) {
-        const LChar* aRemainder = reinterpret_cast&lt;const LChar*&gt;(a);
-        const LChar* bRemainder = reinterpret_cast&lt;const LChar*&gt;(b);
-
-        for (unsigned i = 0; i &lt;  length; ++i) {
-            if (aRemainder[i] != bRemainder[i])
-                return false;
-        }
-    }
-
-    return true;
-}
-
-ALWAYS_INLINE bool equal(const UChar* aUChar, const UChar* bUChar, unsigned length)
-{
-    const char* a = reinterpret_cast&lt;const char*&gt;(aUChar);
-    const char* b = reinterpret_cast&lt;const char*&gt;(bUChar);
-
-    unsigned wordLength = length &gt;&gt; 1;
-    for (unsigned i = 0; i != wordLength; ++i) {
-        if (loadUnaligned&lt;uint32_t&gt;(a) != loadUnaligned&lt;uint32_t&gt;(b))
-            return false;
-        a += sizeof(uint32_t);
-        b += sizeof(uint32_t);
-    }
-
-    if (length &amp; 1 &amp;&amp; *reinterpret_cast&lt;const UChar*&gt;(a) != *reinterpret_cast&lt;const UChar*&gt;(b))
-        return false;
-
-    return true;
-}
-#elif PLATFORM(IOS) &amp;&amp; WTF_ARM_ARCH_AT_LEAST(7) &amp;&amp; !ASAN_ENABLED
-ALWAYS_INLINE bool equal(const LChar* a, const LChar* b, unsigned length)
-{
-    bool isEqual = false;
-    uint32_t aValue;
-    uint32_t bValue;
-    asm(&quot;subs   %[length], #4\n&quot;
-        &quot;blo    2f\n&quot;
-
-        &quot;0:\n&quot; // Label 0 = Start of loop over 32 bits.
-        &quot;ldr    %[aValue], [%[a]], #4\n&quot;
-        &quot;ldr    %[bValue], [%[b]], #4\n&quot;
-        &quot;cmp    %[aValue], %[bValue]\n&quot;
-        &quot;bne    66f\n&quot;
-        &quot;subs   %[length], #4\n&quot;
-        &quot;bhs    0b\n&quot;
-
-        // At this point, length can be:
-        // -0: 00000000000000000000000000000000 (0 bytes left)
-        // -1: 11111111111111111111111111111111 (3 bytes left)
-        // -2: 11111111111111111111111111111110 (2 bytes left)
-        // -3: 11111111111111111111111111111101 (1 byte left)
-        // -4: 11111111111111111111111111111100 (length was 0)
-        // The pointers are at the correct position.
-        &quot;2:\n&quot; // Label 2 = End of loop over 32 bits, check for pair of characters.
-        &quot;tst    %[length], #2\n&quot;
-        &quot;beq    1f\n&quot;
-        &quot;ldrh   %[aValue], [%[a]], #2\n&quot;
-        &quot;ldrh   %[bValue], [%[b]], #2\n&quot;
-        &quot;cmp    %[aValue], %[bValue]\n&quot;
-        &quot;bne    66f\n&quot;
-
-        &quot;1:\n&quot; // Label 1 = Check for a single character left.
-        &quot;tst    %[length], #1\n&quot;
-        &quot;beq    42f\n&quot;
-        &quot;ldrb   %[aValue], [%[a]]\n&quot;
-        &quot;ldrb   %[bValue], [%[b]]\n&quot;
-        &quot;cmp    %[aValue], %[bValue]\n&quot;
-        &quot;bne    66f\n&quot;
-
-        &quot;42:\n&quot; // Label 42 = Success.
-        &quot;mov    %[isEqual], #1\n&quot;
-        &quot;66:\n&quot; // Label 66 = End without changing isEqual to 1.
-        : [length]&quot;+r&quot;(length), [isEqual]&quot;+r&quot;(isEqual), [a]&quot;+r&quot;(a), [b]&quot;+r&quot;(b), [aValue]&quot;+r&quot;(aValue), [bValue]&quot;+r&quot;(bValue)
-        :
-        :
-        );
-    return isEqual;
-}
-
-ALWAYS_INLINE bool equal(const UChar* a, const UChar* b, unsigned length)
-{
-    bool isEqual = false;
-    uint32_t aValue;
-    uint32_t bValue;
-    asm(&quot;subs   %[length], #2\n&quot;
-        &quot;blo    1f\n&quot;
-
-        &quot;0:\n&quot; // Label 0 = Start of loop over 32 bits.
-        &quot;ldr    %[aValue], [%[a]], #4\n&quot;
-        &quot;ldr    %[bValue], [%[b]], #4\n&quot;
-        &quot;cmp    %[aValue], %[bValue]\n&quot;
-        &quot;bne    66f\n&quot;
-        &quot;subs   %[length], #2\n&quot;
-        &quot;bhs    0b\n&quot;
-
-        // At this point, length can be:
-        // -0: 00000000000000000000000000000000 (0 bytes left)
-        // -1: 11111111111111111111111111111111 (1 character left, 2 bytes)
-        // -2: 11111111111111111111111111111110 (length was zero)
-        // The pointers are at the correct position.
-        &quot;1:\n&quot; // Label 1 = Check for a single character left.
-        &quot;tst    %[length], #1\n&quot;
-        &quot;beq    42f\n&quot;
-        &quot;ldrh   %[aValue], [%[a]]\n&quot;
-        &quot;ldrh   %[bValue], [%[b]]\n&quot;
-        &quot;cmp    %[aValue], %[bValue]\n&quot;
-        &quot;bne    66f\n&quot;
-
-        &quot;42:\n&quot; // Label 42 = Success.
-        &quot;mov    %[isEqual], #1\n&quot;
-        &quot;66:\n&quot; // Label 66 = End without changing isEqual to 1.
-        : [length]&quot;+r&quot;(length), [isEqual]&quot;+r&quot;(isEqual), [a]&quot;+r&quot;(a), [b]&quot;+r&quot;(b), [aValue]&quot;+r&quot;(aValue), [bValue]&quot;+r&quot;(bValue)
-        :
-        :
-        );
-    return isEqual;
-}
-#elif !ASAN_ENABLED
-ALWAYS_INLINE bool equal(const LChar* a, const LChar* b, unsigned length) { return !memcmp(a, b, length); }
-ALWAYS_INLINE bool equal(const UChar* a, const UChar* b, unsigned length) { return !memcmp(a, b, length * sizeof(UChar)); }
-#else
-ALWAYS_INLINE bool equal(const LChar* a, const LChar* b, unsigned length)
-{
-    for (unsigned i = 0; i &lt; length; ++i) {
-        if (a[i] != b[i])
-            return false;
-    }
-    return true;
-}
-ALWAYS_INLINE bool equal(const UChar* a, const UChar* b, unsigned length)
-{
-    for (unsigned i = 0; i &lt; length; ++i) {
-        if (a[i] != b[i])
-            return false;
-    }
-    return true;
-}
-#endif
-
-ALWAYS_INLINE bool equal(const LChar* a, const UChar* b, unsigned length)
-{
-    for (unsigned i = 0; i &lt; length; ++i) {
-        if (a[i] != b[i])
-            return false;
-    }
-    return true;
-}
-
-ALWAYS_INLINE bool equal(const UChar* a, const LChar* b, unsigned length) { return equal(b, a, length); }
-
</del><span class="cx"> WTF_EXPORT_STRING_API bool equalIgnoringCase(const StringImpl*, const StringImpl*);
</span><span class="cx"> WTF_EXPORT_STRING_API bool equalIgnoringCase(const StringImpl*, const LChar*);
</span><span class="cx"> inline bool equalIgnoringCase(const LChar* a, const StringImpl* b) { return equalIgnoringCase(b, a); }
</span></span></pre></div>
<a id="trunkSourceWTFwtftextStringViewcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WTF/wtf/text/StringView.cpp (181524 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WTF/wtf/text/StringView.cpp        2015-03-16 06:28:46 UTC (rev 181524)
+++ trunk/Source/WTF/wtf/text/StringView.cpp        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -118,6 +118,26 @@
</span><span class="cx">     adoptUnderlyingString(underlyingString);
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+bool StringView::startsWith(const StringView&amp; prefix) const
+{
+    return ::WTF::startsWith(*this, prefix);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><ins>+bool StringView::startsWithIgnoringASCIICase(const StringView&amp; prefix) const
+{
+    return ::WTF::endsWithIgnoringASCIICase(*this, prefix);
+}
+
+bool StringView::endsWith(const StringView&amp; prefix) const
+{
+    return ::WTF::startsWith(*this, prefix);
+}
+
+bool StringView::endsWithIgnoringASCIICase(const StringView&amp; prefix) const
+{
+    return ::WTF::endsWithIgnoringASCIICase(*this, prefix);
+}
+
+}
+
</ins><span class="cx"> #endif
</span></span></pre></div>
<a id="trunkSourceWTFwtftextStringViewh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WTF/wtf/text/StringView.h (181524 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WTF/wtf/text/StringView.h        2015-03-16 06:28:46 UTC (rev 181524)
+++ trunk/Source/WTF/wtf/text/StringView.h        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -106,6 +106,12 @@
</span><span class="cx">     size_t find(UChar, unsigned start = 0) const;
</span><span class="cx">     bool contains(UChar) const;
</span><span class="cx"> 
</span><ins>+    bool startsWith(const StringView&amp;) const;
+    bool startsWithIgnoringASCIICase(const StringView&amp;) const;
+
+    bool endsWith(const StringView&amp;) const;
+    bool endsWithIgnoringASCIICase(const StringView&amp;) const;
+
</ins><span class="cx">     int toInt(bool&amp; isValid) const;
</span><span class="cx">     float toFloat(bool&amp; isValid) const;
</span><span class="cx"> 
</span><span class="lines">@@ -469,22 +475,7 @@
</span><span class="cx"> 
</span><span class="cx"> inline bool equal(StringView a, StringView b)
</span><span class="cx"> {
</span><del>-    unsigned aLength = a.length();
-    unsigned bLength = b.length();
-    if (aLength != bLength)
-        return false;
-
-    if (a.is8Bit()) {
-        if (b.is8Bit())
-            return equal(a.characters8(), b.characters8(), aLength);
-
-        return equal(a.characters8(), b.characters16(), aLength);
-    }
-
-    if (b.is8Bit())
-        return equal(a.characters16(), b.characters8(), aLength);
-
-    return equal(a.characters16(), b.characters16(), aLength);
</del><ins>+    return equalCommon(a, b);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> inline bool equal(StringView a, const LChar* b)
</span></span></pre></div>
<a id="trunkSourceWTFwtftextWTFStringh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WTF/wtf/text/WTFString.h (181524 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WTF/wtf/text/WTFString.h        2015-03-16 06:28:46 UTC (rev 181524)
+++ trunk/Source/WTF/wtf/text/WTFString.h        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -263,6 +263,8 @@
</span><span class="cx"> 
</span><span class="cx">     bool startsWith(const String&amp; s) const
</span><span class="cx">         { return m_impl ? m_impl-&gt;startsWith(s.impl()) : s.isEmpty(); }
</span><ins>+    bool startsWithIgnoringASCIICase(const String&amp; s) const
+        { return m_impl ? m_impl-&gt;startsWithIgnoringASCIICase(s.impl()) : s.isEmpty(); }
</ins><span class="cx">     bool startsWith(const String&amp; s, bool caseSensitive) const
</span><span class="cx">         { return m_impl ? m_impl-&gt;startsWith(s.impl(), caseSensitive) : s.isEmpty(); }
</span><span class="cx">     bool startsWith(UChar character) const
</span><span class="lines">@@ -273,7 +275,11 @@
</span><span class="cx">     bool hasInfixStartingAt(const String&amp; prefix, unsigned startOffset) const
</span><span class="cx">         { return m_impl &amp;&amp; prefix.impl() ? m_impl-&gt;hasInfixStartingAt(*prefix.impl(), startOffset) : false; }
</span><span class="cx"> 
</span><del>-    bool endsWith(const String&amp; s, bool caseSensitive = true) const
</del><ins>+    bool endsWith(const String&amp; s) const
+        { return m_impl ? m_impl-&gt;endsWith(s.impl()) : s.isEmpty(); }
+    bool endsWithIgnoringASCIICase(const String&amp; s) const
+        { return m_impl ? m_impl-&gt;endsWithIgnoringASCIICase(s.impl()) : s.isEmpty(); }
+    bool endsWith(const String&amp; s, bool caseSensitive) const
</ins><span class="cx">         { return m_impl ? m_impl-&gt;endsWith(s.impl(), caseSensitive) : s.isEmpty(); }
</span><span class="cx">     bool endsWith(UChar character) const
</span><span class="cx">         { return m_impl ? m_impl-&gt;endsWith(character) : false; }
</span></span></pre></div>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (181524 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2015-03-16 06:28:46 UTC (rev 181524)
+++ trunk/Source/WebCore/ChangeLog        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -1,3 +1,29 @@
</span><ins>+2015-03-15  Benjamin Poulain  &lt;benjamin@webkit.org&gt;
+
+        CSS: fix the case-insensitive matching of the attribute selectors Begin, End and Hyphen
+        https://bugs.webkit.org/show_bug.cgi?id=142715
+
+        Reviewed by Brent Fulgham.
+
+        Fix attribute matching with:
+        -Begin: [a^=b].
+        -End: [a$=b].
+        -Hyphen: [a|=b].
+
+        Tests: fast/selectors/attribute-endswith-value-matching-is-ascii-case-insensitive.html
+               fast/selectors/attribute-hyphen-value-matching-is-ascii-case-insensitive.html
+               fast/selectors/attribute-startswith-value-matching-is-ascii-case-insensitive.html
+
+        * css/SelectorChecker.cpp:
+        (WebCore::attributeValueMatches):
+        I forgot to change CSSSelector::Exact in my last patch.
+        The tests could not catch that since we use the CSS JIT almost everywhere.
+
+        * cssjit/SelectorCompiler.cpp:
+        (WebCore::SelectorCompiler::attributeValueBeginsWith):
+        (WebCore::SelectorCompiler::attributeValueEndsWith):
+        (WebCore::SelectorCompiler::attributeValueMatchHyphenRule):
+
</ins><span class="cx"> 2015-03-15  Dan Bernstein  &lt;mitz@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Fixed the iOS build after r181522.
</span></span></pre></div>
<a id="trunkSourceWebCorecssSelectorCheckercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/css/SelectorChecker.cpp (181524 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/css/SelectorChecker.cpp        2015-03-16 06:28:46 UTC (rev 181524)
+++ trunk/Source/WebCore/css/SelectorChecker.cpp        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -420,7 +420,7 @@
</span><span class="cx">     case CSSSelector::Set:
</span><span class="cx">         break;
</span><span class="cx">     case CSSSelector::Exact:
</span><del>-        if (caseSensitive ? selectorValue != value : !equalIgnoringCase(selectorValue, value))
</del><ins>+        if (caseSensitive ? selectorValue != value : !equalIgnoringASCIICase(selectorValue, value))
</ins><span class="cx">             return false;
</span><span class="cx">         break;
</span><span class="cx">     case CSSSelector::List:
</span><span class="lines">@@ -450,18 +450,37 @@
</span><span class="cx">             return false;
</span><span class="cx">         break;
</span><span class="cx">     case CSSSelector::Begin:
</span><del>-        if (!value.startsWith(selectorValue, caseSensitive) || selectorValue.isEmpty())
</del><ins>+        if (selectorValue.isEmpty())
</ins><span class="cx">             return false;
</span><ins>+        if (caseSensitive) {
+            if (!value.startsWith(selectorValue))
+                return false;
+        } else {
+            if (!value.startsWithIgnoringASCIICase(selectorValue))
+                return false;
+        }
</ins><span class="cx">         break;
</span><span class="cx">     case CSSSelector::End:
</span><del>-        if (!value.endsWith(selectorValue, caseSensitive) || selectorValue.isEmpty())
</del><ins>+        if (selectorValue.isEmpty())
</ins><span class="cx">             return false;
</span><ins>+        if (caseSensitive) {
+            if (!value.endsWith(selectorValue))
+                return false;
+        } else {
+            if (!value.endsWithIgnoringASCIICase(selectorValue))
+                return false;
+        }
</ins><span class="cx">         break;
</span><span class="cx">     case CSSSelector::Hyphen:
</span><span class="cx">         if (value.length() &lt; selectorValue.length())
</span><span class="cx">             return false;
</span><del>-        if (!value.startsWith(selectorValue, caseSensitive))
-            return false;
</del><ins>+        if (caseSensitive) {
+            if (!value.startsWith(selectorValue))
+                return false;
+        } else {
+            if (!value.startsWithIgnoringASCIICase(selectorValue))
+                return false;
+        }
</ins><span class="cx">         // It they start the same, check for exact match or following '-':
</span><span class="cx">         if (value.length() != selectorValue.length() &amp;&amp; value[selectorValue.length()] != '-')
</span><span class="cx">             return false;
</span></span></pre></div>
<a id="trunkSourceWebCorecssjitSelectorCompilercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/cssjit/SelectorCompiler.cpp (181524 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/cssjit/SelectorCompiler.cpp        2015-03-16 06:28:46 UTC (rev 181524)
+++ trunk/Source/WebCore/cssjit/SelectorCompiler.cpp        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -2803,10 +2803,12 @@
</span><span class="cx"> template&lt;CaseSensitivity caseSensitivity&gt;
</span><span class="cx"> static bool attributeValueBeginsWith(const Attribute* attribute, AtomicStringImpl* expectedString)
</span><span class="cx"> {
</span><ins>+    ASSERT(expectedString);
+
</ins><span class="cx">     AtomicStringImpl&amp; valueImpl = *attribute-&gt;value().impl();
</span><span class="cx">     if (caseSensitivity == CaseSensitive)
</span><del>-        return valueImpl.startsWith(expectedString);
-    return valueImpl.startsWith(expectedString, false);
</del><ins>+        return valueImpl.startsWith(*expectedString);
+    return valueImpl.startsWithIgnoringASCIICase(*expectedString);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> template&lt;CaseSensitivity caseSensitivity&gt;
</span><span class="lines">@@ -2821,24 +2823,28 @@
</span><span class="cx"> template&lt;CaseSensitivity caseSensitivity&gt;
</span><span class="cx"> static bool attributeValueEndsWith(const Attribute* attribute, AtomicStringImpl* expectedString)
</span><span class="cx"> {
</span><ins>+    ASSERT(expectedString);
+
</ins><span class="cx">     AtomicStringImpl&amp; valueImpl = *attribute-&gt;value().impl();
</span><span class="cx">     if (caseSensitivity == CaseSensitive)
</span><del>-        return valueImpl.endsWith(expectedString);
-    return valueImpl.endsWith(expectedString, false);
</del><ins>+        return valueImpl.endsWith(*expectedString);
+    return valueImpl.endsWithIgnoringASCIICase(*expectedString);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> template&lt;CaseSensitivity caseSensitivity&gt;
</span><span class="cx"> static bool attributeValueMatchHyphenRule(const Attribute* attribute, AtomicStringImpl* expectedString)
</span><span class="cx"> {
</span><ins>+    ASSERT(expectedString);
+
</ins><span class="cx">     AtomicStringImpl&amp; valueImpl = *attribute-&gt;value().impl();
</span><span class="cx">     if (valueImpl.length() &lt; expectedString-&gt;length())
</span><span class="cx">         return false;
</span><span class="cx"> 
</span><span class="cx">     bool valueStartsWithExpectedString;
</span><span class="cx">     if (caseSensitivity == CaseSensitive)
</span><del>-        valueStartsWithExpectedString = valueImpl.startsWith(expectedString);
</del><ins>+        valueStartsWithExpectedString = valueImpl.startsWith(*expectedString);
</ins><span class="cx">     else
</span><del>-        valueStartsWithExpectedString = valueImpl.startsWith(expectedString, false);
</del><ins>+        valueStartsWithExpectedString = valueImpl.startsWithIgnoringASCIICase(*expectedString);
</ins><span class="cx"> 
</span><span class="cx">     if (!valueStartsWithExpectedString)
</span><span class="cx">         return false;
</span></span></pre></div>
<a id="trunkToolsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Tools/ChangeLog (181524 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/ChangeLog        2015-03-16 06:28:46 UTC (rev 181524)
+++ trunk/Tools/ChangeLog        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -1,3 +1,13 @@
</span><ins>+2015-03-15  Benjamin Poulain  &lt;benjamin@webkit.org&gt;
+
+        CSS: fix the case-insensitive matching of the attribute selectors Begin, End and Hyphen
+        https://bugs.webkit.org/show_bug.cgi?id=142715
+
+        Reviewed by Brent Fulgham.
+
+        * TestWebKitAPI/Tests/WTF/StringImpl.cpp:
+        (TestWebKitAPI::TEST):
+
</ins><span class="cx"> 2015-03-15  Benjamin Poulain  &lt;bpoulain@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Change the exact attribute matching to be ASCII case-insensitive
</span></span></pre></div>
<a id="trunkToolsTestWebKitAPITestsWTFStringImplcpp"></a>
<div class="modfile"><h4>Modified: trunk/Tools/TestWebKitAPI/Tests/WTF/StringImpl.cpp (181524 => 181525)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/TestWebKitAPI/Tests/WTF/StringImpl.cpp        2015-03-16 06:28:46 UTC (rev 181524)
+++ trunk/Tools/TestWebKitAPI/Tests/WTF/StringImpl.cpp        2015-03-16 06:51:44 UTC (rev 181525)
</span><span class="lines">@@ -164,4 +164,152 @@
</span><span class="cx">     ASSERT_TRUE(equalIgnoringASCIICase(c.get(), d.get()));
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+TEST(WTF, StringImplStartsWithIgnoringASCIICaseBasic)
+{
+    RefPtr&lt;StringImpl&gt; reference = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;aBcéX&quot;));
+    RefPtr&lt;StringImpl&gt; referenceEquivalent = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;AbCéx&quot;));
+
+    // Identity.
+    ASSERT_TRUE(reference-&gt;startsWithIgnoringASCIICase(reference.get()));
+    ASSERT_TRUE(reference-&gt;startsWithIgnoringASCIICase(*reference.get()));
+    ASSERT_TRUE(reference-&gt;startsWithIgnoringASCIICase(referenceEquivalent.get()));
+    ASSERT_TRUE(reference-&gt;startsWithIgnoringASCIICase(*referenceEquivalent.get()));
+    ASSERT_TRUE(referenceEquivalent-&gt;startsWithIgnoringASCIICase(reference.get()));
+    ASSERT_TRUE(referenceEquivalent-&gt;startsWithIgnoringASCIICase(*reference.get()));
+    ASSERT_TRUE(referenceEquivalent-&gt;startsWithIgnoringASCIICase(referenceEquivalent.get()));
+    ASSERT_TRUE(referenceEquivalent-&gt;startsWithIgnoringASCIICase(*referenceEquivalent.get()));
+
+    // Proper prefixes.
+    RefPtr&lt;StringImpl&gt; aLower = StringImpl::createFromLiteral(&quot;a&quot;);
+    ASSERT_TRUE(reference-&gt;startsWithIgnoringASCIICase(aLower.get()));
+    ASSERT_TRUE(reference-&gt;startsWithIgnoringASCIICase(*aLower.get()));
+    RefPtr&lt;StringImpl&gt; aUpper = StringImpl::createFromLiteral(&quot;A&quot;);
+    ASSERT_TRUE(reference-&gt;startsWithIgnoringASCIICase(aUpper.get()));
+    ASSERT_TRUE(reference-&gt;startsWithIgnoringASCIICase(*aUpper.get()));
+
+    RefPtr&lt;StringImpl&gt; abcLower = StringImpl::createFromLiteral(&quot;abc&quot;);
+    ASSERT_TRUE(reference-&gt;startsWithIgnoringASCIICase(abcLower.get()));
+    ASSERT_TRUE(reference-&gt;startsWithIgnoringASCIICase(*abcLower.get()));
+    RefPtr&lt;StringImpl&gt; abcUpper = StringImpl::createFromLiteral(&quot;ABC&quot;);
+    ASSERT_TRUE(reference-&gt;startsWithIgnoringASCIICase(abcUpper.get()));
+    ASSERT_TRUE(reference-&gt;startsWithIgnoringASCIICase(*abcUpper.get()));
+
+    RefPtr&lt;StringImpl&gt; abcAccentLower = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;abcé&quot;));
+    ASSERT_TRUE(reference-&gt;startsWithIgnoringASCIICase(abcAccentLower.get()));
+    ASSERT_TRUE(reference-&gt;startsWithIgnoringASCIICase(*abcAccentLower.get()));
+    RefPtr&lt;StringImpl&gt; abcAccentUpper = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;ABCé&quot;));
+    ASSERT_TRUE(reference-&gt;startsWithIgnoringASCIICase(abcAccentUpper.get()));
+    ASSERT_TRUE(reference-&gt;startsWithIgnoringASCIICase(*abcAccentUpper.get()));
+
+    // Negative cases.
+    RefPtr&lt;StringImpl&gt; differentFirstChar = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;bBcéX&quot;));
+    RefPtr&lt;StringImpl&gt; differentFirstCharProperPrefix = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;CBcé&quot;));
+    ASSERT_FALSE(reference-&gt;startsWithIgnoringASCIICase(differentFirstChar.get()));
+    ASSERT_FALSE(reference-&gt;startsWithIgnoringASCIICase(*differentFirstChar.get()));
+    ASSERT_FALSE(reference-&gt;startsWithIgnoringASCIICase(differentFirstCharProperPrefix.get()));
+    ASSERT_FALSE(reference-&gt;startsWithIgnoringASCIICase(*differentFirstCharProperPrefix.get()));
+
+    RefPtr&lt;StringImpl&gt; uppercaseAccent = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;aBcÉX&quot;));
+    RefPtr&lt;StringImpl&gt; uppercaseAccentProperPrefix = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;aBcÉX&quot;));
+    ASSERT_FALSE(reference-&gt;startsWithIgnoringASCIICase(uppercaseAccent.get()));
+    ASSERT_FALSE(reference-&gt;startsWithIgnoringASCIICase(*uppercaseAccent.get()));
+    ASSERT_FALSE(reference-&gt;startsWithIgnoringASCIICase(uppercaseAccentProperPrefix.get()));
+    ASSERT_FALSE(reference-&gt;startsWithIgnoringASCIICase(*uppercaseAccentProperPrefix.get()));
+}
+
+TEST(WTF, StringImplStartsWithIgnoringASCIICaseWithNull)
+{
+    RefPtr&lt;StringImpl&gt; reference = StringImpl::createFromLiteral(&quot;aBcDeFG&quot;);
+    ASSERT_FALSE(reference-&gt;startsWithIgnoringASCIICase(nullptr));
+
+    RefPtr&lt;StringImpl&gt; empty = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;&quot;));
+    ASSERT_FALSE(empty-&gt;startsWithIgnoringASCIICase(nullptr));
+}
+
+TEST(WTF, StringImplStartsWithIgnoringASCIICaseWithEmpty)
+{
+    RefPtr&lt;StringImpl&gt; reference = StringImpl::createFromLiteral(&quot;aBcDeFG&quot;);
+    RefPtr&lt;StringImpl&gt; empty = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;&quot;));
+    ASSERT_TRUE(reference-&gt;startsWithIgnoringASCIICase(empty.get()));
+    ASSERT_TRUE(reference-&gt;startsWithIgnoringASCIICase(*empty.get()));
+    ASSERT_TRUE(empty-&gt;startsWithIgnoringASCIICase(empty.get()));
+    ASSERT_TRUE(empty-&gt;startsWithIgnoringASCIICase(*empty.get()));
+    ASSERT_FALSE(empty-&gt;startsWithIgnoringASCIICase(reference.get()));
+    ASSERT_FALSE(empty-&gt;startsWithIgnoringASCIICase(*reference.get()));
+}
+
+TEST(WTF, StringImplEndsWithIgnoringASCIICaseBasic)
+{
+    RefPtr&lt;StringImpl&gt; reference = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;XÉCbA&quot;));
+    RefPtr&lt;StringImpl&gt; referenceEquivalent = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;xÉcBa&quot;));
+
+    // Identity.
+    ASSERT_TRUE(reference-&gt;endsWithIgnoringASCIICase(reference.get()));
+    ASSERT_TRUE(reference-&gt;endsWithIgnoringASCIICase(*reference.get()));
+    ASSERT_TRUE(reference-&gt;endsWithIgnoringASCIICase(referenceEquivalent.get()));
+    ASSERT_TRUE(reference-&gt;endsWithIgnoringASCIICase(*referenceEquivalent.get()));
+    ASSERT_TRUE(referenceEquivalent-&gt;endsWithIgnoringASCIICase(reference.get()));
+    ASSERT_TRUE(referenceEquivalent-&gt;endsWithIgnoringASCIICase(*reference.get()));
+    ASSERT_TRUE(referenceEquivalent-&gt;endsWithIgnoringASCIICase(referenceEquivalent.get()));
+    ASSERT_TRUE(referenceEquivalent-&gt;endsWithIgnoringASCIICase(*referenceEquivalent.get()));
+
+    // Proper suffixes.
+    RefPtr&lt;StringImpl&gt; aLower = StringImpl::createFromLiteral(&quot;a&quot;);
+    ASSERT_TRUE(reference-&gt;endsWithIgnoringASCIICase(aLower.get()));
+    ASSERT_TRUE(reference-&gt;endsWithIgnoringASCIICase(*aLower.get()));
+    RefPtr&lt;StringImpl&gt; aUpper = StringImpl::createFromLiteral(&quot;a&quot;);
+    ASSERT_TRUE(reference-&gt;endsWithIgnoringASCIICase(aUpper.get()));
+    ASSERT_TRUE(reference-&gt;endsWithIgnoringASCIICase(*aUpper.get()));
+
+    RefPtr&lt;StringImpl&gt; abcLower = StringImpl::createFromLiteral(&quot;cba&quot;);
+    ASSERT_TRUE(reference-&gt;endsWithIgnoringASCIICase(abcLower.get()));
+    ASSERT_TRUE(reference-&gt;endsWithIgnoringASCIICase(*abcLower.get()));
+    RefPtr&lt;StringImpl&gt; abcUpper = StringImpl::createFromLiteral(&quot;CBA&quot;);
+    ASSERT_TRUE(reference-&gt;endsWithIgnoringASCIICase(abcUpper.get()));
+    ASSERT_TRUE(reference-&gt;endsWithIgnoringASCIICase(*abcUpper.get()));
+
+    RefPtr&lt;StringImpl&gt; abcAccentLower = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;Écba&quot;));
+    ASSERT_TRUE(reference-&gt;endsWithIgnoringASCIICase(abcAccentLower.get()));
+    ASSERT_TRUE(reference-&gt;endsWithIgnoringASCIICase(*abcAccentLower.get()));
+    RefPtr&lt;StringImpl&gt; abcAccentUpper = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;ÉCBA&quot;));
+    ASSERT_TRUE(reference-&gt;endsWithIgnoringASCIICase(abcAccentUpper.get()));
+    ASSERT_TRUE(reference-&gt;endsWithIgnoringASCIICase(*abcAccentUpper.get()));
+
+    // Negative cases.
+    RefPtr&lt;StringImpl&gt; differentLastChar = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;XÉCbB&quot;));
+    RefPtr&lt;StringImpl&gt; differentLastCharProperSuffix = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;ÉCbb&quot;));
+    ASSERT_FALSE(reference-&gt;endsWithIgnoringASCIICase(differentLastChar.get()));
+    ASSERT_FALSE(reference-&gt;endsWithIgnoringASCIICase(*differentLastChar.get()));
+    ASSERT_FALSE(reference-&gt;endsWithIgnoringASCIICase(differentLastCharProperSuffix.get()));
+    ASSERT_FALSE(reference-&gt;endsWithIgnoringASCIICase(*differentLastCharProperSuffix.get()));
+
+    RefPtr&lt;StringImpl&gt; lowercaseAccent = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;aBcéX&quot;));
+    RefPtr&lt;StringImpl&gt; loweraseAccentProperSuffix = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;aBcéX&quot;));
+    ASSERT_FALSE(reference-&gt;endsWithIgnoringASCIICase(lowercaseAccent.get()));
+    ASSERT_FALSE(reference-&gt;endsWithIgnoringASCIICase(*lowercaseAccent.get()));
+    ASSERT_FALSE(reference-&gt;endsWithIgnoringASCIICase(loweraseAccentProperSuffix.get()));
+    ASSERT_FALSE(reference-&gt;endsWithIgnoringASCIICase(*loweraseAccentProperSuffix.get()));
+}
+
+TEST(WTF, StringImplEndsWithIgnoringASCIICaseWithNull)
+{
+    RefPtr&lt;StringImpl&gt; reference = StringImpl::createFromLiteral(&quot;aBcDeFG&quot;);
+    ASSERT_FALSE(reference-&gt;endsWithIgnoringASCIICase(nullptr));
+
+    RefPtr&lt;StringImpl&gt; empty = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;&quot;));
+    ASSERT_FALSE(empty-&gt;endsWithIgnoringASCIICase(nullptr));
+}
+
+TEST(WTF, StringImplEndsWithIgnoringASCIICaseWithEmpty)
+{
+    RefPtr&lt;StringImpl&gt; reference = StringImpl::createFromLiteral(&quot;aBcDeFG&quot;);
+    RefPtr&lt;StringImpl&gt; empty = StringImpl::create(reinterpret_cast&lt;const LChar*&gt;(&quot;&quot;));
+    ASSERT_TRUE(reference-&gt;endsWithIgnoringASCIICase(empty.get()));
+    ASSERT_TRUE(reference-&gt;endsWithIgnoringASCIICase(*empty.get()));
+    ASSERT_TRUE(empty-&gt;endsWithIgnoringASCIICase(empty.get()));
+    ASSERT_TRUE(empty-&gt;endsWithIgnoringASCIICase(*empty.get()));
+    ASSERT_FALSE(empty-&gt;endsWithIgnoringASCIICase(reference.get()));
+    ASSERT_FALSE(empty-&gt;endsWithIgnoringASCIICase(*reference.get()));
+}
+
</ins><span class="cx"> } // namespace TestWebKitAPI
</span></span></pre>
</div>
</div>

</body>
</html>