Skip to content

Commit

Permalink
Fix ie_driver tests to assert that isInParentOverflow returns a parti…
Browse files Browse the repository at this point in the history
…cular value. It doesn't return a boolean, so passing it directly to assertTrue/assertFalse was an error.

On behalf of juangj.
  • Loading branch information
sevaseva committed Sep 12, 2014
1 parent b1a6a33 commit d53e906
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions javascript/ie-driver/test/parent_overflow_test.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
<title>parent_overflow_test.html</title>
<script src="test_bootstrap.js"></script>
<script type="text/javascript">
goog.require('bot.dom.OverflowState');
goog.require('bot.locators');
goog.require('goog.testing.jsunit');
goog.require('webdriver.ie');
Expand All @@ -18,15 +19,15 @@

function testScrollElementInToView() {
var element = bot.locators.findElement({ id: 'line8' });
assertTrue(webdriver.ie.isInParentOverflow(element));
assertEquals(bot.dom.OverflowState.SCROLL, webdriver.ie.isInParentOverflow(element));
element.scrollIntoView(false);
assertFalse(webdriver.ie.isInParentOverflow(element));
assertEquals(bot.dom.OverflowState.NONE, webdriver.ie.isInParentOverflow(element));

// Verify scroll is correct for up and to the left.
var element = bot.locators.findElement({ id: 'line1' });
assertTrue(webdriver.ie.isInParentOverflow(element));
assertEquals(bot.dom.OverflowState.SCROLL, webdriver.ie.isInParentOverflow(element));
element.scrollIntoView(false);
assertFalse(webdriver.ie.isInParentOverflow(element));
assertEquals(bot.dom.OverflowState.NONE, webdriver.ie.isInParentOverflow(element));
}
</script>
<div style="height: 150px"></div>
Expand Down

0 comments on commit d53e906

Please sign in to comment.