Commit 21048170 authored by Matthias Betz's avatar Matthias Betz
Browse files

fixed test validation

parent 4ef4c11f
......@@ -22,8 +22,6 @@ import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.nio.charset.StandardCharsets;
import java.nio.file.Path;
import java.nio.file.Paths;
import java.time.ZonedDateTime;
import java.util.Locale;
......@@ -484,9 +482,8 @@ class QualityAdeTests {
}
});
Path file = Paths.get("test.gml");
validator.validate(new StreamSource(file.toFile()));
validator.validate(new StreamSource(stream));
return !foundErrors[0];
}
......
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<CityModel xmlns:xAL="urn:oasis:names:tc:ciq:xsdschema:xAL:2.0" xmlns:gml="http://www.opengis.net/gml" xmlns:wtr="http://www.opengis.net/citygml/waterbody/2.0" xmlns:app="http://www.opengis.net/citygml/appearance/2.0" xmlns="http://www.opengis.net/citygml/2.0" xmlns:veg="http://www.opengis.net/citygml/vegetation/2.0" xmlns:dem="http://www.opengis.net/citygml/relief/2.0" xmlns:tran="http://www.opengis.net/citygml/transportation/2.0" xmlns:bldg="http://www.opengis.net/citygml/building/2.0" xmlns:grp="http://www.opengis.net/citygml/cityobjectgroup/2.0" xmlns:tun="http://www.opengis.net/citygml/tunnel/2.0" xmlns:frn="http://www.opengis.net/citygml/cityfurniture/2.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:brid="http://www.opengis.net/citygml/bridge/2.0" xmlns:gen="http://www.opengis.net/citygml/generics/2.0" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:qual="https://transfer.hft-stuttgart.de/pages/citydoctor/qualityade/0.1.4" xmlns:luse="http://www.opengis.net/citygml/landuse/2.0" xsi:schemaLocation="https://transfer.hft-stuttgart.de/pages/citydoctor/qualityade/0.1.4 file:/C:/Job/QualityADE/QualityADERepo/citygml4j-quality-ade/target/classes/qualityAde.xsd">
<cityObjectMember>
<bldg:Building gml:id="testId">
<qual:validationResult>
<qual:ValidationResult>
<qual:validationPlanID xlink:href="#planId"/>
<qual:error>
<qual:GE_S_ALL_POLYGONS_WRONG_ORIENTATION>
<qual:geometryId>geomId</qual:geometryId>
</qual:GE_S_ALL_POLYGONS_WRONG_ORIENTATION>
</qual:error>
<qual:resultType>ERROR</qual:resultType>
</qual:ValidationResult>
</qual:validationResult>
</bldg:Building>
</cityObjectMember>
<gml:featureMember>
<qual:Validation gml:id="planId">
<qual:validationDate>2022-04-12T12:28:14.1485207+02:00</qual:validationDate>
<qual:validationSoftware>testSoftware</qual:validationSoftware>
<qual:statistics>
<qual:Statistics>
<qual:numErrorBridgeObjects>
<qual:FeatureStatistics>
<qual:numChecked>5</qual:numChecked>
<qual:numErrors>2</qual:numErrors>
</qual:FeatureStatistics>
</qual:numErrorBridgeObjects>
</qual:Statistics>
</qual:statistics>
<qual:validationPlan>
<qual:ValidationPlan>
<qual:globalParameters>
<qual:GlobalParameters>
<qual:parameter>
<qual:Parameter>
<qual:name>test</qual:name>
<qual:uom>uom</qual:uom>
<qual:value>5</qual:value>
</qual:Parameter>
</qual:parameter>
</qual:GlobalParameters>
</qual:globalParameters>
<qual:filter>
<qual:Filter>
<qual:checking>
<qual:Checking>
<qual:featureType>BRIDGE</qual:featureType>
</qual:Checking>
</qual:checking>
</qual:Filter>
</qual:filter>
<qual:requirement>
<qual:Requirement>
<qual:enabled>true</qual:enabled>
<qual:requirementType>R_GE_P_HOLE_OUTSIDE</qual:requirementType>
</qual:Requirement>
</qual:requirement>
</qual:ValidationPlan>
</qual:validationPlan>
</qual:Validation>
</gml:featureMember>
</CityModel>
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment