Refactor tasksListPage (#3952)

This commit is contained in:
cristinaj
2018-11-09 12:17:53 +02:00
committed by Eugenio Romano
parent 93578baecd
commit 536467f0ee
23 changed files with 232 additions and 229 deletions

View File

@@ -81,7 +81,7 @@ describe('Items per page set to 15 and adding of tasks', () => {
expect(paginationPage.getCurrentPage()).toEqual('Page ' + currentPage);
expect(paginationPage.getTotalPages()).toEqual('of ' + totalPages);
expect(paginationPage.getPaginationRange()).toEqual('Showing 1-' + itemsPerPage.fifteenValue + ' of ' + (nrOfTasks - 5));
expect(taskPage.getAllDisplayedRows()).toBe(itemsPerPage.fifteenValue);
expect(taskPage.tasksListPage().getDataTable().getNumberOfRows()).toBe(itemsPerPage.fifteenValue);
browser.controlFlow().execute(async () => {
for (i; i < nrOfTasks; i++) {
@@ -95,7 +95,7 @@ describe('Items per page set to 15 and adding of tasks', () => {
expect(paginationPage.getCurrentPage()).toEqual('Page ' + currentPage);
expect(paginationPage.getTotalPages()).toEqual('of ' + totalPages);
expect(paginationPage.getPaginationRange()).toEqual('Showing 16-' + nrOfTasks + ' of ' + nrOfTasks);
expect(taskPage.getAllDisplayedRows()).toBe(nrOfTasks - itemsPerPage.fifteenValue);
expect(taskPage.tasksListPage().getDataTable().getNumberOfRows()).toBe(nrOfTasks - itemsPerPage.fifteenValue);
paginationPage.checkNextPageButtonIsDisabled();
paginationPage.checkPreviousPageButtonIsEnabled();
});