[generator][tests] Add OsmType_SimpleTypesSmoke test.

This commit is contained in:
tatiana-yan 2019-12-27 10:39:47 +03:00 committed by Maksim Andrianov
parent e510b792f0
commit d411b5659b

View file

@ -936,3 +936,627 @@ UNIT_CLASS_TEST(TestWithClassificator, OsmType_DoNotMergeTags)
TEST(!params.IsTypeExist(GetType({"shop", "photo"})), (params));
}
}
UNIT_CLASS_TEST(TestWithClassificator, OsmType_SimpleTypesSmoke)
{
Tags const simpleTypes = {
// Filtered out by MatchTypes filter because have no styles.
// {"aeroway", "apron"},
// {"area:highway", "cycleway"},
// {"area:highway", "motorway"},
// {"area:highway", "path"},
// {"area:highway", "primary"},
// {"area:highway", "residential"},
// {"area:highway", "secondary"},
// {"area:highway", "service"},
// {"area:highway", "steps"},
// {"area:highway", "tertiary"},
// {"area:highway", "track"},
// {"area:highway", "trunk"},
// {"area:highway", "unclassified"},
// {"barrier", "cycle_barrier"},
// {"boundary", "administrative"},
// {"communication", "line"},
// {"earthquake:damage", "spontaneous_camp"},
// {"highway", "platform"},
// {"highway", "traffic_signals"},
// {"historic", "battlefield"},
// {"landuse", "brownfield"},
// {"landuse", "farm"},
// {"landuse", "farmyard"},
// {"landuse", "greenfield"},
// {"landuse", "greenhouse_horticulture"},
// {"landuse", "residential"},
// {"landuse", "retail"},
// {"man_made", "cairn"},
// {"man_made", "pipeline"},
// {"man_made", "surveillance"},
// {"man_made", "tower"},
// {"man_made", "wastewater_plant"},
// {"man_made", "water_tower"},
// {"man_made", "water_well"},
// {"mapswithme", "grid"},
// {"military", "bunker"},
// {"natural", "cliff"},
// {"natural", "meadow"},
// {"natural", "orchard"},
// {"natural", "tree"},
// {"natural", "tree_row"},
// {"natural", "vineyard"},
// {"noexit", "motor_vehicle"},
// {"olympics", "attraction"},
// {"olympics", "bike_sport"},
// {"olympics", "live_site"},
// {"olympics", "official_building"},
// {"olympics", "stadium"},
// {"olympics", "stadium_main"},
// {"olympics", "transport_airport"},
// {"olympics", "transport_boat"},
// {"olympics", "transport_bus"},
// {"olympics", "transport_cable"},
// {"olympics", "transport_railway"},
// {"olympics", "transport_subway"},
// {"olympics", "transport_tram"},
// {"olympics", "water_sport"},
// {"place", "county"},
// {"power", "generator"},
// {"power", "minor_line"},
// {"power", "pole"},
// {"railway", "crossing"},
// {"railway", "proposed"},
// {"railway", "razed"},
// {"railway", "siding"},
// {"railway", "spur"},
// {"railway", "subway"},
// {"traffic_calming", "bump"},
// {"traffic_calming", "hump"},
{"aerialway", "cable_car"},
{"aerialway", "chair_lift"},
{"aerialway", "drag_lift"},
{"aerialway", "gondola"},
{"aerialway", "mixed_lift"},
{"aerialway", "station"},
{"aeroway", "aerodrome"},
{"aeroway", "gate"},
{"aeroway", "helipad"},
{"aeroway", "runway"},
{"aeroway", "taxiway"},
{"aeroway", "terminal"},
{"amenity", "arts_centre"},
{"amenity", "atm"},
{"amenity", "bank"},
{"amenity", "bar"},
{"amenity", "bbq"},
{"amenity", "bench"},
{"amenity", "bicycle_parking"},
{"amenity", "bicycle_rental"},
{"amenity", "biergarten"},
{"amenity", "brothel"},
{"amenity", "bureau_de_change"},
{"amenity", "bus_station"},
{"amenity", "cafe"},
{"amenity", "car_rental"},
{"amenity", "car_sharing"},
{"amenity", "car_wash"},
{"amenity", "casino"},
{"amenity", "charging_station"},
{"amenity", "childcare"},
{"amenity", "cinema"},
{"amenity", "clinic"},
{"amenity", "college"},
{"amenity", "community_centre"},
{"amenity", "courthouse"},
{"amenity", "dentist"},
{"amenity", "doctors"},
{"amenity", "drinking_water"},
{"amenity", "driving_school"},
{"amenity", "embassy"},
{"amenity", "fast_food"},
{"amenity", "ferry_terminal"},
{"amenity", "fire_station"},
{"amenity", "food_court"},
{"amenity", "fountain"},
{"amenity", "fuel"},
{"amenity", "grave_yard"},
{"amenity", "hospital"},
{"amenity", "hunting_stand"},
{"amenity", "ice_cream"},
{"amenity", "internet_cafe"},
{"amenity", "kindergarten"},
{"amenity", "library"},
{"amenity", "marketplace"},
{"amenity", "motorcycle_parking"},
{"amenity", "nightclub"},
{"amenity", "nursing_home"},
{"amenity", "parking"},
{"amenity", "parking_space"},
{"amenity", "payment_terminal"},
{"amenity", "pharmacy"},
{"amenity", "place_of_worship"},
{"amenity", "police"},
{"amenity", "post_box"},
{"amenity", "post_office"},
{"amenity", "prison"},
{"amenity", "pub"},
{"amenity", "public_bookcase"},
{"amenity", "recycling"},
{"amenity", "restaurant"},
{"amenity", "school"},
{"amenity", "shelter"},
{"amenity", "shower"},
{"amenity", "speed_trap"},
{"amenity", "taxi"},
{"amenity", "telephone"},
{"amenity", "theatre"},
{"amenity", "toilets"},
{"amenity", "townhall"},
{"amenity", "university"},
{"amenity", "veterinary"},
{"amenity", "waste_basket"},
{"amenity", "waste_disposal"},
{"amenity", "water_point"},
{"area:highway", "footway"},
{"area:highway", "living_street"},
{"area:highway", "pedestrian"},
{"barrier", "block"},
{"barrier", "bollard"},
{"barrier", "border_control"},
{"barrier", "city_wall"},
{"barrier", "entrance"},
{"barrier", "fence"},
{"barrier", "gate"},
{"barrier", "hedge"},
{"barrier", "lift_gate"},
{"barrier", "retaining_wall"},
{"barrier", "stile"},
{"barrier", "toll_booth"},
{"barrier", "wall"},
{"boundary", "national_park"},
{"building", "has_parts"},
{"building", "train_station"},
{"craft", "brewery"},
{"craft", "carpenter"},
{"craft", "electrician"},
{"craft", "gardener"},
{"craft", "hvac"},
{"craft", "metal_construction"},
{"craft", "painter"},
{"craft", "photographer"},
{"craft", "plumber"},
{"craft", "shoemaker"},
{"craft", "tailor"},
{"cuisine", "african"},
{"cuisine", "american"},
{"cuisine", "arab"},
{"cuisine", "argentinian"},
{"cuisine", "asian"},
{"cuisine", "austrian"},
{"cuisine", "bagel"},
{"cuisine", "balkan"},
{"cuisine", "barbecue"},
{"cuisine", "bavarian"},
{"cuisine", "beef_bowl"},
{"cuisine", "brazilian"},
{"cuisine", "breakfast"},
{"cuisine", "burger"},
{"cuisine", "buschenschank"},
{"cuisine", "cake"},
{"cuisine", "caribbean"},
{"cuisine", "chicken"},
{"cuisine", "chinese"},
{"cuisine", "coffee_shop"},
{"cuisine", "crepe"},
{"cuisine", "croatian"},
{"cuisine", "curry"},
{"cuisine", "deli"},
{"cuisine", "diner"},
{"cuisine", "donut"},
{"cuisine", "ethiopian"},
{"cuisine", "filipino"},
{"cuisine", "fine_dining"},
{"cuisine", "fish"},
{"cuisine", "fish_and_chips"},
{"cuisine", "french"},
{"cuisine", "friture"},
{"cuisine", "georgian"},
{"cuisine", "german"},
{"cuisine", "greek"},
{"cuisine", "grill"},
{"cuisine", "heuriger"},
{"cuisine", "hotdog"},
{"cuisine", "hungarian"},
{"cuisine", "ice_cream"},
{"cuisine", "indian"},
{"cuisine", "indonesian"},
{"cuisine", "international"},
{"cuisine", "irish"},
{"cuisine", "italian"},
{"cuisine", "italian_pizza"},
{"cuisine", "japanese"},
{"cuisine", "kebab"},
{"cuisine", "korean"},
{"cuisine", "lao"},
{"cuisine", "lebanese"},
{"cuisine", "local"},
{"cuisine", "malagasy"},
{"cuisine", "malaysian"},
{"cuisine", "mediterranean"},
{"cuisine", "mexican"},
{"cuisine", "moroccan"},
{"cuisine", "noodles"},
{"cuisine", "oriental"},
{"cuisine", "pancake"},
{"cuisine", "pasta"},
{"cuisine", "persian"},
{"cuisine", "peruvian"},
{"cuisine", "pizza"},
{"cuisine", "polish"},
{"cuisine", "portuguese"},
{"cuisine", "ramen"},
{"cuisine", "regional"},
{"cuisine", "russian"},
{"cuisine", "sandwich"},
{"cuisine", "sausage"},
{"cuisine", "savory_pancakes"},
{"cuisine", "seafood"},
{"cuisine", "soba"},
{"cuisine", "spanish"},
{"cuisine", "steak_house"},
{"cuisine", "sushi"},
{"cuisine", "tapas"},
{"cuisine", "tea"},
{"cuisine", "thai"},
{"cuisine", "turkish"},
{"cuisine", "vegan"},
{"cuisine", "vegetarian"},
{"cuisine", "vietnamese"},
{"emergency", "defibrillator"},
{"emergency", "fire_hydrant"},
{"emergency", "phone"},
{"highway", "bridleway"},
{"highway", "bus_stop"},
{"highway", "construction"},
{"highway", "cycleway"},
{"highway", "footway"},
{"highway", "ford"},
{"highway", "living_street"},
{"highway", "motorway"},
{"highway", "motorway_junction"},
{"highway", "motorway_link"},
{"highway", "path"},
{"highway", "pedestrian"},
{"highway", "primary"},
{"highway", "primary_link"},
{"highway", "proposed"},
{"highway", "raceway"},
{"highway", "residential"},
{"highway", "rest_area"},
{"highway", "road"},
{"highway", "secondary"},
{"highway", "secondary_link"},
{"highway", "service"},
{"highway", "services"},
{"highway", "speed_camera"},
{"highway", "steps"},
{"highway", "tertiary"},
{"highway", "tertiary_link"},
{"highway", "track"},
{"highway", "trunk"},
{"highway", "trunk_link"},
{"highway", "unclassified"},
{"highway", "world_level"},
{"highway", "world_towns_level"},
{"historic", "archaeological_site"},
{"historic", "boundary_stone"},
{"historic", "castle"},
{"historic", "citywalls"},
{"historic", "fort"},
{"historic", "memorial"},
{"historic", "monument"},
{"historic", "museum"},
{"historic", "ruins"},
{"historic", "ship"},
{"historic", "tomb"},
{"historic", "wayside_cross"},
{"historic", "wayside_shrine"},
{"hwtag", "bidir_bicycle"},
{"hwtag", "lit"},
{"hwtag", "nobicycle"},
{"hwtag", "nocar"},
{"hwtag", "nofoot"},
{"hwtag", "oneway"},
{"hwtag", "private"},
{"hwtag", "toll"},
{"hwtag", "yesbicycle"},
{"hwtag", "yescar"},
{"hwtag", "yesfoot"},
{"internet_access", "wlan"},
{"junction", "roundabout"},
{"landuse", "allotments"},
{"landuse", "basin"},
{"landuse", "cemetery"},
{"landuse", "churchyard"},
{"landuse", "commercial"},
{"landuse", "construction"},
{"landuse", "farmland"},
{"landuse", "field"},
{"landuse", "forest"},
{"landuse", "garages"},
{"landuse", "grass"},
{"landuse", "industrial"},
{"landuse", "landfill"},
{"landuse", "meadow"},
{"landuse", "military"},
{"landuse", "orchard"},
{"landuse", "quarry"},
{"landuse", "railway"},
{"landuse", "recreation_ground"},
{"landuse", "reservoir"},
{"landuse", "salt_pond"},
{"landuse", "village_green"},
{"landuse", "vineyard"},
{"leisure", "common"},
{"leisure", "dog_park"},
{"leisure", "fitness_centre"},
{"leisure", "fitness_station"},
{"leisure", "garden"},
{"leisure", "golf_course"},
{"leisure", "ice_rink"},
{"leisure", "landscape_reserve"},
{"leisure", "marina"},
{"leisure", "nature_reserve"},
{"leisure", "park"},
{"leisure", "pitch"},
{"leisure", "playground"},
{"leisure", "recreation_ground"},
{"leisure", "sauna"},
{"leisure", "slipway"},
{"leisure", "sports_centre"},
{"leisure", "stadium"},
{"leisure", "swimming_pool"},
{"leisure", "track"},
{"leisure", "water_park"},
{"man_made", "breakwater"},
{"man_made", "chimney"},
{"man_made", "cutline"},
{"man_made", "lighthouse"},
{"man_made", "pier"},
{"man_made", "water_tap"},
{"man_made", "windmill"},
{"man_made", "works"},
{"natural", "bare_rock"},
{"natural", "bay"},
{"natural", "beach"},
{"natural", "cape"},
{"natural", "cave_entrance"},
{"natural", "coastline"},
{"natural", "geyser"},
{"natural", "glacier"},
{"natural", "grassland"},
{"natural", "heath"},
{"natural", "hot_spring"},
{"natural", "lake"},
{"natural", "land"},
{"natural", "peak"},
{"natural", "pond"},
{"natural", "rock"},
{"natural", "salt_pond"},
{"natural", "scrub"},
{"natural", "spring"},
{"natural", "volcano"},
{"natural", "water"},
{"natural", "wetland"},
{"natural", "wood"},
{"office", "company"},
{"office", "estate_agent"},
{"office", "government"},
{"office", "insurance"},
{"office", "lawyer"},
{"office", "ngo"},
{"office", "telecommunication"},
{"piste:lift", "j-bar"},
{"piste:lift", "magic_carpet"},
{"piste:lift", "platter"},
{"piste:lift", "rope_tow"},
{"piste:lift", "t-bar"},
{"piste:type", "downhill"},
{"piste:type", "nordic"},
{"piste:type", "sled"},
{"place", "city"},
{"place", "continent"},
{"place", "country"},
{"place", "farm"},
{"place", "hamlet"},
{"place", "island"},
{"place", "islet"},
{"place", "isolated_dwelling"},
{"place", "locality"},
{"place", "neighbourhood"},
{"place", "ocean"},
{"place", "region"},
{"place", "sea"},
{"place", "square"},
{"place", "state"},
{"place", "suburb"},
{"place", "town"},
{"place", "village"},
{"power", "line"},
{"power", "station"},
{"power", "substation"},
{"power", "tower"},
{"psurface", "paved_bad"},
{"psurface", "paved_good"},
{"psurface", "unpaved_bad"},
{"psurface", "unpaved_good"},
{"public_transport", "platform"},
{"railway", "abandoned"},
{"railway", "construction"},
{"railway", "disused"},
{"railway", "funicular"},
{"railway", "halt"},
{"railway", "level_crossing"},
{"railway", "light_rail"},
{"railway", "monorail"},
{"railway", "narrow_gauge"},
{"railway", "platform"},
{"railway", "preserved"},
{"railway", "rail"},
{"railway", "station"},
{"railway", "subway_entrance"},
{"railway", "tram"},
{"railway", "tram_stop"},
{"railway", "yard"},
{"route", "ferry"},
{"route", "shuttle_train"},
{"shop", "alcohol"},
{"shop", "bakery"},
{"shop", "beauty"},
{"shop", "beverages"},
{"shop", "bicycle"},
{"shop", "bookmaker"},
{"shop", "books"},
{"shop", "butcher"},
{"shop", "car"},
{"shop", "car_parts"},
{"shop", "car_repair"},
{"shop", "chemist"},
{"shop", "chocolate"},
{"shop", "coffee"},
{"shop", "computer"},
{"shop", "confectionery"},
{"shop", "convenience"},
{"shop", "copyshop"},
{"shop", "cosmetics"},
{"shop", "department_store"},
{"shop", "doityourself"},
{"shop", "dry_cleaning"},
{"shop", "electronics"},
{"shop", "erotic"},
{"shop", "fabric"},
{"shop", "florist"},
{"shop", "funeral_directors"},
{"shop", "furniture"},
{"shop", "garden_centre"},
{"shop", "gift"},
{"shop", "greengrocer"},
{"shop", "hairdresser"},
{"shop", "hardware"},
{"shop", "jewelry"},
{"shop", "kiosk"},
{"shop", "laundry"},
{"shop", "mall"},
{"shop", "massage"},
{"shop", "mobile_phone"},
{"shop", "money_lender"},
{"shop", "motorcycle"},
{"shop", "music"},
{"shop", "musical_instrument"},
{"shop", "newsagent"},
{"shop", "optician"},
{"shop", "outdoor"},
{"shop", "pawnbroker"},
{"shop", "pet"},
{"shop", "photo"},
{"shop", "seafood"},
{"shop", "shoes"},
{"shop", "sports"},
{"shop", "stationery"},
{"shop", "supermarket"},
{"shop", "tattoo"},
{"shop", "tea"},
{"shop", "ticket"},
{"shop", "toys"},
{"shop", "travel_agency"},
{"shop", "tyres"},
{"shop", "variety_store"},
{"shop", "video"},
{"shop", "wine"},
{"sponsored", "booking"},
{"sponsored", "holiday"},
{"sponsored", "opentable"},
{"sponsored", "partner1"},
{"sponsored", "partner10"},
{"sponsored", "partner11"},
{"sponsored", "partner12"},
{"sponsored", "partner13"},
{"sponsored", "partner14"},
{"sponsored", "partner15"},
{"sponsored", "partner16"},
{"sponsored", "partner17"},
{"sponsored", "partner18"},
{"sponsored", "partner19"},
{"sponsored", "partner2"},
{"sponsored", "partner20"},
{"sponsored", "partner3"},
{"sponsored", "partner4"},
{"sponsored", "partner5"},
{"sponsored", "partner6"},
{"sponsored", "partner7"},
{"sponsored", "partner8"},
{"sponsored", "partner9"},
{"sponsored", "promo_catalog"},
{"sport", "american_football"},
{"sport", "archery"},
{"sport", "athletics"},
{"sport", "australian_football"},
{"sport", "baseball"},
{"sport", "basketball"},
{"sport", "bowls"},
{"sport", "cricket"},
{"sport", "curling"},
{"sport", "diving"},
{"sport", "equestrian"},
{"sport", "football"},
{"sport", "gymnastics"},
{"sport", "handball"},
{"sport", "multi"},
{"sport", "scuba_diving"},
{"sport", "shooting"},
{"sport", "skiing"},
{"sport", "soccer"},
{"sport", "swimming"},
{"sport", "tennis"},
{"tourism", "alpine_hut"},
{"tourism", "apartment"},
{"tourism", "artwork"},
{"tourism", "attraction"},
{"tourism", "camp_site"},
{"tourism", "caravan_site"},
{"tourism", "chalet"},
{"tourism", "gallery"},
{"tourism", "guest_house"},
{"tourism", "hostel"},
{"tourism", "hotel"},
{"tourism", "information"},
{"tourism", "motel"},
{"tourism", "museum"},
{"tourism", "picnic_site"},
{"tourism", "resort"},
{"tourism", "theme_park"},
{"tourism", "viewpoint"},
{"tourism", "wilderness_hut"},
{"tourism", "zoo"},
{"waterway", "canal"},
{"waterway", "dam"},
{"waterway", "ditch"},
{"waterway", "dock"},
{"waterway", "drain"},
{"waterway", "lock"},
{"waterway", "lock_gate"},
{"waterway", "river"},
{"waterway", "riverbank"},
{"waterway", "stream"},
{"waterway", "waterfall"},
{"waterway", "weir"},
{"wheelchair", "limited"},
{"wheelchair", "no"},
{"wheelchair", "yes"},
};
for (auto const & type : simpleTypes)
{
auto const params = GetFeatureBuilderParams({type});
TEST_EQUAL(params.m_types.size(), 1, (type, params));
TEST(params.IsTypeExist(classif().GetTypeByPath({type.m_key, type.m_value})), (type, params));
}
}