From de010bd60e08c5031539355c45486e21a0143d85 Mon Sep 17 00:00:00 2001 From: Alex <22rial1mpg@hft-stuttgart.de> Date: Fri, 26 Jul 2024 09:33:26 +0200 Subject: [PATCH] Reworked JUnit test and disabled some of the False-Positive tests which induced a massive memory load --- .../checks/geometry/SolidSelfIntCheckTest.java | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/CityDoctorParent/CityDoctorValidation/src/test/java/de/hft/stuttgart/citydoctor2/checks/geometry/SolidSelfIntCheckTest.java b/CityDoctorParent/CityDoctorValidation/src/test/java/de/hft/stuttgart/citydoctor2/checks/geometry/SolidSelfIntCheckTest.java index 7e001ce5..98424492 100644 --- a/CityDoctorParent/CityDoctorValidation/src/test/java/de/hft/stuttgart/citydoctor2/checks/geometry/SolidSelfIntCheckTest.java +++ b/CityDoctorParent/CityDoctorValidation/src/test/java/de/hft/stuttgart/citydoctor2/checks/geometry/SolidSelfIntCheckTest.java @@ -123,6 +123,7 @@ public class SolidSelfIntCheckTest { check.check(buildingGeom); CheckResult cr = buildingGeom.getCheckResult(check); assertNotNull(cr); + //Ensure that checker did not find the false-positive self intersection assertEquals("Known False-Positive self-intersection was detected as error", ResultStatus.OK, cr.getResultStatus()); } @@ -130,10 +131,10 @@ public class SolidSelfIntCheckTest { } @Test - public void testKnownFalsePositiveExample3() throws CityGmlParseException, InvalidGmlFileException { + public void testKnownFalsePositiveExample_BigMesh1() throws CityGmlParseException, InvalidGmlFileException { ValidationConfiguration config = ValidationConfiguration.loadStandardValidationConfig(); config.setSchematronFilePathInGlobalParameters(null); - CityDoctorModel m = CityGmlParser.parseCityGmlFile("src/test/resources/SolidSelfIntTest-known_false_positive3.gml", config.getParserConfiguration()); + CityDoctorModel m = CityGmlParser.parseCityGmlFile("src/test/resources/SolidSelfIntTest-known_false_positive_Big_Mesh1.gml", config.getParserConfiguration()); Checker c = new Checker(config, m); c.runChecks(); Building building = m.getBuildings().get(0); @@ -145,7 +146,6 @@ public class SolidSelfIntCheckTest { check.check(buildingGeom); CheckResult cr = buildingGeom.getCheckResult(check); assertNotNull(cr); - //Ensure that checker did not find the false-positive self intersection assertEquals("Known False-Positive self-intersection was detected as error", ResultStatus.OK, cr.getResultStatus()); } @@ -153,10 +153,10 @@ public class SolidSelfIntCheckTest { } @Test - public void testKnownFalsePositiveExample4() throws CityGmlParseException, InvalidGmlFileException { + public void testKnownFalsePositiveExample_BigMesh2() throws CityGmlParseException, InvalidGmlFileException { ValidationConfiguration config = ValidationConfiguration.loadStandardValidationConfig(); config.setSchematronFilePathInGlobalParameters(null); - CityDoctorModel m = CityGmlParser.parseCityGmlFile("src/test/resources/SolidSelfIntTest-known_false_positive4.gml", config.getParserConfiguration()); + CityDoctorModel m = CityGmlParser.parseCityGmlFile("src/test/resources/SolidSelfIntTest-known_false_positive_Big_Mesh2.gml", config.getParserConfiguration()); Checker c = new Checker(config, m); c.runChecks(); Building building = m.getBuildings().get(0); @@ -174,5 +174,7 @@ public class SolidSelfIntCheckTest { } + + } -- GitLab