public void ShouldGetClientsInOrangeZone() { //Arrange var clientsWhichHaveZeroBalance = clientTableRepository.GetClientsInOrangeZone(); IEnumerable <ClientEntity> clientsInOrangeZone; //Act clientsInOrangeZone = clientsService.GetClientsInOrangeZone(); //Assert Assert.AreEqual(clientsWhichHaveZeroBalance, clientsInOrangeZone); }
public void Initialize() { clientTableRepository = Substitute.For <IClientTableRepository>(); clientTableRepository.GetById(1).Returns(new ClientEntity() { Id = 1, Balance = 0M, Name = "Vlad Blood" }); clientTableRepository.GetClientsInOrangeZone() .Returns(new List <ClientEntity>()); clientTableRepository.GetClientsInBlackZone() .Returns(new List <ClientEntity>()); clientsService = new ClientsService(clientTableRepository); }
public ICollection <ClientEntity> GetClientsInOrangeZone() { return(clientTableRepository.GetClientsInOrangeZone()); }