Queue via fly-to + Relocate; remove dedicated queue-add input (ISS-053, v0.32.0)
CI / build + unit + e2e (pull_request) Successful in 10m18s
CI / build + unit + e2e (pull_request) Successful in 10m18s
- LeftPane fly-to button enabled for any plane state; posts to /queue when the plane is flying, else /fly - Relocate lists ALL planes (relocatable); relocate-go posts to /queue for a flying selected plane, else /fly - Delete queue-add select + Add-to-queue button and shared queueAddDestIcao state; leg rows/cancel kept - e2e/queue.spec.ts test 1 adds its queued leg via the Relocate section (starter is flying) - e2e/two-planes.spec.ts per-plane-queues test adds the starter's second leg via API POST /queue
This commit is contained in:
@@ -519,13 +519,9 @@ test('per-plane queues are independent; landing auto-chains the next queued leg'
|
||||
await expect(starterLeg0, 'the starter block renders its queued leg').toContainText(a.icao, { timeout: 15_000 });
|
||||
await expect(page.getByTestId(`queue-leg-${secondId}-0`), 'the second block renders its queued leg').toContainText(b.icao);
|
||||
|
||||
// …and ADD a second leg to the STARTER via its scoped controls only.
|
||||
const starterDest = page.getByTestId(`queue-add-dest-${STARTER}`);
|
||||
await expect(starterDest.locator(`option[value="${b.icao}"]`)).toHaveCount(1, { timeout: 15_000 }); // airports fetched
|
||||
await starterDest.selectOption(b.icao);
|
||||
const starterAdd = page.getByTestId(`queue-add-${STARTER}`);
|
||||
await expect(starterAdd).toBeEnabled();
|
||||
await starterAdd.click();
|
||||
// …and ADD a second leg to the STARTER via the API — the dedicated queue-add UI was removed in
|
||||
// ISS-053 (fly-to / Relocate cover it), and the starter is grounded here so fly-to would start, not queue.
|
||||
expect((await page.request.post(`/api/planes/${STARTER}/queue`, { data: { destIcao: b.icao } })).status()).toBe(200);
|
||||
await expect(page.getByTestId(`queue-leg-${STARTER}-1`), 'the second leg is queued on the STARTER').toContainText(b.icao, { timeout: 15_000 });
|
||||
|
||||
// CANCEL the only leg on the SECOND plane — its queue empties, the starter's stays intact.
|
||||
|
||||
Reference in New Issue
Block a user