Wait longer for load discover search (#19265)

This commit is contained in:
Tim Roes 2018-05-22 13:27:54 +02:00 committed by GitHub
parent 0ab9703287
commit f84d57afd7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -55,7 +55,12 @@ export function DiscoverPageProvider({ getService, getPageObjects }) {
async openSavedSearch() {
await this.clickLoadSavedSearchButton();
await testSubjects.exists('loadSearchForm');
await retry.try(async () => {
const isLoadFormVisible = await testSubjects.exists('loadSearchForm');
if (!isLoadFormVisible) {
throw new Error('Load search form not visible yet.');
}
});
}
async hasSavedSearch(searchName) {