Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Set environment variables for test runs #4949

Closed
peterdeme opened this issue Dec 10, 2021 · 1 comment
Closed

Set environment variables for test runs #4949

peterdeme opened this issue Dec 10, 2021 · 1 comment

Comments

@peterdeme
Copy link

Environment data

Doesn't matter.

OmniSharp log

Doesn't matter.

Feature request

Ability to use a dotenv file for test running. Exactly the same thing was implemented by the Go team here. Here's how it works:

"go.testEnvFile": "${workspaceFolder}/.env"

Then whenever you run a test it'll pick up the env vars from that file. Currently I do this workaround:

$ cd stream-chat-net
$ export OMNISHARP_STREAM_API_KEY=xyz
$ export OMNISHARP_STREAM_API_SECRET=xyz
$ code . 

With the OMNISHARP_ prefix it picks up the env vars but it's pretty inconvenient because I must start VS Code from the shell.

A lot of us don't want to clutter our machine-level env vars but want to use "local" ones. This feature would make it possible.

@peterdeme
Copy link
Author

I guess I'll close it.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant