[GH-ISSUE #264] Add test harness for setting env vars in test repo #99

Open
opened 2026-03-02 04:11:48 +03:00 by kerem · 2 comments
Owner

Originally created by @svarlamov on GitHub (Dec 4, 2025).
Original GitHub issue: https://github.com/git-ai-project/git-ai/issues/264

Instead of the flakey serial test lib approach used in https://vscode.dev/github/acunniffe/git-ai/blob/fix/dec-3-25-cves-and-ignore-prompts-fix/tests/github_copilot.rs

  • Make it easy to set arbitrary env vars on test repo
  • Update the tests
  • Remove the serial test lib
Originally created by @svarlamov on GitHub (Dec 4, 2025). Original GitHub issue: https://github.com/git-ai-project/git-ai/issues/264 Instead of the flakey serial test lib approach used in https://vscode.dev/github/acunniffe/git-ai/blob/fix/dec-3-25-cves-and-ignore-prompts-fix/tests/github_copilot.rs - [ ] Make it easy to set arbitrary env vars on test repo - [ ] Update the tests - [ ] Remove the serial test lib
Author
Owner

@svarlamov commented on GitHub (Feb 14, 2026):

@stuartsessions taking this on! 💪

<!-- gh-comment-id:3902144760 --> @svarlamov commented on GitHub (Feb 14, 2026): @stuartsessions taking this on! 💪
Author
Owner

@stuartsessions commented on GitHub (Feb 15, 2026):

@svarlamov This seems straightforward to fix for integration tests using cargo-nextest (https://nexte.st/docs/running/). Much easier than making a custom harness that handles the parallelization of those tests. Serial testing would still apply to some unit tests (in codex.rs installer tests), but that doesn't interact with test repo.

if you want to fully get rid of serial test lib, I'll have to change the installer unit tests. If you don't want to use a different testing tech, I can make a custom harness but it'll take longer cause I have to learn how!

I can put deserialization behind a feature flag for now so it doesn't break for people running the old testing type, but the unit vs. integration tests would essentially be separated now. If you'd rather solve a different way by having test repo spoof an env or something, can explore

<!-- gh-comment-id:3905178891 --> @stuartsessions commented on GitHub (Feb 15, 2026): @svarlamov This seems straightforward to fix for integration tests using cargo-nextest (https://nexte.st/docs/running/). Much easier than making a custom harness that handles the parallelization of those tests. Serial testing would still apply to some unit tests (in codex.rs installer tests), but that doesn't interact with test repo. if you want to fully get rid of serial test lib, I'll have to change the installer unit tests. If you don't want to use a different testing tech, I can make a custom harness but it'll take longer cause I have to learn how! I can put deserialization behind a feature flag for now so it doesn't break for people running the old testing type, but the unit vs. integration tests would essentially be separated now. If you'd rather solve a different way by having test repo spoof an env or something, can explore
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/git-ai#99
No description provided.