Skip to content

Commit

Permalink
fixes pagination tests (#51822) (#51830)
Browse files Browse the repository at this point in the history
  • Loading branch information
MadameSheema authored Nov 28, 2019
1 parent 5167d38 commit ffe067a
Showing 1 changed file with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,19 +23,19 @@ describe('Pagination', () => {
return logout();
});

it.skip('pagination updates results and page number', () => {
it('pagination updates results and page number', () => {
loginAndWaitForPage(HOSTS_PAGE_TAB_URLS.uncommonProcesses);
waitForTableLoad(UNCOMMON_PROCCESSES_TABLE);
cy.get(getPageButtonSelector(0)).should('have.class', 'euiPaginationButton-isActive');

cy.get(getDraggableField('user.name'))
cy.get(getDraggableField('process.name'))
.first()
.invoke('text')
.then(text1 => {
cy.get(getPageButtonSelector(2)).click({ force: true });
// wait for table to be done loading
waitForTableLoad(UNCOMMON_PROCCESSES_TABLE);
cy.get(getDraggableField('user.name'))
cy.get(getDraggableField('process.name'))
.first()
.invoke('text')
.should(text2 => {
Expand All @@ -55,7 +55,7 @@ describe('Pagination', () => {
// wait for table to be done loading
waitForTableLoad(UNCOMMON_PROCCESSES_TABLE);

cy.get(getDraggableField('user.name'))
cy.get(getDraggableField('process.name'))
.first()
.invoke('text')
.then(text2 => {
Expand All @@ -70,7 +70,7 @@ describe('Pagination', () => {
waitForTableLoad(UNCOMMON_PROCCESSES_TABLE);
// check uncommon processes table picks up at 3
cy.get(getPageButtonSelector(2)).should('have.class', 'euiPaginationButton-isActive');
cy.get(getDraggableField('user.name'))
cy.get(getDraggableField('process.name'))
.first()
.invoke('text')
.should(text1 => {
Expand All @@ -82,7 +82,7 @@ describe('Pagination', () => {
* We only want to comment this code/test for now because it can be nondeterministic
* when we figure out a way to really mock the data, we should come back to it
*/
it.skip('pagination resets results and page number to first page when refresh is clicked', () => {
it('pagination resets results and page number to first page when refresh is clicked', () => {
loginAndWaitForPage(HOSTS_PAGE_TAB_URLS.uncommonProcesses);
cy.get(NUMBERED_PAGINATION, { timeout: DEFAULT_TIMEOUT });
cy.get(getPageButtonSelector(0)).should('have.class', 'euiPaginationButton-isActive');
Expand All @@ -100,7 +100,7 @@ describe('Pagination', () => {
.last()
.click({ force: true });
waitForTableLoad(UNCOMMON_PROCCESSES_TABLE);
cy.get(getPageButtonSelector(0)).should('have.class', 'euiPaginationButton-isActive');
cy.get(getPageButtonSelector(2)).should('have.class', 'euiPaginationButton-isActive');
// cy.get(getDraggableField('user.name'))
// .first()
// .invoke('text')
Expand Down

0 comments on commit ffe067a

Please sign in to comment.