Skip to content

RI-7969 Vector Search e2e tests#5636

Merged
valkirilov merged 25 commits intomainfrom
e2e/RI-7969/vector-search
Mar 18, 2026
Merged

RI-7969 Vector Search e2e tests#5636
valkirilov merged 25 commits intomainfrom
e2e/RI-7969/vector-search

Conversation

@valkirilov
Copy link
Copy Markdown
Member

@valkirilov valkirilov commented Mar 13, 2026

What

Add comprehensive Playwright E2E test coverage for the Vector Search feature (55 tests across 11 spec files), covering navigation, index creation, query execution, query library, and browser page integration.

Note: The PR is quite big, so I would advise reviewing the PR plan or going through the commits separately, where you can see the different test suites instead of one large change set.

Infrastructure & prerequisites

  • Test plan update (TEST_PLAN.md section 8.1–8.12) — 2ba1c39, 09882ad
  • TypeScript types and Fishery test data factories — 2a7fd13
  • API helpers for index/key management via Workbench endpoint — cd95b0d
  • Base page objects, fixtures, and Playwright config — b4a072f
  • Browser page object enhancements (View Index, Make Searchable, KeyList) — 32c3d63
  • Vector Search page objects (16 component POMs) — 4fd7753

Test suites

  • Navigation & RQE availability (3 tests) — welcome screen, list screen, RQE not available — 027d84c
image
  • Select key & create index onboarding (5 tests) — onboarding flow, skip, persistence — 06f1420
image
  • Sample data index creation (6 tests) — E-Commerce Discovery & Content Recommendations flows — df312d4
image
  • Existing data index creation (7 tests) — default settings, prefix editing, field management, JSON keys — d6d00f2
image
  • List indexes (5 tests) — table display, query/browse navigation, details panel, deletion — 324cede
image
  • Create index from list page (4 tests) — sample data modal, existing data, disabled state — f945b43
image
  • Query editor (10 tests) — run query, result cards, explain/profile, button states — 26b1a25
image
  • Query page onboarding (2 tests) — onboarding dismissal and persistence — 7a468f8
image
  • Save query (3 tests) — save, toast navigation, cancel modal — 7ebeb17
image
  • Query library (5 tests) — search/filter, expand/collapse, run, load, delete — e70c224
image
  • Browser page integration (5 tests) — View Index button/dropdown, Make Searchable, folder Index button — 4e945cb
image

Serial execution project

All Vector Search test suites are tagged with @serial and run in the new chromium-serial Playwright project (workers: 1, fullyParallel: false). This is necessary because the tests operate on shared RediSearch indexes (FT.CREATE / FT.DROPINDEX) on the same Redis instance, and parallel execution causes flakiness due to index name collisions and cleanup race conditions. The existing chromium project now excludes @serial tests via grepInvert.

Testing

Prerequisites

  • Redis Stack instance running with RediSearch module (v7+)
  • RedisInsight API and UI running (yarn dev:desktop or yarn dev:api && yarn dev:ui)

Run all Vector Search tests

cd tests/e2e-playwright
npx playwright test tests/main/vector-search/

Run a specific spec file

npx playwright test tests/main/vector-search/navigation/navigation.spec.ts
npx playwright test tests/main/vector-search/query/query-editor.spec.ts

Run with UI mode (for debugging)

npx playwright test tests/main/vector-search/ --ui

Note

Medium Risk
Adds a large new E2E test suite and changes Playwright project configuration/CI execution, which may impact test runtime and stability (especially due to new serial-only tagging and Redis index cleanup behavior). No product runtime code is modified beyond test harness/page objects.

Overview
Adds comprehensive Playwright E2E coverage for Vector Search (navigation/RQE availability, index creation from sample/existing data, query execution/results, query onboarding, saving queries, query library CRUD, and Browser-page integration like View index / Make searchable).

Extends the E2E test harness to support these flows: new VectorSearchPage page-object model with supporting components/modals, new vector-search test data factories/types, and ApiHelper helpers to create/list/delete RediSearch indexes plus manage saved queries and SEARCH command history via the Workbench endpoint.

Updates Playwright/CI to run @serial Vector Search tests in a new chromium-serial project (single worker, not fully parallel) while excluding them from the regular chromium project; the GitHub workflow now runs both projects. Also includes small robustness tweaks to existing page objects (DB list pagination/reload in gotoDatabase, new Search tab navigation, and Browser key list/tree selectors for the updated UI).

Written by Cursor Bugbot for commit c14318a. This will update automatically on new commits. Configure here.

@valkirilov valkirilov marked this pull request as ready for review March 13, 2026 09:42
@valkirilov valkirilov self-assigned this Mar 13, 2026
@jit-ci
Copy link
Copy Markdown

jit-ci Bot commented Mar 13, 2026

🛡️ Jit Security Scan Results

CRITICAL HIGH MEDIUM

✅ No security findings were detected in this PR


Security scan by Jit

name: Vector Search E2E Tests
overview: Update TEST_PLAN.md with ~37 flow-based Vector Search e2e test cases across 9 subsections, and implement the tests across 5 separate pull requests organized by functional area.
todos:
- id: pr1-infrastructure-and-navigation
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.

I'd just do that as a single PR with 5 commits. It shouldn't take long to review that.

Copy link
Copy Markdown
Member Author

@valkirilov valkirilov Mar 13, 2026

Choose a reason for hiding this comment

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

I think separate PRs work better here, because each one covers a specific area, so when you review it you only need to think about that one thing - like just the create index flow or just the query tests.

Mixing everything into one PR means you have to keep switching context between unrelated parts, which I find makes the review harder. The total effort is the same, but the individual reviews should be quicker.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

PS: If the code is not that much, I can combine it in a single PR 👍

DimoHG
DimoHG previously approved these changes Mar 13, 2026
KrumTy
KrumTy previously approved these changes Mar 13, 2026
dantovska
dantovska previously approved these changes Mar 13, 2026
@valkirilov valkirilov dismissed stale reviews from dantovska, KrumTy, and DimoHG via 4e945cb March 17, 2026 10:25
@valkirilov valkirilov force-pushed the e2e/RI-7969/vector-search branch from ca5ab40 to 4e945cb Compare March 17, 2026 10:25
Comment thread tests/e2e-playwright/test-data/databases/index.ts
Comment thread tests/e2e-playwright/pages/browser/components/KeyList.ts Outdated
Add TypeScript types and Fishery factories for Vector Search E2E tests:
- IndexSchemaField, IndexConfig, IndexHashKeyData, IndexJsonKeyData types
- IndexConfigFactory, IndexHashKeyFactory, IndexJsonKeyFactory factories
- StandaloneEmptyConfigFactory, StandaloneV7ConfigFactory database configs

References: #RI-7969
Made-with: Cursor
Extend ApiHelper with methods for Vector Search E2E tests:
createIndex, deleteIndex, deleteAllIndexes, getIndexes,
sendCommand, createSavedQuery, deleteAllSavedQueries,
deleteCommandExecutions.

References: #RI-7969
Made-with: Cursor
Add Search tab navigation, vectorSearchPage fixture, and
gotoDatabase scroll handling for Vector Search E2E tests.

References: #RI-7969
Made-with: Cursor
Add View Index, Make Searchable, and Index folder button locators.
Add selectKeyInTree, hoverFolderNode helpers and MakeSearchableModal POM.

References: #RI-7969
Made-with: Cursor
Add VectorSearchPage and all component POMs: CreateIndexForm,
CreateIndexOnboarding, IndexList, QueryEditor, QueryLibrary,
QueryResults, SaveQueryModal, FieldTypeModal, and more.

References: #RI-7969
Made-with: Cursor
Delete the previous Vector Search E2E test plan file as it has been replaced with a more comprehensive and updated version in the TEST_PLAN.md.

References: #RI-7969
Made-with: Cursor
Tests for welcome screen, index list screen, and RQE not available
screen when Redis lacks the search module.

References: #RI-7969
Made-with: Cursor
Tests for select key onboarding dismissal, create index onboarding
step-through, skip, and persistence after completion.

References: #RI-7969
Made-with: Cursor
Tests for sample data modal flow, E-Commerce Discovery and Content
Recommendations index creation via Start querying and See index definition.

References: #RI-7969
Made-with: Cursor
Tests for creating indexes from existing hash/JSON keys with default
settings, prefix editing, field management, name validation, and
JSON key support.

References: #RI-7969
Made-with: Cursor
Tests for index table display, query and browse navigation,
index details side panel, and index deletion with confirmation.

References: #RI-7969
Made-with: Cursor
Tests for sample data modal flows, existing data creation via list
page menu, and disabled state when no hash/JSON keys exist.

References: #RI-7969
Made-with: Cursor
Tests for running queries, result card interactions (expand, collapse,
re-run, delete, clear), explain/profile actions, and button states.

References: #RI-7969
Made-with: Cursor
Tests for query library onboarding popover dismissal and
persistence after completion.

References: #RI-7969
Made-with: Cursor
Tests for saving queries, navigating to query library via success
toast action, and cancelling the save query modal.

References: #RI-7969
Made-with: Cursor
Tests for searching/filtering saved queries, expand/collapse items,
running and loading queries from library, and deleting with notification.

References: #RI-7969
Made-with: Cursor
Tests for View Index button/dropdown, Make Searchable flow,
Index button on folder nodes, and RQE not available from Browser.

References: #RI-7969
Made-with: Cursor
…ethod

Updated the logic for extracting the leaf name from the key name to account for the length of the delimiter, ensuring accurate substring extraction.

References: #RI-7969
Made-with: Cursor
@valkirilov valkirilov force-pushed the e2e/RI-7969/vector-search branch from 4e945cb to f634372 Compare March 17, 2026 10:40
Comment thread tests/e2e-playwright/helpers/api.ts
…alue

Added a new method `getKeysToScan` to the SettingsPage class for retrieving the current keys-to-scan value.

e2e(vector-search): optimize browser page integration tests

Refactored the browser page integration tests to utilize the `browserPage` object for navigation, removing redundant calls to `goto` for improved test efficiency.

References: #RI-7969
Made-with: Cursor
Updated the `createIndex` method to accept an additional `keyType` parameter, allowing for the specification of 'hash' or 'json' types when creating indexes. This change improves flexibility in index creation commands.

References: #RI-7969
Made-with: Cursor
Comment thread tests/e2e-playwright/helpers/api.ts
Modified the `createIndex` method to format index name and prefix as quoted strings for consistency. Additionally, updated the `IndexSchemaFieldFactory` to generate field names using a new method for better randomness.

References: #RI-7969
Made-with: Cursor
Updated the onboarding tests for vector search to include navigation to the application before localStorage operations. This change ensures that the correct origin is targeted during tests, improving reliability and consistency.

References: #RI-7969
Made-with: Cursor
Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Reorganized the onboarding steps in vector search tests to ensure navigation occurs before localStorage operations. This adjustment enhances test reliability by targeting the correct application origin during onboarding.

References: #RI-7969
Made-with: Cursor
@valkirilov valkirilov merged commit 007f573 into main Mar 18, 2026
5 checks passed
@valkirilov valkirilov deleted the e2e/RI-7969/vector-search branch March 18, 2026 13:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants