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

Unified Diff: LayoutTests/fast/dom/Window/window-resize-and-move-arguments.html

Issue 886463010: Make arguments to window.{move,resize}{To,By} non-optional (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: rebased Created 5 years, 6 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 side-by-side diff with in-line comments
Download patch
Index: LayoutTests/fast/dom/Window/window-resize-and-move-arguments.html
diff --git a/LayoutTests/fast/dom/Window/window-resize-and-move-arguments.html b/LayoutTests/fast/dom/Window/window-resize-and-move-arguments.html
index 01693ef4713335994e3ec1924b39022b621f8fab..1906d031591d942063a299be68d7b2bcc965bb20 100644
--- a/LayoutTests/fast/dom/Window/window-resize-and-move-arguments.html
+++ b/LayoutTests/fast/dom/Window/window-resize-and-move-arguments.html
@@ -39,14 +39,14 @@
debug('');
debug("Testing - resizeTo with 0 arguments");
- window.resizeTo();
+ shouldThrow('window.resizeTo()');
shouldBe('window.outerWidth', 'resetWidth');
shouldBe('window.outerHeight', 'resetHeight');
reset();
debug("Testing - resizeTo with 1 argument");
- window.resizeTo(x);
- shouldBe('window.outerWidth', 'width');
+ shouldThrow('window.resizeTo(width)');
+ shouldBe('window.outerWidth', 'resetWidth');
shouldBe('window.outerHeight', 'resetHeight');
reset();
@@ -62,14 +62,14 @@
debug('');
debug("Testing - resizeBy with 0 arguments");
- window.resizeBy();
+ shouldThrow('window.resizeBy()');
shouldBe('window.outerWidth', 'resetWidth');
shouldBe('window.outerHeight', 'resetHeight');
reset();
debug("Testing - resizeBy with 1 argument");
- window.resizeBy(x);
- shouldBe('window.outerWidth', 'resetWidth + x');
+ shouldThrow('window.resizeBy(x)');
+ shouldBe('window.outerWidth', 'resetWidth');
shouldBe('window.outerHeight', 'resetHeight');
reset();
@@ -86,14 +86,14 @@
debug('');
debug("Testing - moveTo with 0 arguments");
- window.moveTo();
+ shouldThrow('window.moveTo()');
shouldBe('window.screenX', 'resetX');
shouldBe('window.screenY', 'resetY');
reset();
debug("Testing - moveTo with 1 argument");
- window.moveTo(x);
- shouldBe('window.screenX', 'Math.max(x, screen.availLeft)');
+ shouldThrow('window.moveTo(x)');
+ shouldBe('window.screenX', 'resetX');
shouldBe('window.screenY', 'resetY');
reset();
@@ -111,14 +111,14 @@
debug('');
debug("Testing - moveBy with 0 arguments");
- window.moveBy();
+ shouldThrow('window.moveBy()');
shouldBe('window.screenX', 'resetX');
shouldBe('window.screenY', 'resetY');
reset();
debug("Testing - moveBy with 1 argument");
- window.moveBy(x);
- shouldBe('window.screenX', 'resetX + x');
+ shouldThrow('window.moveBy(x)');
+ shouldBe('window.screenX', 'resetX');
shouldBe('window.screenY', 'resetY');
reset();

Powered by Google App Engine
This is Rietveld 408576698