fix(tests): isolate encrypted store per test file#25717
Merged
Conversation
… races Parallel test processes were all reading/writing `~/.vellum/protected/keys.enc`, causing six email CLI tests to fail intermittently in CI. The "missing platform credentials returns error" tests delete the API key and expect the credential check to fire, but a parallel test file that sets the key between the delete and the command's fetch leaves the key in place — the command then attempts an unmocked HTTP call and fails with "No mock matched". Override the store path in test-preload.ts so each test file's bun process gets its own keys.enc under the per-file temp workspace.
Jasonnnz
pushed a commit
that referenced
this pull request
Apr 15, 2026
… races (#25717) Parallel test processes were all reading/writing `~/.vellum/protected/keys.enc`, causing six email CLI tests to fail intermittently in CI. The "missing platform credentials returns error" tests delete the API key and expect the credential check to fire, but a parallel test file that sets the key between the delete and the command's fetch leaves the key in place — the command then attempts an unmocked HTTP call and fails with "No mock matched". Override the store path in test-preload.ts so each test file's bun process gets its own keys.enc under the per-file temp workspace.
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
~/.vellum/protected/keys.enc, racing on sets/deletes and flaking six email CLI tests in CI (email-download,email-list,email-send,email-unregister,email-attachment,email-status).test-preload.tsnow calls_setStorePathto point at<per-file-temp-workspace>/keys.enc, giving each test file its own isolated encrypted store while still honoring explicit_setStorePathoverrides in tests likecredential-vault.test.ts.Original prompt
--yolo Fix the specific CI issue in this failing job only: https://github.com/vellum-ai/vellum-assistant/actions/runs/24434800483/job/71386643819