Skip to content

Commit

Permalink
Fixes sonarcloud issues
Browse files Browse the repository at this point in the history
  • Loading branch information
funsjanssen committed Jun 14, 2024
1 parent 7dc05f0 commit f90a654
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
4 changes: 2 additions & 2 deletions WebCalculator.Tests/Hooks/Hook.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,14 @@ public Hooks(IObjectContainer objectContainer)
}

[BeforeScenario]
public async Task RegisterServices()
public void RegisterServices()
{
var factory = GetWebApplicationFactory();

_objectContainer.RegisterInstanceAs(factory);
}

private WebApplicationFactory<Program> GetWebApplicationFactory() =>
private static WebApplicationFactory<Program> GetWebApplicationFactory() =>
new WebApplicationFactory<Program>()
.WithWebHostBuilder(builder =>
{
Expand Down
7 changes: 5 additions & 2 deletions WebCalculator/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@

app.MapGet("{x:int}/add/{y:int}", (int x, int y, HttpContext context) => x + y);

app.Run();
await app.RunAsync();

public partial class Program {}
#pragma warning disable S1118
public partial class Program {}

#pragma warning enable S1118

0 comments on commit f90a654

Please sign in to comment.