Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
mythz committed Dec 31, 2024
1 parent 8544ce7 commit 6eb9c20
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion MyApp.Tests/ImportTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,7 @@ public async Task Can_call_curl_to_get_url()
[Test]
public async Task Can_create_new_users()
{
var client = TestUtils.CreateAdminProdClient();
var client = await TestUtils.CreateAdminProdClientAsync();

var api = await client.ApiAsync(new EnsureApplicationUser
{
Expand Down
6 changes: 2 additions & 4 deletions MyApp.Tests/TestUtils.cs
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,8 @@ await client.ApiAsync(new Authenticate
});
return client;
}
public static JsonApiClient CreateAdminProdClient() => new("https://pvq.app")
{
BearerToken = Environment.GetEnvironmentVariable("AUTH_SECRET")
};
public static JsonApiClient CreateAdminProdClient() => new JsonApiClient("https://pvq.app")
.Apply(c => c.AddHeader(Keywords.AuthSecret, Environment.GetEnvironmentVariable("AUTH_SECRET")!));

public static async Task<JsonApiClient> CreateAdminProdClientAsync()
{
Expand Down

0 comments on commit 6eb9c20

Please sign in to comment.