diff --git a/src/CSharp/EasyMicroservices.IdentityMicroservice.Tests/LoginTests.cs b/src/CSharp/EasyMicroservices.IdentityMicroservice.Tests/LoginTests.cs index 7b9fba1..7199ec7 100644 --- a/src/CSharp/EasyMicroservices.IdentityMicroservice.Tests/LoginTests.cs +++ b/src/CSharp/EasyMicroservices.IdentityMicroservice.Tests/LoginTests.cs @@ -15,12 +15,12 @@ public LoginTests(AuthenticationTestFixture authenticationTestFixture) [Fact] public async Task LoginOwnerAsync() { - await GetLoginOwnerAsync(); + await GetLoginOwnerAsync(_authenticationClient); } - public async Task GetLoginOwnerAsync() + public static async Task GetLoginOwnerAsync(AuthenticationClient authenticationClient) { - var loginResult = await _authenticationClient.LoginByPersonalAccessTokenAsync(new LoginByPersonalAccessTokenRequestContract() + var loginResult = await authenticationClient.LoginByPersonalAccessTokenAsync(new LoginByPersonalAccessTokenRequestContract() { PersonalAccessToken = "ownerpat" }).AsCheckedResult(x => x.Result); @@ -29,9 +29,9 @@ public async Task GetLoginOwnerAsync() return loginResult.Token; } - public async Task GetLoginAsync(UserSummaryContract userSummaryContract) + public static async Task GetLoginAsync(UserSummaryContract userSummaryContract, AuthenticationClient authenticationClient) { - var loginResult = await _authenticationClient.LoginAsync(userSummaryContract) + var loginResult = await authenticationClient.LoginAsync(userSummaryContract) .AsCheckedResult(x => x.Result); Assert.NotNull(loginResult); Assert.NotEmpty(loginResult.Token);