OLD | NEW |
1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> | 1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> |
2 <html> | 2 <html> |
3 <head> | 3 <head> |
4 <script src="../js/resources/js-test-pre.js"></script> | 4 <script src="../js/resources/js-test-pre.js"></script> |
5 </head> | 5 </head> |
6 <body> | 6 <body> |
7 <p>Test for <a href="http://bugs.webkit.org/show_bug.cgi?id=41913">bug 41913</a>
: | 7 <p>Test for <a href="http://bugs.webkit.org/show_bug.cgi?id=41913">bug 41913</a>
: |
8 XPath substring function does not correctly handle non-positive values for the p
osition argument</p> | 8 XPath substring function does not correctly handle non-positive values for the p
osition argument</p> |
9 <div id="console"></div> | 9 <div id="console"></div> |
10 | 10 |
11 <script> | 11 <script> |
12 shouldBe("document.evaluate(\"substring('abcde', 0)\", document, null, XPath
Result.STRING_TYPE, null).stringValue", "'abcde'"); | 12 shouldBe("document.evaluate(\"substring('abcde', 0)\", document, null, XPath
Result.STRING_TYPE, null).stringValue", "'abcde'"); |
13 shouldBe("document.evaluate(\"substring('abcde', -2)\", document, null, XPat
hResult.STRING_TYPE, null).stringValue", "'abcde'"); | 13 shouldBe("document.evaluate(\"substring('abcde', -2)\", document, null, XPat
hResult.STRING_TYPE, null).stringValue", "'abcde'"); |
14 shouldBe("document.evaluate(\"substring('abcde', 0, 5)\", document, null, XP
athResult.STRING_TYPE, null).stringValue", "'abcd'"); | 14 shouldBe("document.evaluate(\"substring('abcde', 0, 5)\", document, null, XP
athResult.STRING_TYPE, null).stringValue", "'abcd'"); |
15 shouldBe("document.evaluate(\"substring('abcde', -2, 5)\", document, null, X
PathResult.STRING_TYPE, null).stringValue", "'ab'"); | 15 shouldBe("document.evaluate(\"substring('abcde', -2, 5)\", document, null, X
PathResult.STRING_TYPE, null).stringValue", "'ab'"); |
16 | 16 |
17 </script> | 17 </script> |
18 <script src="../js/resources/js-test-post.js"></script> | |
19 </body> | 18 </body> |
20 </html> | 19 </html> |
OLD | NEW |