mirror of
https://github.com/cfpwastaken/planetiler-openmaptiles.git
synced 2026-02-04 12:31:10 +00:00
Fix service/man_made npe (#72)
This commit is contained in:
@@ -222,7 +222,7 @@ public class Transportation implements
|
||||
"highway", coalesce(highway, ""),
|
||||
"public_transport", coalesce(publicTransport, ""),
|
||||
"construction", coalesce(construction, "")
|
||||
), null) : manMade;
|
||||
), null) : isBridgeOrPier(manMade) ? manMade : null;
|
||||
}
|
||||
|
||||
static String highwaySubclass(String highwayClass, String publicTransport, String highway) {
|
||||
|
||||
@@ -497,6 +497,24 @@ public class TransportationTest extends AbstractLayerTest {
|
||||
))));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testIgnoreManMadeWhenNotBridgeOrPier() {
|
||||
// https://github.com/onthegomap/planetiler/issues/69
|
||||
assertFeatures(14, List.of(), process(lineFeature(Map.of(
|
||||
"man_made", "storage_tank",
|
||||
"service", "driveway"
|
||||
))));
|
||||
assertFeatures(14, List.of(), process(lineFeature(Map.of(
|
||||
"man_made", "courtyard",
|
||||
"service", "driveway"
|
||||
))));
|
||||
assertFeatures(14, List.of(), process(lineFeature(Map.of(
|
||||
"man_made", "courtyard",
|
||||
"service", "driveway",
|
||||
"name", "Named Driveway"
|
||||
))));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testRaceway() {
|
||||
assertFeatures(13, List.of(Map.of(
|
||||
|
||||
Reference in New Issue
Block a user