Skip to content

Commit

Permalink
Fix integration tests' authentication
Browse files Browse the repository at this point in the history
  • Loading branch information
christoment committed Dec 14, 2023
1 parent 133ba9a commit 965e106
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Tests/Common/Fixtures/WebUITestFactory.cs
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ private static void SetAuthHeader(HttpClient client, LoginResponse? loginRespons

private static async Task<LoginResponse?> Login(string userName, string password, HttpClient client)
{
var loginResponse = await client.PostAsJsonAsync("/login", new { Email = userName, Password = password });
var loginResponse = await client.PostAsJsonAsync("/api/auth/login", new { Email = userName, Password = password });
loginResponse.EnsureSuccessStatusCode();

var loginResponseContent = await loginResponse.Content.ReadFromJsonAsync<LoginResponse>();
Expand All @@ -85,7 +85,7 @@ private static void SetAuthHeader(HttpClient client, LoginResponse? loginRespons

private static async Task Register(string userName, string password, HttpClient client)
{
var registerResponse = await client.PostAsJsonAsync("/register", new { Email = userName, Password = password });
var registerResponse = await client.PostAsJsonAsync("/api/auth/register", new { Email = userName, Password = password });
registerResponse.EnsureSuccessStatusCode();
}
}
Expand Down

0 comments on commit 965e106

Please sign in to comment.