Commit d92a1cc
authored
[Streams] Unskip MKI Tech Preview badge test (elastic#264452)
closes: elastic#258589
## Summary
Re-enables the Streams UI test `should not show Technical Preview badge
when AI suggestions are unavailable` on serverless observability (MKI).
The test was skipped in elastic#263984 while it was failing deterministically
on the MKI.
The underlying bug was fixed by elastic#263843 after this test was skipped
## Root cause
**Root cause of the original failure (fixed):**
Before elastic#263843, `useLoadConnectors` in `@kbn/inference-connectors` had a
client-side fallback that called `fetchConnectorById` against `GET
/internal/inference/connectors/{id}` whenever `soEntryFound === false`
and `defaultConnectorId` was truthy. The test's `page.route` mock only
covered `**/internal/search_inference_endpoints/connectors*`, so the
fallback slipped past the mock and returned the project's EIS connector.
The Technical Preview badge (and the "Elastic Managed LLM is the new
default" callout) then rendered, and the assertion failed.
This was MKI-only because the fallback is gated on `defaultConnectorId`
being truthy, which requires the `GEN_AI_SETTINGS_DEFAULT_AI_CONNECTOR`
uiSetting to be configured. Serverless observability CI projects
preconfigure that setting to an EIS inference endpoint; local stateful /
ECH environments do not, so the fallback short-circuited there.
**How elastic#263843 fixed it:**
Removed the client-side fallback entirely. Default-connector merging now
happens server-side in `mergeConnectors`
(`x-pack/platform/plugins/shared/search_inference_endpoints/server/lib/merge_connectors.ts`).
After the fix, `useLoadConnectors` makes exactly one HTTP call to the
endpoint the test already mocks.1 parent f64dae2 commit d92a1cc
1 file changed
Lines changed: 1 addition & 2 deletions
File tree
Lines changed: 1 addition & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | | - | |
17 | 16 | | |
18 | 17 | | |
19 | | - | |
| 18 | + | |
20 | 19 | | |
21 | 20 | | |
22 | 21 | | |
| |||
0 commit comments