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

Flaky Jest config: x-pack/plugins/security_solution/public/timelines #143718

Closed
tylersmalley opened this issue Oct 20, 2022 · 2 comments · Fixed by #143824
Closed

Flaky Jest config: x-pack/plugins/security_solution/public/timelines #143718

tylersmalley opened this issue Oct 20, 2022 · 2 comments · Fixed by #143824
Assignees
Labels
failed-test A test failure on a tracked branch, potentially flaky-test Team: SecuritySolution Security Solutions Team working on SIEM, Endpoint, Timeline, Resolver, etc. Team:Threat Hunting:Investigations Security Solution Investigations Team Team:Threat Hunting Security Solution Threat Hunting Team

Comments

@tylersmalley
Copy link
Contributor

tylersmalley commented Oct 20, 2022

Related to #141477

We're seeing an extreamly high failure rate on the x-pack/plugins/security_solution/public/timelines/jest.config.js Jest config.

 PASS  x-pack/plugins/security_solution/public/timelines/components/fields_browser/index.test.tsx (8.622 s)
/var/lib/buildkite-agent/builds/kb-n2-4-spot-b704f4e0ad16dddb/elastic/kibana-on-merge/kibana/node_modules/react-dom/cjs/react-dom.development.js:3905
      var evt = document.createEvent('Event');
                         ^
TypeError: Cannot read properties of null (reading 'createEvent')
    at Object.invokeGuardedCallbackDev (/var/lib/buildkite-agent/builds/kb-n2-4-spot-b704f4e0ad16dddb/elastic/kibana-on-merge/kibana/node_modules/react-dom/cjs/react-dom.development.js:3905:26)
    at invokeGuardedCallback (/var/lib/buildkite-agent/builds/kb-n2-4-spot-b704f4e0ad16dddb/elastic/kibana-on-merge/kibana/node_modules/react-dom/cjs/react-dom.development.js:4056:31)
    at flushPassiveEffectsImpl (/var/lib/buildkite-agent/builds/kb-n2-4-spot-b704f4e0ad16dddb/elastic/kibana-on-merge/kibana/node_modules/react-dom/cjs/react-dom.development.js:23543:11)
    at unstable_runWithPriority (/var/lib/buildkite-agent/builds/kb-n2-4-spot-b704f4e0ad16dddb/elastic/kibana-on-merge/kibana/node_modules/scheduler/cjs/scheduler.development.js:468:12)
    at runWithPriority$1 (/var/lib/buildkite-agent/builds/kb-n2-4-spot-b704f4e0ad16dddb/elastic/kibana-on-merge/kibana/node_modules/react-dom/cjs/react-dom.development.js:11276:10)
    at flushPassiveEffects (/var/lib/buildkite-agent/builds/kb-n2-4-spot-b704f4e0ad16dddb/elastic/kibana-on-merge/kibana/node_modules/react-dom/cjs/react-dom.development.js:23447:14)
    at Object.<anonymous>.flushWork (/var/lib/buildkite-agent/builds/kb-n2-4-spot-b704f4e0ad16dddb/elastic/kibana-on-merge/kibana/node_modules/react-dom/cjs/react-dom-test-utils.development.js:992:10)
    at Immediate.<anonymous> (/var/lib/buildkite-agent/builds/kb-n2-4-spot-b704f4e0ad16dddb/elastic/kibana-on-merge/kibana/node_modules/react-dom/cjs/react-dom-test-utils.development.js:1003:11)
    at processImmediate (node:internal/timers:466:21)
Jest exited with code 1

Examples:

This error causes Jest to exit, meaning the rest of the tests in the config do not run, and an issue is not automatically generated.

This seems which seems to always happen after x-pack/plugins/security_solution/public/timelines/components/fields_browser/index.test.tsx leading me to believe it might be happening in x-pack/plugins/security_solution/public/timelines/components/timeline/body/index.test.tsx. I am skipping that suite (1d7c084), but if it continues, I will need to skip the entire config until it can be investigated.

@tylersmalley tylersmalley added blocker failed-test A test failure on a tracked branch, potentially flaky-test skipped-test Team: SecuritySolution Security Solutions Team working on SIEM, Endpoint, Timeline, Resolver, etc. v8.6.0 labels Oct 20, 2022
@elasticmachine
Copy link
Contributor

Pinging @elastic/security-solution (Team: SecuritySolution)

tylersmalley pushed a commit that referenced this issue Oct 20, 2022
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
tylersmalley pushed a commit to tylersmalley/kibana that referenced this issue Oct 20, 2022
@MadameSheema MadameSheema added Team:Threat Hunting Security Solution Threat Hunting Team Team:Threat Hunting:Investigations Security Solution Investigations Team labels Oct 20, 2022
@elasticmachine
Copy link
Contributor

Pinging @elastic/security-threat-hunting (Team:Threat Hunting)

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 Team: SecuritySolution Security Solutions Team working on SIEM, Endpoint, Timeline, Resolver, etc. Team:Threat Hunting:Investigations Security Solution Investigations Team Team:Threat Hunting Security Solution Threat Hunting Team
Projects
None yet
6 participants