Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / xpath / empty-string-substring.html
blob5c5c9253830f3496ba97d6668b0a3e1c2642f624
1 <p>Test for <a href="http://bugs.webkit.org/show_bug.cgi?id=11815">bug 11815</a>:
2 XPathEvaluator behavior does not match Firefox - substring() and empty element.</p>
3 <script>
4 if (window.testRunner)
5 testRunner.dumpAsText();
7 var strXML = '<data><record></record><record>-hi-</record></data>';
8 var doc = (new DOMParser()).parseFromString(strXML, "text/xml");
9 var xpe = new XPathEvaluator();
10 var objResult = xpe.evaluate("//record[substring(.,1,1)='-']", doc, null, 0, null);
11 var itm = null;
12 var objNodes = [];
13 while (itm = objResult.iterateNext()) objNodes.push(itm);
15 if (objNodes.length == 1)
16 document.write("SUCCESS");
17 else
18 document.write("FAILURE: matched " + objNodes.length + " nodes.");
19 </script>