Skip to content

Commit

Permalink
wait for page to reload
Browse files Browse the repository at this point in the history
  • Loading branch information
wildone committed Feb 16, 2021
1 parent 284105a commit c9b17bc
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,14 @@ class ContactListPaginationPublishSpec extends ComponentSpec {
and: "Can select page 2"
scrollIntoView($("${selector} .pagination").firstElement())
$("${selector} .pagination .next a").click()
waitForDocumentReady()
assert $("${selector} .pagination .current").text().trim() == "2"
takeScreenshot($(selector).firstElement(), "The component should be on second page")

and: "Can select page 3"
scrollIntoView($("${selector} .pagination").firstElement())
$("${selector} .pagination .next a").click()
waitForDocumentReady()
assert $("${selector} .pagination .current").text().trim() == "3"
takeScreenshot($(selector).firstElement(), "The component should be on third page")

Expand All @@ -64,6 +66,7 @@ class ContactListPaginationPublishSpec extends ComponentSpec {
and: "Can select previous page"
scrollIntoView($("${selector} .pagination").firstElement())
$("${selector} .pagination .previous a").click()
waitForDocumentReady()
assert $("${selector} .pagination .current").text().trim() == "2"
takeScreenshot($(selector).firstElement(), "The component should be on forth page")

Expand Down

0 comments on commit c9b17bc

Please sign in to comment.