public void AddAddress_ShouldWork() { VipServicesContextTest contextTest = new VipServicesContextTest(keepExistingDB: false); VipServicesManager m = new VipServicesManager(new UnitOfWork(contextTest)); Address address = new Address("Groenlaan", "17", "Herzele"); Action act = () => { m.AddAddress("Groenlaan", "17", "Herzele"); }; act.Should().NotThrow <DomainException>(); Assert.AreEqual(1, contextTest.Addresses.Local.Count); var addressInDb = contextTest.Addresses.First(); Assert.AreEqual(addressInDb.StreetName, address.StreetName); Assert.AreEqual(addressInDb.StreetNumber, address.StreetNumber); Assert.AreEqual(addressInDb.Town, address.Town); }