| 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="../../../resources/js-test.js"></script> | 4 <script src="../../resources/js-test.js"></script> |
| 5 </head> | 5 </head> |
| 6 <body> | 6 <body> |
| 7 <script> | 7 <script> |
| 8 description('Test the behavior of multiple base elements.'); | 8 description('Test the behavior of multiple base elements.'); |
| 9 | 9 |
| 10 var originalBase = document.URL.replace(/[^/]*$/, ""); | 10 var originalBase = document.URL.replace(/[^/]*$/, ""); |
| 11 | 11 |
| 12 function clean(url) | 12 function clean(url) |
| 13 { | 13 { |
| 14 if (url.length < originalBase.length) | 14 if (url.length < originalBase.length) |
| (...skipping 28 matching lines...) Expand all Loading... |
| 43 shouldBe("document.head.appendChild(base), document.head.appendChild(base2), cle
an(anchor.href)", "'http://domain.com/base/file'"); | 43 shouldBe("document.head.appendChild(base), document.head.appendChild(base2), cle
an(anchor.href)", "'http://domain.com/base/file'"); |
| 44 shouldBe("base.removeAttribute('href'), clean(anchor.href)", "'http://domain.com
/base2/file'"); | 44 shouldBe("base.removeAttribute('href'), clean(anchor.href)", "'http://domain.com
/base2/file'"); |
| 45 shouldBe("document.head.appendChild(base3), clean(anchor.href)", "'http://domain
.com/base2/file'"); | 45 shouldBe("document.head.appendChild(base3), clean(anchor.href)", "'http://domain
.com/base2/file'"); |
| 46 | 46 |
| 47 document.head.removeChild(base); | 47 document.head.removeChild(base); |
| 48 document.head.removeChild(base2); | 48 document.head.removeChild(base2); |
| 49 document.head.removeChild(base3); | 49 document.head.removeChild(base3); |
| 50 </script> | 50 </script> |
| 51 </body> | 51 </body> |
| 52 </html> | 52 </html> |
| OLD | NEW |