Skip to content

Commit ab481d8

Browse files
committed
hack to retry
1 parent b190dcc commit ab481d8

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

scripts/pit/its/cc-identity-management.js

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,14 @@ const {log, err, args, createPage, closePage, takeScreenshot, waitForServerReady
4747
// Button is enabled after app is running, let's see
4848
await page.getByRole('link', { name: 'Identity Management' }).click();
4949
await takeScreenshot(page, __filename, 'identity-link-clicked');
50-
await page.getByRole('button', { name: 'Enable Identity Management' }).click();
50+
try {
51+
await page.getByRole('button', { name: 'Enable Identity Management' }).click();
52+
} catch (error) {
53+
err(`Retrying in 60 secs looking for enabled button : ${error}\n`);
54+
await page.waitForTimeout(60000);
55+
await page.reload();
56+
await page.getByRole('button', { name: 'Enable Identity Management' }).click();
57+
}
5158
await takeScreenshot(page, __filename, 'identity-enabled');
5259

5360
log(`Adding Role, Group and User ...\n`);

0 commit comments

Comments
 (0)