Fix chromatic pixel tests
This commit is contained in:
@ -1,7 +1,7 @@
|
||||
import { expect } from '@storybook/jest';
|
||||
import { Meta, StoryObj } from '@storybook/react';
|
||||
import { within } from '@storybook/test';
|
||||
import { graphql, HttpResponse } from 'msw';
|
||||
import { HttpResponse, graphql } from 'msw';
|
||||
|
||||
import {
|
||||
PageDecorator,
|
||||
@ -90,7 +90,11 @@ export const Default: Story = {
|
||||
await canvas.findAllByText(
|
||||
peopleMock[0].name.firstName + ' ' + peopleMock[0].name.lastName,
|
||||
);
|
||||
await canvas.findByText('Add your first Activity');
|
||||
expect(
|
||||
await canvas.findByText('Add your first Activity', undefined, {
|
||||
timeout: 3000,
|
||||
}),
|
||||
).toBeInTheDocument();
|
||||
},
|
||||
};
|
||||
|
||||
@ -106,6 +110,11 @@ export const Loading: Story = {
|
||||
peopleMock[0].name.firstName + ' ' + peopleMock[0].name.lastName,
|
||||
),
|
||||
).toBeNull();
|
||||
expect(canvas.queryByText('Add your first Activity')).toBeNull();
|
||||
|
||||
expect(
|
||||
await canvas.findByText('Add your first Activity', undefined, {
|
||||
timeout: 3000,
|
||||
}),
|
||||
).toBeInTheDocument();
|
||||
},
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user