Skip to content

Commit

Permalink
added restore step in the pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
Radoslav Radev committed Mar 9, 2024
1 parent ee33f48 commit edd4071
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
8 changes: 5 additions & 3 deletions .github/workflows/AccountPipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,13 @@ jobs:
uses: actions/setup-dotnet@v3
with:
dotnet-version: 8.0.x
- name: Restore dependencies
-name: Restore dependencies for Account project
run: dotnet restore Backend/Account/Account.csproj
- name: Build
- name: Restore dependencies for Account Test project
run: dotnet restore Backend/Tests/Account.Test/Account.Test.csproj
- name: Build Account project
run: dotnet build Backend/Account/Account.csproj --no-restore
- name: Test
- name: Run tests
run: dotnet test Backend/Tests/Account.Test/Account.Test.csproj --no-build --verbosity normal

- name: Log in to DockerHub
Expand Down
2 changes: 1 addition & 1 deletion Backend/Account/Services/AccountService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public class AccountService(DatabaseContext _accountDbContext, IConfiguration co
{
private readonly AsyncRetryPolicy _dbRetryPolicy = Policy.Handle<Exception>().WaitAndRetryAsync(3, i => TimeSpan.FromSeconds(10));

public async Task<Tuple<AccountDTO,string>?> Login(LoginRequestDTO request)
public async Task<Tuple<AccountDTO,string>?> Login(LoginRequestDTO request)
{
var account = await _accountDbContext.Accounts.FirstOrDefaultAsync(x => x.Email == request.email);
if (account is null) return null;
Expand Down

0 comments on commit edd4071

Please sign in to comment.