Skip to content

test(ui): derive the settings field count from the schema - #12901

Merged
mudler merged 1 commit into
masterfrom
fix/settings-page-spec
Oct 25, 2026
Merged

mudler merged 1 commit into
masterfrom
fix/settings-page-spec

Conversation

@mudler-agent

Copy link
Copy Markdown
Collaborator

Description

The settings page UI spec (core/http/react-ui/e2e/settings-page.spec.js) hard-coded the number of settings (58). Every new setting broke it. The last one was max_concurrent_backend_operations (#12888), which made the page list 59, so "every real field sits in exactly one group" fails on master.

The spec now takes the list of settings from settingsSchema.js and compares it by name with what the page shows. A failure now names the setting that is shown but not in the schema, or in the schema but in no group, and the count and the search label follow the schema. The mocked settings payload also gets the new setting.

Notes for Reviewers

  • feat(galleryop): limit concurrent backend operations #12888 added the setting to the registry, the schema and the docs but not to this spec or its fixture. That change is the one that broke the spec, so this is a follow-up to it.
  • The Go struct RuntimeSettings has 6 JSON keys with no schema entry (single_backend, logo_file, logo_horizontal_file, favicon_file, mitm_listen, pii_default_detectors). mitm_listen and pii_default_detectors are saved from the Middleware page. I did not touch them; the spec compares against the schema, not the registry.
  • I checked the new assertions with a Node script against the real schema (59 keys, none missing or extra). I did not run the Playwright spec locally, so please let the UI E2E job confirm.

Signed commits

  • Yes, I signed my commits.
  • Documentation updated (docs/content/) for user-facing changes, or not applicable

🤖 Generated with Claude Code

The settings page spec hard-coded 58 fields. Each new setting broke it,
most recently max_concurrent_backend_operations, which made the page
list 59. Compare the grouped keys with the schema keys instead, so a
failure names the field that is in no group or shown twice. Add the
new setting to the mocked settings payload.

Assisted-by: Claude:claude-sonnet-5-5
Signed-off-by: Ettore Di Giacinto <mudler@localai.io>
@mudler
mudler merged commit f1d36a0 into master Oct 25, 2026
22 of 23 checks passed
@mudler
mudler deleted the fix/settings-page-spec branch October 25, 2026 20:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants