public void ReadExcludedPreprocessorLocations_InvalidValueInReadLocation_ThrowsCriticalFileReadException() { // Setup using (var reader = new HydraRingSettingsDatabaseReader(invalidDatabasePath)) { // Call TestDelegate test = () => reader.ReadExcludedPreprocessorLocations().ToArray(); // Assert Assert.Throws <CriticalFileReadException>(test); } }
public void ReadExcludedPreprocessorLocations_EmptyTable_ReturnsEmptyEnumerable() { // Setup using (var reader = new HydraRingSettingsDatabaseReader(emptyDatabasePath)) { // Call IEnumerable <long> locations = reader.ReadExcludedPreprocessorLocations(); // Assert CollectionAssert.IsEmpty(locations); } }
public void ReadExcludedPreprocessorLocations_TableWithRows_ReturnsAllLocationIdsInTable() { // Setup using (var reader = new HydraRingSettingsDatabaseReader(completeDatabasePath)) { // Call IEnumerable <long> locations = reader.ReadExcludedPreprocessorLocations(); // Assert CollectionAssert.AreEqual(new[] { 700136 }, locations); } }