[ftr/pageObjects/security] try simplified logout check to avoid flakiness (#28893)

* [ftr/pageObjects/security] try simplified logout check to avoid flakiness

* [pageObjects/security] wait for longer than normal
This commit is contained in:
Spencer 2019-01-17 15:19:42 -08:00 committed by GitHub
parent 93930326de
commit 4911fb1ce8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -95,18 +95,9 @@ export function SecurityPageProvider({ getService, getPageObjects }) {
await find.clickByLinkText('Logout');
await retry.try(async () => {
const loginFormExists = await find.existsByDisplayedByCssSelector('.login-form');
const logoutLinkExists = await find.existsByLinkText('Logout');
if (logoutLinkExists) {
await find.clickByLinkText('Logout');
}
if (!loginFormExists) {
throw new Error('Logout is not completed yet');
}
});
await retry.waitForWithTimeout('login form', config.get('timeouts.waitFor') * 5, async () => (
await find.existsByDisplayedByCssSelector('.login-form')
));
}
async clickRolesSection() {