Skip to content

Commit

Permalink
[Security Solution][Detection Engine] fix flaky new terms suppression…
Browse files Browse the repository at this point in the history
… cypress test (#184347)

## Summary

- addresses #183941
- It looks there is some kind of race condition when adding another
Group by field during editing for New terms rule. Around 2-3 tests fails
for 200 runs. So, I decided to exclude this command from a test
-
[kibana-flaky-test-suite-runner#6157](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/6157)
  • Loading branch information
vitaliidm authored May 30, 2024
1 parent 7abbfca commit 71ea578
Showing 1 changed file with 4 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ import { saveEditedRule } from '../../../../tasks/edit_rule';
import {
selectAlertSuppressionPerRuleExecution,
selectDoNotSuppressForMissingFields,
fillAlertSuppressionFields,
} from '../../../../tasks/create_new_rule';
import { visit } from '../../../../tasks/navigation';

Expand All @@ -52,13 +51,12 @@ describe(
deleteAlertsAndRules();
});

// FLAKY: https://github.com/elastic/kibana/issues/183941
describe.skip('with suppression configured', () => {
describe('with suppression configured', () => {
beforeEach(() => {
createRule({
...rule,
alert_suppression: {
group_by: SUPPRESS_BY_FIELDS.slice(0, 1),
group_by: SUPPRESS_BY_FIELDS,
duration: { value: 20, unit: 'm' },
missing_fields_strategy: 'suppress',
},
Expand All @@ -78,12 +76,11 @@ describe(
.eq(1)
.should('be.enabled')
.should('have.value', 'm');
cy.get(ALERT_SUPPRESSION_FIELDS).should('contain', SUPPRESS_BY_FIELDS.slice(0, 1).join(''));
cy.get(ALERT_SUPPRESSION_FIELDS).should('contain', SUPPRESS_BY_FIELDS.join(''));
cy.get(ALERT_SUPPRESSION_MISSING_FIELDS_SUPPRESS).should('be.checked');

selectAlertSuppressionPerRuleExecution();
selectDoNotSuppressForMissingFields();
fillAlertSuppressionFields(SUPPRESS_BY_FIELDS.slice(1));
selectAlertSuppressionPerRuleExecution();

saveEditedRule();

Expand Down

0 comments on commit 71ea578

Please sign in to comment.