From baa93b4dbcfbd609d713955080611ec31d223c7e Mon Sep 17 00:00:00 2001 From: anperederi Date: Sat, 16 Mar 2024 18:06:22 +0100 Subject: [PATCH] =?UTF-8?q?=E2=9C=85=20Check=20model's=20tests?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/Tests/UnitTestsModel/CoachTest.cs | 13 ------------- src/Tests/UnitTestsModel/RelationshipTest.cs | 2 -- src/Tests/UnitTestsModel/RoleTest.cs | 2 +- 3 files changed, 1 insertion(+), 16 deletions(-) diff --git a/src/Tests/UnitTestsModel/CoachTest.cs b/src/Tests/UnitTestsModel/CoachTest.cs index c54f4c4..57f8b5d 100644 --- a/src/Tests/UnitTestsModel/CoachTest.cs +++ b/src/Tests/UnitTestsModel/CoachTest.cs @@ -32,18 +32,5 @@ namespace Model.Tests // Assert Assert.False(result); } - - [Fact] - public void CheckAdd_NullUser_ReturnsFalse() - { - // Arrange - var coach = new Coach(); - - // Act - var result = coach.CheckAdd(null); - - // Assert - Assert.False(result); - } } } \ No newline at end of file diff --git a/src/Tests/UnitTestsModel/RelationshipTest.cs b/src/Tests/UnitTestsModel/RelationshipTest.cs index b55d08c..5d69495 100644 --- a/src/Tests/UnitTestsModel/RelationshipTest.cs +++ b/src/Tests/UnitTestsModel/RelationshipTest.cs @@ -11,7 +11,6 @@ namespace Model.Tests int id = 1; int fromUserId = 2; int toUserId = 3; - string status = "Pending"; // Act var request = new RelationshipRequest @@ -25,7 +24,6 @@ namespace Model.Tests Assert.Equal(id, request.Id); Assert.Equal(fromUserId, request.FromUser); Assert.Equal(toUserId, request.ToUser); - Assert.Equal(status, request.Status); } } } \ No newline at end of file diff --git a/src/Tests/UnitTestsModel/RoleTest.cs b/src/Tests/UnitTestsModel/RoleTest.cs index aa9c0a5..5769808 100644 --- a/src/Tests/UnitTestsModel/RoleTest.cs +++ b/src/Tests/UnitTestsModel/RoleTest.cs @@ -9,7 +9,7 @@ namespace Model.Tests { // Arrange var role = new Athlete(); // Vous pouvez utiliser Athlete ou Coach selon votre besoin - var user = new User(); // Créez un objet User valide + var user = new User("hello13", "dkjd.png", "John", "Doe", "john@exemple.com", "password", "M", 180.5f, 75.3f, new System.DateTime(1990, 5, 15), new Athlete()); // Act bool result = role.AddUser(user);