Skip to content

[test-helpers] Add EuiEmptyPromptObject - #10290

Merged
steliosmavro merged 7 commits into
elastic:mainfrom
steliosmavro:stelios/eui-empty-prompt-object
Nov 20, 2026
Merged

steliosmavro merged 7 commits into
elastic:mainfrom
steliosmavro:stelios/eui-empty-prompt-object

Conversation

@steliosmavro

Copy link
Copy Markdown
Contributor

Summary

Adds EuiEmptyPromptObject to @elastic/eui-test-helpers.

  • getTitle() and getBody(), empty strings when the prop is not set
  • getActions(), the action labels in order, for a single action and for an array
  • action(name) locator and clickAction(name), matching a button or a link by accessible name
  • footer locator

Kibana prep: elastic/kibana#304586 moves the one raw .euiEmptyPrompt__content Scout usage in the APM service map page object to getByRole('heading'), registered under @next.

Closes elastic/apps-dx#315.

QA

  • yarn lint in packages/test-helpers
  • yarn test-e2e on the spec against Storybook, 4 passed

@steliosmavro
steliosmavro requested a review from a team as a code owner November 11, 2026 08:49
Copilot AI balanced review requested due to automatic review settings November 11, 2026 08:49

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The clickAction(name) lookup includes title and body links, so it can click an excluded body link or fail with a strict-mode violation when a body link and an action share a name.

1 open issue
What changed in this PR

Adds EuiEmptyPromptObject to @elastic/eui-test-helpers, giving consumers a reusable Playwright interface for empty prompts.

Changes:

  • Adds selectors and helpers for reading titles, bodies, and action labels, locating and clicking actions, and accessing the footer.
  • Exports and documents the object, with Storybook-backed tests and a changelog entry.
  • Registers the related Kibana selector migration for the next release.
File Description
packages/​test-helpers/​src/​selectors.ts Registers empty-prompt selectors.
packages/​test-helpers/​src/​playwright/​components/​empty_prompt/​object.ts Implements the Playwright component object.
packages/​test-helpers/​src/​playwright/​components/​empty_prompt/​object.spec.ts Adds Storybook-backed helper tests.
packages/​test-helpers/​src/​index.ts Exports EuiEmptyPromptObject.
packages/​test-helpers/​src/​components/​empty_prompt/​selectors.ts Defines empty-prompt element selectors.
packages/​test-helpers/​src/​components/​empty_prompt/​README.md Documents usage, API, and exclusions.
packages/​test-helpers/​README.md Adds the object to the component directory.
packages/​test-helpers/​changelogs/​upcoming/​10290.md Records the new helper API.
packages/​release-cli/​kibana-prep-commits Registers the Kibana preparation commit under @next.

Review effort: Balanced

@weronikaolejniczak weronikaolejniczak added the ci:regression-integration-test-kibana Run a Regression Integration Test in Kibana against this PR label Nov 12, 2026
@weronikaolejniczak

Copy link
Copy Markdown
Contributor

@steliosmavro there's a couple of merge conflicts, could you fix them before review? 🙏🏻

@github-actions

github-actions Bot commented Nov 12, 2026 •

Copy link
Copy Markdown

Kibana Regression Integration Test

Status: 💔 Kibana CI failed
Branch: update-dependencies/pr-10290
Kibana PR: elastic/kibana#305069

Please check Kibana CI logs for details.

@steliosmavro
steliosmavro force-pushed the stelios/eui-empty-prompt-object branch 2 times, most recently from 2b1b7a2 to 6225d05 Compare November 12, 2026 15:56
@steliosmavro
steliosmavro force-pushed the stelios/eui-empty-prompt-object branch 2 times, most recently from 742a975 to 58dccdc Compare November 18, 2026 10:59
@weronikaolejniczak
weronikaolejniczak removed their request for review November 18, 2026 11:25

@mgadewoll mgadewoll left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 LGTM, thanks for the updates!

@steliosmavro
steliosmavro force-pushed the stelios/eui-empty-prompt-object branch from 9ed1d14 to 66ff244 Compare November 20, 2026 13:32
@infra-vault-gh-plugin-prod

Copy link
Copy Markdown

💚 Build Succeeded

History

@infra-vault-gh-plugin-prod

Copy link
Copy Markdown

💚 Build Succeeded

History

@steliosmavro
steliosmavro merged commit 0368922 into elastic:main Nov 20, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci:regression-integration-test-kibana Run a Regression Integration Test in Kibana against this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants