all is well
This commit is contained in:
parent
eac1bd0d13
commit
2f149503bb
53 changed files with 1543 additions and 354 deletions
|
|
@ -71,7 +71,7 @@ describe('map utilities', () => {
|
|||
expect(enumIndexToColor(ENUM_PALETTE.length, ENUM_PALETTE)).toEqual(ENUM_PALETTE[0]);
|
||||
});
|
||||
|
||||
it('resolves POI category logos and rejects unknown icon categories', () => {
|
||||
it('resolves POI category logos and generates a fallback for unknown chains', () => {
|
||||
expect(getPoiIconUrl('Waitrose', '🛒')).toBe('/assets/poi-icons/logos/waitrose.svg');
|
||||
expect(getPoiIconUrl('Iceland', '🛒', 'The Food Warehouse')).toBe(
|
||||
'/assets/poi-icons/logos/the_food_warehouse.png'
|
||||
|
|
@ -83,8 +83,8 @@ describe('map utilities', () => {
|
|||
expect(getPoiIconUrl('M&S', '🛒', undefined, 'M&S Simply Food')).toBe(
|
||||
'/assets/poi-icons/visuals/mns.svg'
|
||||
);
|
||||
expect(() => getPoiIconUrl('Unknown category', '🛒')).toThrow(
|
||||
"Missing POI icon for category 'Unknown category'"
|
||||
expect(getPoiIconUrl('Tian Tian', '🛒')).toMatch(
|
||||
/^data:image\/svg\+xml;charset=utf-8,/
|
||||
);
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue