OLD | NEW |
1 description("This tests the constructor property of DOM objects: http://bugs.web
kit.org/show_bug.cgi?id=11315"); | 1 description("This tests the constructor property of DOM objects: http://bugs.web
kit.org/show_bug.cgi?id=11315"); |
2 | 2 |
3 shouldBeFalse("window.document.constructor === window.Object"); | 3 shouldBeFalse("window.document.constructor === window.Object"); |
4 shouldBeTrue("window.document.constructor === window.HTMLDocument"); | 4 shouldBeTrue("window.document.constructor === window.HTMLDocument"); |
5 shouldBeTrue("window.document.constructor.prototype === window.HTMLDocument.prot
otype"); | 5 shouldBeTrue("window.document.constructor.prototype === window.HTMLDocument.prot
otype"); |
6 shouldBeTrue("window.document.constructor.prototype.__proto__ === window.HTMLDoc
ument.prototype.__proto__"); | 6 shouldBeTrue("window.document.constructor.prototype.__proto__ === window.HTMLDoc
ument.prototype.__proto__"); |
7 shouldBeTrue("window.document.constructor.prototype.__proto__ === window.Documen
t.prototype"); | 7 shouldBeTrue("window.document.constructor.prototype.__proto__ === window.Documen
t.prototype"); |
8 | 8 |
9 shouldBeTrue("window.document.body.constructor === window.HTMLBodyElement"); | 9 shouldBeTrue("window.document.body.constructor === window.HTMLBodyElement"); |
10 shouldBeTrue("window.document.body.constructor.prototype === window.HTMLBodyElem
ent.prototype"); | 10 shouldBeTrue("window.document.body.constructor.prototype === window.HTMLBodyElem
ent.prototype"); |
11 shouldBeTrue("window.document.body.constructor.prototype.__proto__ === window.HT
MLBodyElement.prototype.__proto__"); | 11 shouldBeTrue("window.document.body.constructor.prototype.__proto__ === window.HT
MLBodyElement.prototype.__proto__"); |
12 shouldBeTrue("window.document.body.constructor.prototype.__proto__ === window.HT
MLElement.prototype"); | 12 shouldBeTrue("window.document.body.constructor.prototype.__proto__ === window.HT
MLElement.prototype"); |
13 | 13 |
14 var nodeList = document.getElementsByTagName('script'); | 14 var htmlCollection = document.getElementsByTagName('script'); |
15 shouldBeTrue("nodeList.constructor === window.NodeList"); | 15 shouldBeTrue("htmlCollection.constructor === window.HTMLCollection"); |
16 shouldBeTrue("nodeList.constructor.prototype === window.NodeList.prototype"); | 16 shouldBeTrue("htmlCollection.constructor.prototype === window.HTMLCollection.pro
totype"); |
17 | 17 |
18 var mutationEvent = document.createEvent("MutationEvent"); | 18 var mutationEvent = document.createEvent("MutationEvent"); |
19 shouldBeTrue("mutationEvent.constructor === window.MutationEvent"); | 19 shouldBeTrue("mutationEvent.constructor === window.MutationEvent"); |
20 shouldBeTrue("mutationEvent.constructor.prototype.__proto__ === window.Event.pro
totype"); | 20 shouldBeTrue("mutationEvent.constructor.prototype.__proto__ === window.Event.pro
totype"); |
OLD | NEW |