Skip to content

Commit

Permalink
[Reporting/Functional] unskip pagination test (#74973) (#75013)
Browse files Browse the repository at this point in the history
* [Reporting/Functional] unskip pagination test

* change to js file for flaky test runner

* fix ts
  • Loading branch information
tsullivan authored Aug 14, 2020
1 parent 003c5e2 commit 357e0e0
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 11 deletions.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -513,7 +513,6 @@ class ReportListingUi extends Component<Props, State> {
isSelectable={true}
onChange={this.onTableChange}
data-test-subj="reportJobListing"
data-test-page={this.state.page}
/>
{this.state.selectedJobs.length > 0 ? this.renderDeleteButton() : null}
</Fragment>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,7 @@
* you may not use this file except in compliance with the Elastic License.
*/

import { FtrProviderContext } from '../../ftr_provider_context';

export default ({ loadTestFile }: FtrProviderContext) => {
export default ({ loadTestFile }) => {
describe('reporting management app', function () {
this.tags('ciGroup7');
loadTestFile(require.resolve('./report_listing'));
Expand Down
14 changes: 10 additions & 4 deletions x-pack/test/functional/apps/reporting_management/report_listing.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ export default ({ getPageObjects, getService }: FtrProviderContext) => {
const security = getService('security');

const testSubjects = getService('testSubjects');
const findInstance = getService('find');
const esArchiver = getService('esArchiver');

describe('Listing of Reports', function () {
Expand Down Expand Up @@ -68,7 +67,10 @@ export default ({ getPageObjects, getService }: FtrProviderContext) => {
});
});

it.skip('Paginates content', async () => {
it('Paginates historical reports', async () => {
// wait for first row of page 1
await testSubjects.find('checkboxSelectRow-k9a9xlwl0gpe1457b10rraq3');

const previousButton = await testSubjects.find('pagination-button-previous');

// previous CAN NOT be clicked
Expand All @@ -91,7 +93,9 @@ pdf\n2020-04-21 @ 07:00 PM\ntest_user\nCompleted at 2020-04-21 @ 07:00 PM

// click page 2
await testSubjects.click('pagination-button-1');
await findInstance.byCssSelector('[data-test-page="1"]');

// wait for first row of page 2
await testSubjects.find('checkboxSelectRow-k9a9uc4x0gpe1457b16wthc8');

// previous CAN be clicked
expect(await previousButton.getAttribute('disabled')).to.be(null);
Expand All @@ -112,7 +116,9 @@ report2csv\nsearch\n2020-04-21 @ 06:54 PM\ntest_user\nCompleted at 2020-04-21 @

// click page 3
await testSubjects.click('pagination-button-2');
await findInstance.byCssSelector('[data-test-page="2"]');

// wait for first row of page 3
await testSubjects.find('checkboxSelectRow-k9a9p1840gpe1457b1ghfxw5');

// scan page 3
tableText = await getTableTextFromElement(await testSubjects.find('reportJobListing'));
Expand Down

0 comments on commit 357e0e0

Please sign in to comment.