public void PutHoliday() { // Arrange HolidayController controller = new HolidayController(); Espl.Linkup.Domain.Leave.Holiday.Holiday HolidayObj = new Espl.Linkup.Domain.Leave.Holiday.Holiday { ID = 1, Title = "Put request sucessfull", WeekDay = "Sunday", HolidayType = "Fixed", HolidayDate = new DateTime() }; var actResult = controller.Put(1, HolidayObj); // Act var result = actResult as OkNegotiatedContentResult <Espl.Linkup.Domain.Leave.Holiday.Holiday>; // Assert Assert.IsNotNull(result); Assert.IsTrue(result.Content.Title.Equals("Put request sucessfull")); }