public StubDataCountryRepository(MemoryRepository <Country> memRepository) { this._memRepository = memRepository; memRepository.Add(Country.Create(new Guid("229074BD-2356-4B5A-8619-CDEBBA71CC21"), "United Kingdom")); memRepository.Add(Country.Create(new Guid("F3C78DD5-026F-4402-8A19-DAA956ACE593"), "United States")); }
public StubDataCustomerRepository(MemoryRepository <Customer> memRepository) { _memRepository = memRepository; var customer = Customer.Create(new Guid("5D5020DA-47DF-4C82-A722-C8DEAF06AE23"), "john", "smith", "*****@*****.**", Country.Create(new Guid("229074BD-2356-4B5A-8619-CDEBBA71CC21"), "United Kingdom")); customer.Add(CreditCard.Create(customer, "MR J SMITH", "123122131", DateTime.Today.AddDays(1))); _memRepository.Add(customer); }
public void Add(Customer entity) { _memRepository.Add(entity); }