From b48e34474932dc994f5dcb2931762b7ef8866ca0 Mon Sep 17 00:00:00 2001 From: Maurice Date: Mon, 9 Nov 2026 13:17:22 +0100 Subject: [PATCH] test(planner): the booking dialog's map button reads Map --- .../components/Planner/bookings/BookingDetailHost.test.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/client/src/components/Planner/bookings/BookingDetailHost.test.tsx b/client/src/components/Planner/bookings/BookingDetailHost.test.tsx index 9f47ad8a5..0bbcc30a4 100644 --- a/client/src/components/Planner/bookings/BookingDetailHost.test.tsx +++ b/client/src/components/Planner/bookings/BookingDetailHost.test.tsx @@ -160,7 +160,7 @@ describe('BookingDetailHost', () => { await waitFor(() => expect(toasts).toContainEqual({ message: 'Failed to update', type: 'error' })); }); - it('FE-PLANNER-BOOKINGHOST-011: On map is offered only for a booking the map can show, and closes first', async () => { + it('FE-PLANNER-BOOKINGHOST-011: Map is offered only for a booking the map can show, and closes first', async () => { const onShowOnMap = vi.fn(() => { calls.push('map'); }); const routed = buildReservation({ title: 'Shinkansen', type: 'train', @@ -171,7 +171,7 @@ describe('BookingDetailHost', () => { }); const { unmount } = renderHost(routed, { onShowOnMap, isOnMap: () => true }); - const onMap = screen.getByRole('button', { name: 'On map' }); + const onMap = screen.getByRole('button', { name: 'Map' }); expect(onMap).toHaveAttribute('aria-pressed', 'true'); await userEvent.click(onMap); expect(onShowOnMap).toHaveBeenCalledWith(routed); @@ -179,7 +179,7 @@ describe('BookingDetailHost', () => { unmount(); renderHost(buildReservation({ title: 'Nowhere', place_id: null }), { onShowOnMap }); - expect(screen.queryByRole('button', { name: 'On map' })).toBeNull(); + expect(screen.queryByRole('button', { name: 'Map' })).toBeNull(); }); it('FE-PLANNER-BOOKINGHOST-012: Change route is offered for a transit journey only', async () => {