Ejemplo n.º 1
0
        public async Task DeleteSurveyAsync_ReturnOkResult()
        {
            var id = 5;

            _mockMyDbContext.Setup(
                db => db.DeleteSurveyAsync(id)).Returns(Task.CompletedTask);

            var surveysController = new SurveysController(_mockMyDbContext.Object);

            var result = await surveysController.DeleteSurveyAsync(id);

            Assert.True(result is OkResult);
        }