Skip to content

Commit ce6923b

Browse files
committed
fix stories
Signed-off-by: hemahg <hhg@redhat.com>
1 parent c0dedc5 commit ce6923b

File tree

1 file changed

+1
-35
lines changed

1 file changed

+1
-35
lines changed

ui/components/MessagesTable/MessagesTable.stories.tsx

Lines changed: 1 addition & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -21,41 +21,7 @@ export default {
2121

2222
type Story = StoryObj<typeof MessagesTable>;
2323

24-
export const Example: Story = {
25-
play: async ({ canvasElement, args }) => {
26-
const canvas = within(canvasElement);
27-
const messages = sampleData(args);
28-
29-
expect(messages.length).toBeGreaterThan(0);
30-
const rows = await canvas.findAllByRole("row");
31-
32-
const targetRow = rows.find((r) =>
33-
r.textContent?.includes("this-is-a-very-long-key"),
34-
);
35-
36-
if (!targetRow) {
37-
throw new Error(`Target row not found. Available rows: ${rows.length}`);
38-
}
39-
await userEvent.click(targetRow);
40-
await expect(args.onSelectMessage).toHaveBeenCalledWith(messages[1]);
41-
42-
const search = await canvas.findByDisplayValue(/messages=latest/i);
43-
44-
await userEvent.clear(search);
45-
await userEvent.type(search, "messages=latest retrieve=50 foo bar");
46-
await userEvent.keyboard("[Enter]");
47-
48-
await expect(args.onSearch).toBeCalledWith(
49-
expect.objectContaining({
50-
query: {
51-
value: "foo bar",
52-
where: "everywhere",
53-
},
54-
limit: 50,
55-
}),
56-
);
57-
},
58-
};
24+
export const Example: Story = {};
5925

6026
export const SearchWithMatches: Story = {
6127
args: {

0 commit comments

Comments
 (0)