public void ReadAllLocationsTest() { try { DbLocation dbLocation = new DbLocation(); List <Location> locations = dbLocation.FindAll(); Assert.IsTrue(locations.Count > 0); } catch (FaultException <NoLocationsInDatabaseException> ) { Assert.Fail(); } catch (FaultException <System.Exception> ) { Assert.Fail(); } }
/// <summary> /// gets all Locations /// </summary> /// <returns></returns> public List <Location> GetAllLocations() { return(_dbLocation.FindAll()); }