public void AddingTest() { Mock <IDataFiller> mockRepository = new Mock <IDataFiller>(); mockRepository.Setup(x => x.Fill()).Returns(data); Repository repository = new Repository(mockRepository.Object); List <Burger> Burgers = new List <Burger>(); Burger Burger = new Burger("Testowa", 12.34f, "test"); Burgers.Add(Burger); Customer customer = new Customer("Ala", "kotowa", "Ola@as", "123456789"); Employee employee = new Employee("Włodek"); Order order = new Order(customer, Burgers, employee, 10); repository.AddCustomer(customer); repository.AddEmployee(employee); repository.AddOrder(order); repository.AddBurger(Burger); repository.AddOrderToArchive(order); List <Burger> BurgersL = (List <Burger>)repository.GetAllBurgers(); List <Customer> customers = (List <Customer>)repository.GetAllCustomers(); List <Employee> employees = (List <Employee>)repository.GetAllEmployees(); List <Order> orders = (List <Order>)repository.GetAllOrders(); BurgersL.Count.Should().Be(4, "because we added one item to three items in the collection"); customers.Count.Should().Be(5, "because we added one item to four items in the collection"); employees.Count.Should().Be(4, "because we added one item to three items in the collection"); orders.Count.Should().Be(1, "because we added one item to zero items in the collection"); Assert.IsTrue(BurgersL.Contains(Burger)); Assert.IsTrue(customers.Contains(customer)); Assert.IsTrue(employees.Contains(employee)); Assert.IsTrue(orders.Contains(order)); }