public void HasAttribute_VariousCases_ReturnTrueIfMatchesInProperCaseHasBeenFound(string attributeName, bool expectedResult) { // Setup string shapefileFilePath = TestHelper.GetTestDataPath(TestDataPath.Core.Components.Gis.IO, "Single_Polygon_with_ID.shp"); using (var reader = new PolygonShapeFileReader(shapefileFilePath)) { // Call bool result = reader.HasAttribute(attributeName); // Assert Assert.AreEqual(expectedResult, result); } }
public void HasAttribute_AttributeInShapefile_ReturnTrue() { // Setup string shapefileFilePath = TestHelper.GetTestDataPath(TestDataPath.Core.Components.Gis.IO, "Single_Polygon_with_ID.shp"); using (var reader = new PolygonShapeFileReader(shapefileFilePath)) { // Call bool result = reader.HasAttribute("id"); // Assert Assert.IsTrue(result); } }