Exemplo n.º 1
0
        public void ShouldProvideStatementsForCustomer()
        {
            var repository = new StatementRepository();

            var c1 = new Customer("One");
            var c2 = new Customer("Two");

            var statement = new Statement(c1);

            repository.Add(statement);

            repository.Add(new Statement(c2));

            var c1statements = repository.FindByCustomer(c1);

            Assert.That(c1statements.Contains(statement));
            Assert.That(c1statements.Count(), Is.EqualTo(1));
        }
Exemplo n.º 2
0
 public ViewResult Index()
 {
     return(View("Index", repository.FindByCustomer(customer)));
 }