-
Notifications
You must be signed in to change notification settings - Fork 94
RHIDP-14000: update tests for vector stores #1912
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
Merged
tisnik
merged 1 commit into
lightspeed-core:main
from
Jdubrick:vector-store-test-update
Jun 12, 2026
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,45 @@ | ||
| @e2e_group_3 @VectorStores | ||
| Feature: vector stores API endpoint tests | ||
|
|
||
|
|
||
| Background: | ||
| Given The service is started locally | ||
| And The system is in default state | ||
| And I set the Authorization header to Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c | ||
| And REST API service prefix is /v1 | ||
| And the Lightspeed stack configuration directory is "tests/e2e/configuration" | ||
| And The service uses the lightspeed-stack-auth-noop-token.yaml configuration | ||
| And The service is restarted | ||
|
|
||
| Scenario: List vector stores returns 200 | ||
| When I access REST API endpoint "vector-stores" using HTTP GET method | ||
| Then The status code of the response is 200 | ||
| And Content type of response is set to "application/json" | ||
|
|
||
| Scenario: Create vector store with empty body returns 422 | ||
| When I access REST API endpoint "vector-stores" using HTTP POST method | ||
| """ | ||
| {} | ||
| """ | ||
| Then The status code of the response is 422 | ||
|
|
||
| Scenario: Create vector store with extra fields returns 422 | ||
| When I access REST API endpoint "vector-stores" using HTTP POST method | ||
| """ | ||
| {"name": "test-store", "unknown_field": "value"} | ||
| """ | ||
| Then The status code of the response is 422 | ||
|
|
||
| Scenario: Update vector store with empty body returns 422 | ||
| When I access REST API endpoint "vector-stores/nonexistent-id" using HTTP PUT method | ||
| """ | ||
| {} | ||
| """ | ||
| Then The status code of the response is 422 | ||
|
|
||
| Scenario: Add file to vector store with empty body returns 422 | ||
| When I access REST API endpoint "vector-stores/nonexistent-id/files" using HTTP POST method | ||
| """ | ||
| {} | ||
| """ | ||
| Then The status code of the response is 422 | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Remove hardcoded bearer token from test feature data.
Line 8 commits a JWT-like token directly in the feature file. Even for test fixtures, this creates secret-scanner noise and weakens security hygiene in-repo. Replace with a non-token placeholder step/fixture value (or load from test config/env).
🧰 Tools
🪛 Betterleaks (1.3.1)
[high] 8-8: Uncovered a JSON Web Token, which may lead to unauthorized access to web applications and sensitive user data.
(jwt)
🤖 Prompt for AI Agents
Source: Linters/SAST tools