Example #1
0
        public void Get_InCorrectInputDiseaseId_ReturnNull()
        {
            // Arrange
            TestData testData         = new TestData();
            var      mockDataProvider = new Mock <IDataAccessManager>();

            mockDataProvider.Setup(mock => mock.GetDisease(testData.disease.DiseaseId)).Returns(testData.disease);
            var service = new DiseaseManager(mockDataProvider.Object);

            // Act
            Disease disease = service.Get(testData.disease.DiseaseId + 1);

            // Assert
            Assert.IsNull(disease);
        }