test: target the Process env-var scope

This allows the integration tests to be run on unix-based systems.
This commit is contained in:
Christopher Felegy
2019-09-08 11:27:20 -04:00
parent 9482204bcf
commit 3c6b3765ab

View File

@@ -14,7 +14,7 @@ namespace Discord
public DiscordRestClientFixture() public DiscordRestClientFixture()
{ {
var token = Environment.GetEnvironmentVariable("DNET_TEST_TOKEN", EnvironmentVariableTarget.Machine); var token = Environment.GetEnvironmentVariable("DNET_TEST_TOKEN", EnvironmentVariableTarget.Process);
if (string.IsNullOrWhiteSpace(token)) if (string.IsNullOrWhiteSpace(token))
throw new Exception("The DNET_TEST_TOKEN environment variable was not provided."); throw new Exception("The DNET_TEST_TOKEN environment variable was not provided.");
Client = new DiscordRestClient(new DiscordRestConfig() Client = new DiscordRestClient(new DiscordRestConfig()