Skip to content

Commit

Permalink
Remove flaky functional test.
Browse files Browse the repository at this point in the history
  • Loading branch information
justinkambic committed Jun 8, 2020
1 parent 0eea5fd commit 09bf4b3
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 67 deletions.
4 changes: 0 additions & 4 deletions x-pack/test/functional/page_objects/uptime_page.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,6 @@ export function UptimePageProvider({ getPageObjects, getService }: FtrProviderCo
}
}

public async goToUptimeOverview() {
return navigation.goToUptime();
}

public async goToUptimeOverviewAndLoadData(
dateStart: string,
dateEnd: string,
Expand Down
33 changes: 7 additions & 26 deletions x-pack/test/functional/services/uptime/alerts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,39 +9,20 @@ import { FtrProviderContext } from '../../ftr_provider_context';
export function UptimeAlertsProvider({ getService }: FtrProviderContext) {
const testSubjects = getService('testSubjects');
const browser = getService('browser');
const retry = getService('retry');

return {
async openFlyout(alertType: 'monitorStatus' | 'tls') {
await retry.try(
async () => {
await testSubjects.click('xpack.uptime.alertsPopover.toggleButton');
await testSubjects.click('xpack.uptime.openAlertContextPanel');
if (alertType === 'monitorStatus') {
await testSubjects.existOrFail('xpack.uptime.toggleAlertFlyout');
await testSubjects.click('xpack.uptime.toggleAlertFlyout');
} else if (alertType === 'tls') {
await testSubjects.click('xpack.uptime.toggleTlsAlertFlyout');
}
},
async () => {
await browser.refresh();
}
);
await testSubjects.click('xpack.uptime.alertsPopover.toggleButton', 5000);
await testSubjects.click('xpack.uptime.openAlertContextPanel', 5000);
if (alertType === 'monitorStatus') {
await testSubjects.click('xpack.uptime.toggleAlertFlyout', 5000);
} else if (alertType === 'tls') {
await testSubjects.click('xpack.uptime.toggleTlsAlertFlyout');
}
},
async openMonitorStatusAlertType(alertType: string) {
return testSubjects.click(`xpack.uptime.alerts.${alertType}-SelectOption`, 5000);
},
async assertTlsFieldExists(id: string) {
return testSubjects.existOrFail(`xpack.uptime.alerts.tls.expressionPopover.${id}`, {
timeout: 15 * 1000,
});
},
async assertMonitorStatusFlyoutSearchBarExists() {
return testSubjects.existOrFail('xpack.uptime.alerts.monitorStatus.filterBar', {
timeout: 15 * 1000,
});
},
async setAlertTags(tags: string[]) {
for (let i = 0; i < tags.length; i += 1) {
await testSubjects.click('comboBoxSearchInput', 5000);
Expand Down
36 changes: 0 additions & 36 deletions x-pack/test/functional_with_es_ssl/apps/uptime/flyout_loads.ts

This file was deleted.

1 change: 0 additions & 1 deletion x-pack/test/functional_with_es_ssl/apps/uptime/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ export default ({ getService, loadTestFile }: FtrProviderContext) => {
after(async () => await esArchiver.unload(ARCHIVE));

loadTestFile(require.resolve('./alert_flyout'));
loadTestFile(require.resolve('./flyout_loads'));
});
});
};

0 comments on commit 09bf4b3

Please sign in to comment.