Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(298)

Side by Side Diff: LayoutTests/fast/js/var-declarations-shadowing.html

Issue 242613009: Make window.history property non replaceable (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 <p> 1 <p>
2 This page tests var declarations that attempt to shadow interesting global prope rties in 2 This page tests var declarations that attempt to shadow interesting global prope rties in
3 interesting ways. <a href="http://bugs.webkit.org/show_bug.cgi?id=16644">Bug 166 44</a>. 3 interesting ways. <a href="http://bugs.webkit.org/show_bug.cgi?id=16644">Bug 166 44</a>.
4 </p> 4 </p>
5 5
6 <p> 6 <p>
7 If the test passes, you'll see a series of PASS messages below. 7 If the test passes, you'll see a series of PASS messages below.
8 </p> 8 </p>
9 9
10 <pre id="console"></pre> 10 <pre id="console"></pre>
(...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after
249 249
250 try { 250 try {
251 eval("var screen = marker"); 251 eval("var screen = marker");
252 } catch(e) { } 252 } catch(e) { }
253 shouldBe(screen == marker, "screen == marker", false); 253 shouldBe(screen == marker, "screen == marker", false);
254 shouldBe(eval('screen == marker'), "eval('screen == marker')", false); 254 shouldBe(eval('screen == marker'), "eval('screen == marker')", false);
255 255
256 try { 256 try {
257 eval("var history = marker"); 257 eval("var history = marker");
258 } catch(e) { } 258 } catch(e) { }
259 shouldBe(history == marker, "history == marker", true); 259 shouldBe(history == marker, "history == marker", false);
260 shouldBe(eval('history == marker'), "eval('history == marker')", true); 260 shouldBe(eval('history == marker'), "eval('history == marker')", false);
261 261
262 log("-----"); 262 log("-----");
263 263
264 try { 264 try {
265 eval("var frameElement = marker"); 265 eval("var frameElement = marker");
266 } catch(e) { } 266 } catch(e) { }
267 shouldBe(frameElement == marker, "frameElement == marker", false); 267 shouldBe(frameElement == marker, "frameElement == marker", false);
268 shouldBe(eval('frameElement == marker'), "eval('frameElement == marker')", false ); 268 shouldBe(eval('frameElement == marker'), "eval('frameElement == marker')", false );
269 269
270 try { 270 try {
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
303 shouldBe(crypto == marker, "crypto == marker", false); 303 shouldBe(crypto == marker, "crypto == marker", false);
304 shouldBe(eval('crypto == marker'), "eval('crypto == marker')", false); 304 shouldBe(eval('crypto == marker'), "eval('crypto == marker')", false);
305 305
306 try { 306 try {
307 eval("var top = marker"); 307 eval("var top = marker");
308 } catch(e) { } 308 } catch(e) { }
309 shouldBe(top == marker, "top == marker", false); 309 shouldBe(top == marker, "top == marker", false);
310 shouldBe(eval('top == marker'), "eval('top == marker')", false); 310 shouldBe(eval('top == marker'), "eval('top == marker')", false);
311 311
312 </script> 312 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698