Commit 1b7d5f34 by Waqas Khalid Committed by Dennis Jen

Test pagination reposition test is failing

Test pagination reposition test is failing on release
and master. It was flaky test and this problem was
caused by the javascript animation. Issue was fixed by
adding the promise that we check the value of window
top after the animation is completed.
parent dd2d1912
...@@ -406,12 +406,24 @@ class DiscussionUserProfilePage(CoursePage): ...@@ -406,12 +406,24 @@ class DiscussionUserProfilePage(CoursePage):
def click_prev_page(self): def click_prev_page(self):
self._click_pager_with_text(self.TEXT_PREV, self.get_current_page() - 1) self._click_pager_with_text(self.TEXT_PREV, self.get_current_page() - 1)
EmptyPromise(
self.is_window_on_top,
"Window is on top"
).fulfill()
def click_next_page(self): def click_next_page(self):
self._click_pager_with_text(self.TEXT_NEXT, self.get_current_page() + 1) self._click_pager_with_text(self.TEXT_NEXT, self.get_current_page() + 1)
EmptyPromise(
self.is_window_on_top,
"Window is on top"
).fulfill()
def click_on_page(self, page_number): def click_on_page(self, page_number):
self._click_pager_with_text(unicode(page_number), page_number) self._click_pager_with_text(unicode(page_number), page_number)
EmptyPromise(
self.is_window_on_top,
"Window is on top"
).fulfill()
class DiscussionTabHomePage(CoursePage, DiscussionPageMixin): class DiscussionTabHomePage(CoursePage, DiscussionPageMixin):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment