Skip to content
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

Failing test: X-Pack Endpoint Functional Tests on Serverless.x-pack/test/security_solution_endpoint/apps/endpoint/responder·ts - endpoint Response Actions Responder from timeline should show Responder from alert in a timeline #172374

Closed
kibanamachine opened this issue Dec 1, 2023 · 11 comments
Assignees
Labels
failed-test A test failure on a tracked branch, potentially flaky-test OLM Sprint Team:Defend Workflows “EDR Workflows” sub-team of Security Solution

Comments

@kibanamachine
Copy link
Contributor

kibanamachine commented Dec 1, 2023

A test failed on a tracked branch

Error: expected testSubject(superDatePickerQuickMenu) to exist
    at TestSubjects.existOrFail (test_subjects.ts:71:13)
    at Object.clickActionLogSuperDatePickerQuickMenuButton (endpoint_responder.ts:53:5)
    at performResponderSanityChecks (responder.ts:41:5)
    at Context.<anonymous> (responder.ts:204:9)
    at Object.apply (wrap_function.js:73:16)

First failure: CI Build - main

@kibanamachine kibanamachine added the failed-test A test failure on a tracked branch, potentially flaky-test label Dec 1, 2023
@botelastic botelastic bot added the needs-team Issues missing a team label label Dec 1, 2023
@kibanamachine kibanamachine added the Team:Defend Workflows “EDR Workflows” sub-team of Security Solution label Dec 1, 2023
@elasticmachine
Copy link
Contributor

Pinging @elastic/security-defend-workflows (Team:Defend Workflows)

@botelastic botelastic bot removed the needs-team Issues missing a team label label Dec 1, 2023
@ashokaditya ashokaditya self-assigned this Dec 4, 2023
@ashokaditya
Copy link
Member

ashokaditya commented Dec 4, 2023

The cause of failure is due to a tour popup blocking the buttons below. We've already fixed this issue in /pull/172303. There's no reason that it should fail on #171760 give that it was merged after the fix PR. Unless, the CI ran before syncing with main which could cause in the test failure. I'm going to keep an eye on this one for a day before closing it.

@kibanamachine
Copy link
Contributor Author

New failure: CI Build - main

@ashokaditya
Copy link
Member

This is a new failure on serverless CI tests ☝🏼 Might be related to changes in /pull/172030. Looking into it!

@logeekal
Copy link
Contributor

logeekal commented Dec 6, 2023

I have triggered a flaky test run because this test seems to be passing locally everytime

https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/4211

@logeekal logeekal self-assigned this Dec 6, 2023
@logeekal
Copy link
Contributor

logeekal commented Dec 7, 2023

Hello @ashokaditya ,

I looked into the above flaky test runner and it looks like there was only one failure of a different test but with same reason.

Reason is that test clicks on below highlighted button but the popover never shows up and as you can see in below code. It could be for n number of reasons such as proper hydration or the button is not yet active.

We face this kind of error in cypress as well but we have way to repeatedly click a button until the required css selector shows up. Do you also employ this kind of technique in FTR somewhere as well?

const clickActionLogSuperDatePickerQuickMenuButton = async (): Promise<void> => {
await testSubjects.findService.clickByCssSelector(
`${testSubjSelector(TEST_SUBJ.actionLogFlyout)} ${testSubjSelector(
'superDatePickerToggleQuickMenuButton'
)}`
);
await testSubjects.existOrFail('superDatePickerQuickMenu');
};

Screenshot 2023-12-07 at 10 46 39

@ashokaditya
Copy link
Member

@logeekal thanks for looking into this. I am not aware if we can do this on FTR. We could surely benefit with such a technique in the tests. Can you point me to a cypress test where you repeatedly click a button until the css selector shows up.

@ashokaditya
Copy link
Member

related tickets

#170435
#172512

@ashokaditya ashokaditya reopened this Jan 24, 2024
ashokaditya added a commit to ashokaditya/kibana that referenced this issue Jan 24, 2024
@ashokaditya
Copy link
Member

/pull/175454

@logeekal
Copy link
Contributor

logeekal commented Feb 7, 2024

@ashokaditya , Below is one such example. We run statements 206,207 till 209 is true.

export const clearAllSelections = (filterIndex: number) => {
cy.get(CONTROL_GROUP).scrollIntoView();
recurse(
() => {
cy.get(CONTROL_FRAME_TITLE).eq(filterIndex).realHover();
return cy.get(OPTION_LIST_CLEAR_BTN).eq(filterIndex);
},
($el) => $el.is(':visible')
);
cy.get(OPTION_LIST_CLEAR_BTN).eq(filterIndex).should('be.visible').trigger('click');
};

@ashokaditya
Copy link
Member

We removed the FTR test in /pull/177740. Thetests were failing as there's a change in the timelines UI. We decided to cover it in cypress tests if not already covered.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
failed-test A test failure on a tracked branch, potentially flaky-test OLM Sprint Team:Defend Workflows “EDR Workflows” sub-team of Security Solution
Projects
None yet
Development

No branches or pull requests

4 participants