<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
- <link rel="stylesheet" href="../../js/resources/js-test-style.css">
<script src="../../js/resources/js-test-pre.js"></script>
</head>
<body>
reset();
- description("This test makes sure that we don't allow calling the window moving and resizing\
- methods with less than 2 arguments and that we do allow calling them with more.");
+ description("This test makes sure that calling the window moving and resizing\
+ methods with less than 2 arguments treats the missing arguments as 0.");
// resizeTo /////////////////////////
debug('');
debug("Testing - resizeTo with 1 argument");
window.resizeTo(x);
- shouldBe('window.outerWidth', 'resetWidth');
+ shouldBe('window.outerWidth', 'width');
shouldBe('window.outerHeight', 'resetHeight');
reset();
debug("Testing - resizeBy with 1 argument");
window.resizeBy(x);
- shouldBe('window.outerWidth', 'resetWidth');
+ shouldBe('window.outerWidth', 'resetWidth + x');
shouldBe('window.outerHeight', 'resetHeight');
reset();
debug("Testing - moveTo with 1 argument");
window.moveTo(x);
- shouldBe('window.screenX', 'resetX');
+ shouldBe('window.screenX', 'resetX + x');
shouldBe('window.screenY', 'resetY');
reset();
debug("Testing - moveBy with 1 argument");
window.moveBy(x);
- shouldBe('window.screenX', 'resetX');
+ shouldBe('window.screenX', 'resetX + x');
shouldBe('window.screenY', 'resetY');
reset();
window.moveBy(x, y, 200, "text");
shouldBe('window.screenX', 'resetX + x');
shouldBe('window.screenY', 'resetY + y');
-
- var successfullyParsed = true;
</script>
<script src="../../js/resources/js-test-post.js"></script>
</body>