Skip to content

v0.2.53..v0.2.54 changeset ConvertCmdTest.sh

Garret Voltz edited this page Mar 31, 2020 · 1 revision
diff --git a/test-files/cmd/slow/ConvertCmdTest.sh b/test-files/cmd/slow/ConvertCmdTest.sh
index b69ba56..92d2ade 100755
--- a/test-files/cmd/slow/ConvertCmdTest.sh
+++ b/test-files/cmd/slow/ConvertCmdTest.sh
@@ -5,34 +5,36 @@ OUTPUT_DIR=test-output/cmd/slow/ConvertCmdTest
 rm -rf $OUTPUT_DIR
 mkdir -p $OUTPUT_DIR
 
+CONFIG="-C Testing.conf"
+
 echo "Multiple OSM to single OSM..."
-hoot convert -C Testing.conf test-files/ToyTestA.osm test-files/ToyTestB.osm $OUTPUT_DIR/ToyTestC.osm
-hoot diff test-files/cmd/slow/ConvertCmdTest/ToyTestC.osm $OUTPUT_DIR/ToyTestC.osm
+hoot convert $CONFIG test-files/ToyTestA.osm test-files/ToyTestB.osm $OUTPUT_DIR/ToyTestC.osm
+hoot diff $CONFIG test-files/cmd/slow/ConvertCmdTest/ToyTestC.osm $OUTPUT_DIR/ToyTestC.osm
 
 echo "PBF to OSM..."
-hoot convert -C Testing.conf test-files/ToyTestA.osm.pbf $OUTPUT_DIR/ToyTestA.osm
+hoot convert $CONFIG test-files/ToyTestA.osm.pbf $OUTPUT_DIR/ToyTestA.osm
 cat $OUTPUT_DIR/ToyTestA.osm
 
 echo "PBF to SHP..."
-hoot convert -C Testing.conf test-files/ToyTestA.osm.pbf $OUTPUT_DIR/ToyTestA.shp
+hoot convert $CONFIG test-files/ToyTestA.osm.pbf $OUTPUT_DIR/ToyTestA.shp
 
 echo "SHP to OSM..."
 # comparing shapefiles is kinda hard. We'll convert it to a .osm file first.
-hoot convert -C Testing.conf $OUTPUT_DIR/ToyTestA.shp $OUTPUT_DIR/ToyTestAShp.osm
-hoot diff $OUTPUT_DIR/ToyTestAShp.osm $OUTPUT_DIR/ToyTestAShp.osm
+hoot convert $CONFIG $OUTPUT_DIR/ToyTestA.shp $OUTPUT_DIR/ToyTestAShp.osm
+hoot diff $CONFIG $OUTPUT_DIR/ToyTestAShp.osm $OUTPUT_DIR/ToyTestAShp.osm
 
 echo "Streaming XML read and write..."
-hoot convert -C Testing.conf -D writer.xml.sort.by.id="false" test-files/ToyTestA.osm $OUTPUT_DIR/ToyTestA2.osm
-hoot diff test-files/ToyTestA.osm $OUTPUT_DIR/ToyTestA2.osm
+hoot convert $CONFIG -D writer.xml.sort.by.id="false" test-files/ToyTestA.osm $OUTPUT_DIR/ToyTestA2.osm
+hoot diff $CONFIG test-files/ToyTestA.osm $OUTPUT_DIR/ToyTestA2.osm
 
 echo "POI Criterion..."
 # test streaming filter output to pois only
-hoot convert -C Testing.conf -D writer.xml.sort.by.id="false" -D convert.ops="hoot::PoiCriterion" test-files/conflate/unified/AllDataTypesA.osm.pbf $OUTPUT_DIR/AllDataTypesA.osm
-hoot diff test-files/cmd/slow/ConvertCmdTest/AllDataTypesAPois.osm $OUTPUT_DIR/AllDataTypesA.osm
+hoot convert $CONFIG -D writer.xml.sort.by.id="false" -D convert.ops="hoot::PoiCriterion" test-files/conflate/unified/AllDataTypesA.osm.pbf $OUTPUT_DIR/AllDataTypesA.osm
+hoot diff $CONFIG test-files/cmd/slow/ConvertCmdTest/AllDataTypesAPois.osm $OUTPUT_DIR/AllDataTypesA.osm
 
 echo "Check for invalid characters. You should see 3 sets of warnings."
-hoot convert -C Testing.conf test-files/io/InvalidCharacters.osm $OUTPUT_DIR/InvalidCharacters.osm
+hoot convert $CONFIG test-files/io/InvalidCharacters.osm $OUTPUT_DIR/InvalidCharacters.osm
 
 echo "Translation check..."
 # This wasn't working at one point.
-hoot convert -D convert.ops=hoot::SchemaTranslationVisitor -D schema.translation.direction=toogr -D schema.translation.script=translations/MGCP_TRD4.js test-files/ToyTestA.osm $OUTPUT_DIR/translation-check-out.gdb
+hoot convert $CONFIG -D convert.ops=hoot::SchemaTranslationVisitor -D schema.translation.direction=toogr -D schema.translation.script=translations/MGCP_TRD4.js test-files/ToyTestA.osm $OUTPUT_DIR/translation-check-out.gdb
Clone this wiki locally