OLD | NEW |
1 This is a test case for String.prototype.link(href). | 1 This is a test case for String.prototype.link(href). |
2 | 2 |
3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
". | 3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
". |
4 | 4 |
5 | 5 |
6 PASS '_'.link('"') is "<a href=\""\">_</a>" | 6 PASS '_'.link('"') is "<a href=\""\">_</a>" |
7 PASS '_'.link('b') is "<a href=\"b\">_</a>" | 7 PASS '_'.link('b') is "<a href=\"b\">_</a>" |
8 PASS '<'.link('b') is "<a href=\"b\"><</a>" | 8 PASS '<'.link('b') is "<a href=\"b\"><</a>" |
9 PASS '_'.link(0x2A) is "<a href=\"42\">_</a>" | 9 PASS '_'.link(0x2A) is "<a href=\"42\">_</a>" |
10 PASS '_'.link('"') is "<a href=\""\">_</a>" | 10 PASS '_'.link('"') is "<a href=\""\">_</a>" |
11 PASS '_'.link('" target="_blank') is "<a href=\"" target="_blank\">_</
a>" | 11 PASS '_'.link('" target="_blank') is "<a href=\"" target="_blank\">_</
a>" |
12 PASS String.prototype.link.call(0x2A, 0x2A) is "<a href=\"42\">42</a>" | 12 PASS String.prototype.link.call(0x2A, 0x2A) is "<a href=\"42\">42</a>" |
13 PASS String.prototype.link.call(undefined) threw exception TypeError: Type error
. | 13 FAIL String.prototype.link.call(undefined) should throw TypeError: Type error. W
as <a href="undefined">undefined</a>. |
14 PASS String.prototype.link.call(null) threw exception TypeError: Type error. | 14 FAIL String.prototype.link.call(null) should throw TypeError: Type error. Was <a
href="undefined">null</a>. |
15 PASS String.prototype.link.length is 1 | 15 PASS String.prototype.link.length is 1 |
16 PASS successfullyParsed is true | 16 PASS successfullyParsed is true |
17 | 17 |
18 TEST COMPLETE | 18 TEST COMPLETE |
19 | 19 |
OLD | NEW |