Test previously failing case for SHUTTLE_WILL_LEAVE_STOP

This commit is contained in:
2025-11-21 11:10:10 -08:00
parent 413443a162
commit 6c199e38a8

View File

@@ -805,6 +805,10 @@ describe.each(repositoryImplementations)('$name', (holder) => {
const arrivalTime = new Date("2024-01-15T10:30:00Z");
await repository.addOrUpdateShuttle(shuttle, arrivalTime.getTime());
// Test that it actually emits the event correctly and not right after the shuttle arrives
await repository.addOrUpdateShuttle(shuttle, arrivalTime.getTime());
expect(listener).not.toHaveBeenCalled();
shuttle.coordinates = { latitude: 12.5, longitude: 22.5 }; // Not at any stop
// Simulate leaving stop 1