public void TestDeleteNotInUse() { Country country = _dataGenerator.CreateCountry(); ICountryDao countryDao = new CountryDao(_graphClient); countryDao.Delete(country); Assert.AreEqual(0, countryDao.GetAll().Count); }
public void TestDeleteInUse() { Country country = _dataGenerator.CreateCountry(); Route route = _dataGenerator.CreateRouteInCountry(country: country); ICountryDao countryDao = new CountryDao(_graphClient); Action action = ()=>countryDao.Delete(country); action.ShouldThrow<NodeInUseException>(); }