-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
[kbn-scout] Custom event-oriented test reporter & persistence #202906
Conversation
f5bcde0
to
aa76745
Compare
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.
Next batch of comments - still reviewing more.
packages/kbn-scout-reporting/src/reporting/report/persistence/mappings.ts
Outdated
Show resolved
Hide resolved
packages/kbn-scout-reporting/src/reporting/report/persistence/index_templates.ts
Outdated
Show resolved
Hide resolved
packages/kbn-scout-reporting/src/reporting/report/persistence/mappings.ts
Show resolved
Hide resolved
packages/kbn-scout-reporting/src/reporting/report/persistence/index.ts
Outdated
Show resolved
Hide resolved
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.
Two more comments
packages/kbn-test/src/functional_test_runner/lib/mocha/reporter/scout_ftr_reporter.ts
Show resolved
Hide resolved
aa76745
to
9b6eaaa
Compare
Addresses circular dependency issues detected during type checks.
Covered by ECS mappings.
f772956
to
c92229f
Compare
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 🚀
Also went through a number of scenarios locally (including skipped and failed tests) and uploaded results to a cloud cluster. That all worked fine for me.
💚 Build Succeeded
Metrics [docs]Public APIs missing comments
Public APIs missing exports
Unknown metric groupsAPI count
ESLint disabled line counts
Total ESLint disabled count
History
cc @dolaru |
Starting backport for target branches: 8.x https://github.com/elastic/kibana/actions/runs/12376852654 |
Starting backport for target branches: 8.x https://github.com/elastic/kibana/actions/runs/12376852633 |
💔 All backports failed
Manual backportTo create the backport manually run:
Questions ?Please refer to the Backport tool documentation |
1 similar comment
💔 All backports failed
Manual backportTo create the backport manually run:
Questions ?Please refer to the Backport tool documentation |
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
…202906) (#204696) # Backport This will backport the following commits from `main` to `8.x`: - [[kbn-scout] Custom event-oriented test reporter & persistence (#202906)](#202906) <!--- Backport version: 8.9.8 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"David Olaru","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-12-09T14:34:25Z","message":"[kbn-scout] Custom event-oriented test reporter & persistence (#202906)","sha":"ad4e8efd0f07f8f682709efce271493a4872e331","branchLabelMapping":{"^v9.0.0$":"main","^v8.18.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","v9.0.0","backport:prev-minor","test:scout"],"number":202906,"url":"https://github.com/elastic/kibana/pull/202906","mergeCommit":{"message":"[kbn-scout] Custom event-oriented test reporter & persistence (#202906)","sha":"ad4e8efd0f07f8f682709efce271493a4872e331"}},"sourceBranch":"main","suggestedTargetBranches":[],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","labelRegex":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/202906","number":202906,"mergeCommit":{"message":"[kbn-scout] Custom event-oriented test reporter & persistence (#202906)","sha":"ad4e8efd0f07f8f682709efce271493a4872e331"}}]}] BACKPORT--> --------- Co-authored-by: David Olaru <[email protected]> Co-authored-by: kibanamachine <[email protected]>
Summary
These changes introduce an event-oriented test reporter which should aid with analysis of test runs over time.
Scout CLI
All Scout related CLI commands are now consolidated to a single script:
./scripts/scout.js
.Scout report
This is essentially a tool for logging events that occur during a test run and save them to an
ndjson
file for later consumption.Scout report events are best consumed when indexed in an ES datastream. Initializing the datastream and uploading events should be fairly simple to do using the newly added CLI commands
initialize-report-datastream
andupload-events
.Reporters
Easy to use reporters that produce a Scout report have been added for Playwright and FTR (Mocha).
When these are used, you can expect the reports to be saved automatically under
.scout/reports
relative to the Kibana repository root.Reporters have been attached to FTR and Scout Playwright configs. For FTR, a report will only be produced if the environment variable
ENABLE_SCOUT_REPORTER=true
is set.