Example #1
0
        public async Task Given_GetExamById_When_IdIsValid_Then_OkStatusCode()
        {
            //Arrange
            var guid = new Guid("ef7e98df-26ed-4b21-b874-c3a2815d18ac");

            mockRepo
            .Setup(e => e.FindById(guid))
            .ReturnsAsync(new ExamDetailsModel());

            // Act
            var result = await controller.GetExamById(guid);

            // Assert
            Assert.IsType <OkObjectResult>(result);
        }