diff --git a/Sources/TestUnitaire/TestAPILol.cs b/Sources/TestUnitaire/TestAPILol.cs index 02dbdee..e819972 100644 --- a/Sources/TestUnitaire/TestAPILol.cs +++ b/Sources/TestUnitaire/TestAPILol.cs @@ -1,6 +1,8 @@ using apiLOL; using apiLOL.Controllers; using Microsoft.AspNetCore.Mvc; +using Microsoft.Extensions.Logging; +using Microsoft.Extensions.Logging.Abstractions; using StubLib; namespace TestUnitaire @@ -8,14 +10,15 @@ namespace TestUnitaire public class TestAPILol { [Theory] - [InlineData("Aatrox", "Aatrox est un champion de League of Legends")] - [InlineData("Ahri", "Ahri est un champion de League of Legends")] - [InlineData("Akali", "Akali est un champion de League of Legends")] + [InlineData("Beatrice", "sdfsdfd")] + [InlineData("Maurice", "Ahri est un champion de League of Legends")] + [InlineData("Loupiotte", "Akali est un champion de League of Legends")] public async Task TestPostChampion(string name, string bio) { // Arrange var data = new StubData(); - var controller = new ControllerChampions(new StubData()); + var logger = new NullLogger(); + var controller = new ControllerChampions(data, logger); var champDTO = new ChampionDTO(name, bio); // Act @@ -30,14 +33,15 @@ namespace TestUnitaire [Theory] - [InlineData("Aatrox", "Aatrox est un champion de League of Legends")] - [InlineData("Ahri", "Ahri est un champion de League of Legends")] - [InlineData("Akali", "Akali est un champion de League of Legends")] + [InlineData("Beatrice", "Aatrox est un champion de League of Legends")] + [InlineData("Maurice", "Ahri est un champion de League of Legends")] + [InlineData("Loupiotte", "Akali est un champion de League of Legends")] public async Task TestGetChampion(string name, string bio) { // Arrange var data = new StubData(); - var controller = new ControllerChampions(new StubData()); + var logger = new NullLogger(); + var controller = new ControllerChampions(data, logger); var champDTO = new ChampionDTO(name, bio); // Act