-
Notifications
You must be signed in to change notification settings - Fork 8.5k
[Scout] Test config manifests #245135
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
base: main
Are you sure you want to change the base?
[Scout] Test config manifests #245135
Conversation
Because Scout is based on Playwright, detailed information about tests is only available while Playwright is running. This means that any time we need test-level information from a test config file we have to start a Playwright process which can be quite slow and resource-intensive if you want to do this for a larger number of tests configurations. These changes are trying to address that by introducing a system where this runtime-only information is stored in manifest files, stored in the proximity of test config files, automatically kept up to date by CI. ### Usage Locally, run the new kbn-scout CLI command (via `node scripts/scout update-test-config-manifests`) to regenerate manifests. - Running without `--includingUpToDate` will only regenerate manifests that appear outdated (component directory SHA mismatch) - Use `--includingUpToDate` to force regenerate all manifests In Buildkite, `node scripts/scout update-test-config-manifests` runs as a quick check and any changes will be auto-commited. ### Notable changes - Add Scout reporting package with a registry of test configs and components - Add a Playwright reporter that writes manifest files that capture test information for static analysis - Add a Scout CLI command `update-test-config-manifests` to create/update manifests - Add a versatile Playwright CLI wrapper for Scout tooling to call Playwright programmatically - Add Buildkite quick check to run manifest updates and commit any changes as `[Scout] Automated config manifest updates` - Add new path constants/globs/regex for discovering Scout configs - Changed how test IDs are calculated for Scout: combine test file path and test title when hashing - Remove project name and test file path from Scout test titles
...ges/private/kbn-scout-reporting/src/reporting/playwright/failed_test/failed_test_reporter.ts
Outdated
Show resolved
Hide resolved
src/platform/packages/private/kbn-scout-reporting/src/helpers/test_id_generator.ts
Show resolved
Hide resolved
src/platform/packages/private/kbn-scout-reporting/src/registry/test_config.ts
Outdated
Show resolved
Hide resolved
src/platform/packages/private/kbn-scout-reporting/src/registry/test_config.ts
Outdated
Show resolved
Hide resolved
src/platform/packages/private/kbn-scout-reporting/src/registry/test_config.ts
Show resolved
Hide resolved
src/platform/packages/private/kbn-scout-reporting/src/registry/test_config.ts
Outdated
Show resolved
Hide resolved
src/platform/packages/private/kbn-scout-reporting/src/registry/test_config.ts
Outdated
Show resolved
Hide resolved
src/platform/packages/private/kbn-scout-reporting/src/registry/testable_component.ts
Outdated
Show resolved
Hide resolved
.../packages/private/kbn-scout-reporting/src/reporting/playwright/events/playwright_reporter.ts
Show resolved
Hide resolved
src/platform/packages/private/kbn-scout-reporting/src/registry/test_config.ts
Show resolved
Hide resolved
- add tests for `test_config` module - add missing `lastModified` and `sha1` props to empty manifest object - readability improvements - rename, component -> module
💚 Build Succeeded
Metrics [docs]Public APIs missing comments
Unknown metric groupsAPI count
ESLint disabled line counts
Total ESLint disabled count
History
cc @dolaru |
dmlemeshko
left a comment
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
| "lastModified": "2025-12-03T19:04:20.842Z", | ||
| "sha1": "cf987cc228a08cc2083d5d705322a88092e4ba5a", |
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.
Do we need the lastModified and sha1 properties here? Want to make sure it's something we need as it will likely be a cause of merge conflicts.
Because Scout is based on Playwright, detailed information about tests is only available while Playwright is running. This means that any time we need test-level information from a test config file we have to start a Playwright process which can be quite slow and resource-intensive if you want to do this for a larger number of test configs.
These changes are trying to address that by introducing a system where this runtime-only information is stored in manifest files, in close proximity of test config files, automatically kept up to date by CI.
Usage
Locally, run the new kbn-scout CLI command (via
node scripts/scout update-test-config-manifests) to regenerate manifests.--includingUpToDatewill only regenerate manifests that appear outdated (component directory SHA mismatch)--includingUpToDateto force regenerate all manifestsIn Buildkite,
node scripts/scout update-test-config-manifestsruns as a quick check and any changes will be auto-commited.Notable changes
update-test-config-manifeststo create/update manifests[Scout] Automated config manifest updates