1
0
Fork 0

shop=appliance support

This commit is contained in:
Mateusz Konieczny 2025-03-22 08:52:40 +01:00
parent d17ecaa477
commit 3dc274ce1e
2 changed files with 38 additions and 0 deletions

View file

@ -6698,6 +6698,13 @@ def clear_type_conflicts():
def matching_rather_than_type_conflict():
return [
'shop=appliance vs shop=electronics',
# shop=white_goods ? TODO handle, maybe I can convince OSM mappers to treat it as an equivalent?
# https://overpass-turbo.eu/s/20Py
# see https://www.openstreetmap.org/changeset/18627515
# https://www.openstreetmap.org/changeset/10322286
# https://www.openstreetmap.org/changeset/76410664
'furniture_shop vs interior_stuff_shop',
'shop=carpet vs shop=flooring',

View file

@ -667,6 +667,37 @@ class CanonicalValueTests(unittest.TestCase):
self.assertEqual(config.the_same_feature_type({'shop': 'sports'}, {'shop': 'ski'}), True)
self.assertEqual(config.the_same_feature_type({'shop': 'clothes'}, {'shop': 'ski'}), True)
def test_white_goods_shops(self):
self.assertEqual(config.the_same_feature_type({
'@source_uri': 'https://sklepy.mediaexpert.pl/data/getshops',
'@spider': 'media_expert_pl',
'shop': 'electronics',
'addr:full': 'ul. Aleja Armii Krajowej 46, 47-224 Kędzierzyn Koźle',
'addr:street_address': 'ul. Aleja Armii Krajowej 46',
'addr:city': 'Kędzierzyn Koźle',
'addr:postcode': '47-224',
'addr:country': 'PL',
'name': 'Media Expert',
'phone': '+48 77 545 30 10',
'website': 'https://sklepy.mediaexpert.pl/kedzierzynkozle2_armiikrajowej',
'brand': 'Media Expert',
'brand:wikidata': 'Q11776794',
'atp_ref': 'S642',
'opening_hours_in_atp_format': 'Mo-Sa 09:00-20:00; Su 10:00-18:00'
},
{
'addr:city': 'Kędzierzyn-Koźle',
'addr:city:simc': '0965424',
'addr:housenumber': '46',
'addr:postcode': '47-224',
'addr:street': 'Aleja Armii Krajowej',
'building': 'retail',
'building:levels': '1',
'name': 'Media Expert',
'shop': 'appliance',
'source:addr': 'gugik.gov.pl',
'source:building': 'BDOT'
}), True)
def test_match_tile_shops_tagged_in_a_different_way(self):
self.assertEqual(config.the_same_feature_type({'shop': 'trade', 'trade': 'tiles'}, {'shop': 'trade'}), True)