mirror of
https://github.com/coder/coder.git
synced 2026-06-02 20:48:20 +00:00
test(site/src/pages/AgentsPage): restore planning indicator baseline
This commit is contained in:
@@ -829,29 +829,16 @@ export const PlanningIndicator: Story = {
|
||||
planModeEnabled: true,
|
||||
onPlanModeToggle: fn(),
|
||||
},
|
||||
decorators: [
|
||||
(Story) => (
|
||||
<div style={{ width: 480 }}>
|
||||
<Story />
|
||||
</div>
|
||||
),
|
||||
],
|
||||
parameters: {
|
||||
viewport: { defaultViewport: "desktopZoom200" },
|
||||
chromatic: { viewports: [720] },
|
||||
},
|
||||
play: async ({ canvasElement }) => {
|
||||
const canvas = within(canvasElement);
|
||||
const planningBadge = await canvas.findByTestId("planning-badge");
|
||||
|
||||
await waitFor(() => {
|
||||
expect(planningBadge).toBeVisible();
|
||||
expect(canvas.getByText("Planning")).toBeVisible();
|
||||
expect(
|
||||
within(planningBadge).getByRole("button", {
|
||||
name: "Disable plan mode",
|
||||
}),
|
||||
canvas.getByRole("button", { name: "Disable plan mode" }),
|
||||
).toBeVisible();
|
||||
});
|
||||
},
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user