예제 #1
0
        public async Task ListAllCustomersTest()
        {
            var databaseRepoMock = new Mock <IDatabaseRepository>();

            databaseRepoMock.Setup(repo => repo.ReadDatabase().Result).Returns(TestDatabaseFilled);
            var customerDataService = new CustomerDataService(databaseRepoMock.Object, _mockLogger.Object);

            var customers = await customerDataService.ListAllCustomers();

            Assert.NotEmpty(customers);
        }