Ejemplo n.º 1
0
        public void Delete_Assessment_Returns_Assessment()
        {
            // Arrange
            var fakeAssessment = new Assessment()
            {
                Id = 1000, Name = "test fake assessment", Duration = 10
            };

            assessmentRepository.Setup(x => x.Delete(1000));
            assessmentManager = new AssessmentManager(fakeUoW.Object, assessmentRepository.Object, null);
            //// Act
            assessmentManager.Delete(1000);

            //// Assert
            //Assert.IsNotNull(newAssessment, "Result is null");
            //Assert.IsInstanceOfType(newAssessment, typeof(Assessment), "Invalid Enitity");
            //Assert.AreEqual(1000, newAssessment.Id);
        }
 // DELETE api/assessments/5
 public HttpResponseMessage Delete(int id)
 {
     manager.Delete(id);
     return(Request.CreateResponse(HttpStatusCode.NoContent));
 }