| OLD | NEW | 
| (Empty) |  | 
 |   1 <!doctype html> | 
 |   2 <meta charset=utf-8> | 
 |   3 <title>Indexed properties of the window object (strict mode)</title> | 
 |   4 <link rel="author" title="Ms2ger" href="ms2ger@gmail.com"> | 
 |   5 <link rel="help" href="https://html.spec.whatwg.org/multipage/#window"> | 
 |   6 <link rel="help" href="https://html.spec.whatwg.org/multipage/#dom-window-item"> | 
 |   7 <link rel="help" href="https://heycam.github.io/webidl/#getownproperty"> | 
 |   8 <link rel="help" href="https://heycam.github.io/webidl/#defineownproperty"> | 
 |   9 <script src="../../../../../resources/testharness.js"></script> | 
 |  10 <script src="../../../../../resources/testharnessreport.js"></script> | 
 |  11 <div id=log></div> | 
 |  12 <iframe></iframe> | 
 |  13 <script> | 
 |  14 test(function() { | 
 |  15   "use strict"; | 
 |  16   assert_false("-1" in window, "-1 not in window"); | 
 |  17   assert_equals(window[-1], undefined); | 
 |  18   window[-1] = "foo"; | 
 |  19   assert_equals(window[-1], "foo"); | 
 |  20 }); | 
 |  21 test(function() { | 
 |  22   "use strict"; | 
 |  23   assert_throws(new TypeError(), function() { | 
 |  24     window[0] = "foo"; | 
 |  25   }); | 
 |  26   assert_equals(window[0], | 
 |  27                 document.getElementsByTagName("iframe")[0].contentWindow); | 
 |  28 }); | 
 |  29 test(function() { | 
 |  30   "use strict"; | 
 |  31   assert_throws(new TypeError(), function() { | 
 |  32     window[1] = "foo"; | 
 |  33   }); | 
 |  34   assert_equals(window[1], undefined); | 
 |  35 }); | 
 |  36 test(function() { | 
 |  37   "use strict"; | 
 |  38   var proto = Window.prototype; | 
 |  39   [-1, 0, 1].forEach(function(idx) { | 
 |  40     assert_false(idx in proto, idx + " in proto"); | 
 |  41   }); | 
 |  42 }); | 
 |  43 </script> | 
| OLD | NEW |