Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert "Comment out failing ISM test" #1614

Open
wants to merge 1 commit into
base: 2.18
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -500,45 +500,44 @@ describe('Indices', () => {
});
});

// TODO: FIX THIS TEST
// it('successfully open an index', () => {
// // Confirm we have our initial index
// cy.contains(SAMPLE_INDEX);

// cy.get('[data-test-subj="moreAction"]').click();
// // Open btn should be disabled if no items selected
// cy.get('[data-test-subj="Open Action"]').should(
// 'have.class',
// 'euiContextMenuItem-isDisabled'
// );

// // Select an index
// cy.get(`[data-test-subj="checkboxSelectRow-${SAMPLE_INDEX}"]`).check({
// force: true,
// });

// cy.get('[data-test-subj="moreAction"]').click();
// // Open btn should be enabled
// cy.get('[data-test-subj="Open Action"]')
// .should('exist')
// .should('not.have.class', 'euiContextMenuItem-isDisabled')
// .click();

// // Check for open index modal
// cy.contains('Open');

// cy.get('[data-test-subj="Open Confirm button"]').click();

// // Check for success toast
// cy.contains(/sample_index have been opened/);

// // Confirm the index is open
// cy.get(`input[type="search"]`).focus().type(SAMPLE_INDEX);
// cy.get('tbody > tr').should(($tr) => {
// expect($tr, '1 row').to.have.length(1);
// expect($tr, 'item').to.contain('open');
// });
// });
it('successfully open an index', () => {
// Confirm we have our initial index
cy.contains(SAMPLE_INDEX);

cy.get('[data-test-subj="moreAction"]').click();
// Open btn should be disabled if no items selected
cy.get('[data-test-subj="Open Action"]').should(
'have.class',
'euiContextMenuItem-isDisabled'
);

// Select an index
cy.get(`[data-test-subj="checkboxSelectRow-${SAMPLE_INDEX}"]`).check({
force: true,
});

cy.get('[data-test-subj="moreAction"]').click();
// Open btn should be enabled
cy.get('[data-test-subj="Open Action"]')
.should('exist')
.should('not.have.class', 'euiContextMenuItem-isDisabled')
.click();

// Check for open index modal
cy.contains('Open');

cy.get('[data-test-subj="Open Confirm button"]').click();

// Check for success toast
cy.contains(/sample_index have been opened/);

// Confirm the index is open
cy.get(`input[type="search"]`).focus().type(SAMPLE_INDEX);
cy.get('tbody > tr').should(($tr) => {
expect($tr, '1 row').to.have.length(1);
expect($tr, 'item').to.contain('open');
});
});
});

describe('can clear cache for indexes', () => {
Expand Down
Loading