diff --git a/test/eu/simstadt/regionchooser/test/ConvexHullCalculatorTests.java b/test/eu/simstadt/regionchooser/test/ConvexHullCalculatorTests.java index dc5807e2ffa2f8523ab632c95c6afaaffee8dd47..72485f7306ba0e0b833a14cd7e84a0492edf3849 100644 --- a/test/eu/simstadt/regionchooser/test/ConvexHullCalculatorTests.java +++ b/test/eu/simstadt/regionchooser/test/ConvexHullCalculatorTests.java @@ -22,8 +22,9 @@ public void testExtractConvexHullFromOneBuilding() throws Throwable { Path citygmlPath = repo.resolve("Gruenbuehl.proj/20140218_Gruenbuehl_LOD2_1building.gml"); Geometry hull = ConvexHullCalculator.calculateFromCityGML(citygmlPath); assertEquals(hull.getCoordinates().length, 4 + 1); // Convex hull of a building should be a closed rectangle - Point someBuildingPoint = gf.createPoint(new Coordinate(3515960.36, 5415667.91)); - assertTrue(hull.contains(someBuildingPoint)); + // Point someBuildingPoint = gf.createPoint(new Coordinate(3515960.36, 5415667.91)); // Original coordinates, GSK3 + Point someBuildingPoint = gf.createPoint(new Coordinate(9.21656126408, 48.8782253597)); // WGS84 + assertTrue("Hull should contain every building point", hull.contains(someBuildingPoint)); } @Test @@ -32,7 +33,8 @@ public void testExtractConvexHullFromOneSmallRegion() throws Throwable { Path citygmlPath = repo.resolve("Gruenbuehl.proj/Gruenbuehl_LOD2_ALKIS_1010.gml"); Geometry hull = ConvexHullCalculator.calculateFromCityGML(citygmlPath); assertTrue(hull.getCoordinates().length > 4); // Convex hull should have at least 4 corners - Point somewhereBetweenBuildings = gf.createPoint(new Coordinate(3515883.6668538367, 5415843.300640578)); - assertTrue(hull.contains(somewhereBetweenBuildings)); + // Point somewhereBetweenBuildings = gf.createPoint(new Coordinate(3515883.6668538367, 5415843.300640578)); // Original coordinates, GSK3 + Point somewhereBetweenBuildings = gf.createPoint(new Coordinate(9.21552249084, 48.87980446)); // WGS84 + assertTrue("Hull should contain region between buildings", hull.contains(somewhereBetweenBuildings)); } }