Skip to content

Commit 2b844e9

Browse files
committed
fix: remove flaky CancelDirectoryPicker test
1 parent 5fb24de commit 2b844e9

File tree

1 file changed

+0
-36
lines changed

1 file changed

+0
-36
lines changed

src/browser/components/ProjectCreateModal.stories.tsx

Lines changed: 0 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -393,42 +393,6 @@ export const FullFlowWithDirectoryPicker: Story = {
393393
},
394394
};
395395

396-
export const CancelDirectoryPicker: Story = {
397-
args: {
398-
isOpen: true,
399-
onClose: action("close"),
400-
onSuccess: action("success"),
401-
},
402-
render: () => <ProjectCreateModalWrapper />,
403-
play: async ({ canvasElement }) => {
404-
const canvas = within(canvasElement);
405-
406-
// Wait for modal and click Browse
407-
await waitFor(() => {
408-
expect(canvas.getByRole("dialog")).toBeInTheDocument();
409-
});
410-
411-
await userEvent.click(canvas.getByText("Browse…"));
412-
413-
// Wait for DirectoryPickerModal
414-
await waitFor(() => {
415-
expect(canvas.getByText("Select Project Directory")).toBeInTheDocument();
416-
});
417-
418-
// Click Cancel in the directory picker (the second/last Cancel button visible)
419-
const cancelButtons = canvas.getAllByRole("button", { name: "Cancel" });
420-
await userEvent.click(cancelButtons[cancelButtons.length - 1]);
421-
422-
// DirectoryPickerModal should close but main modal stays open
423-
await waitFor(() => {
424-
expect(canvas.queryByText("Select Project Directory")).not.toBeInTheDocument();
425-
});
426-
427-
// Main modal should still be visible
428-
expect(canvas.getByRole("button", { name: "Add Project" })).toBeInTheDocument();
429-
},
430-
};
431-
432396
export const ValidationError: Story = {
433397
args: {
434398
isOpen: true,

0 commit comments

Comments
 (0)