Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / dom / Window / es52-globals.html
blob6ecf26c088a559d91628b75e5329af5c64f181bd
1 <!DOCTYPE html>
2 <script src="../../../resources/js-test.js"></script>
3 <div id="div"></div>
4 <iframe name="f"></iframe>
5 <a href="http://webkit.org" name="a"></a>
6 <script>
8 window.x = 1;
9 Object.getPrototypeOf(window).y = 2;
11 </script>
12 <script>
14 shouldBeTrue('window.hasOwnProperty("Element")');
15 shouldBeTrue('window.hasOwnProperty("x")');
16 shouldBeFalse('window.hasOwnProperty("y")');
17 shouldBeTrue('window.hasOwnProperty("f")');
18 shouldBeTrue('window.hasOwnProperty("div")');
19 shouldBeTrue('window.hasOwnProperty("a")');
21 </script>
22 <script>
24 var Element;
25 shouldNotBe('Element', 'undefined');
27 var x;
28 shouldBe('x', '1');
30 var y;
31 shouldBeUndefined('y');
33 var f;
34 shouldBeUndefined('f');
36 var div;
37 shouldBeUndefined('div');
39 var a;
40 shouldBeUndefined('a');
42 </script>