-
Notifications
You must be signed in to change notification settings - Fork 8.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Cloud Security][FTR][Bug] Add a little delay for findings FTR for stability #160696
Conversation
Pinging @elastic/kibana-cloud-security-posture (Team:Cloud Security) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@animehart increasing the sleep from 1s to 3s points to me that we are going in the wrong direction with that workaround.
We should be able to detect better when a sort action is over
@kfirpeled |
@@ -63,6 +64,7 @@ export function CspDashboardPageProvider({ getService, getPageObjects }: FtrProv | |||
|
|||
getKubernetesTab: async () => { | |||
const tabs = await dashboard.getDashboardTabs(); | |||
sleep(1000); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of placing a sleep here we should check if we can wait for the tabs to appear with a timeout of 1s or 2s
@@ -131,6 +131,7 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) { | |||
describe('SearchBar', () => { | |||
it('add filter', async () => { | |||
await filterBar.addFilter({ field: 'rule.name', operation: 'is', value: ruleName1 }); | |||
sleep(1000); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of the following sleep we should call HeaderPageObject.awaitGlobalLoadingIndicatorHidden
on before test
When we went over the PR together we saw that we can have a reference to the
in the export function CspDashboardPageProvider({ getService, getPageObjects }: FtrProviderContext) {
const PageObjects = getPageObjects(['common', 'header']);
// MORE CODE HERE ...
// PSEUDO USAGE:
getDashboardTabs: async () => {
// Waits for the page to load
await PageObjects.header. awaitGlobalLoadingIndicatorHidden();
// REST OF THE LOGIC
}, |
💚 Build Succeeded
Metrics [docs]Unknown metric groupsESLint disabled line counts
Total ESLint disabled count
History
To update your PR or re-run it, just comment with: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Summary