Delay loading support chat (#10234)
There are a lot of requests being done in parallel when you load the page, and the support chat is responsible for some of them. I don't think it's critical to have it upon loading so delaying it by 2 seconds
This commit is contained in:
@ -53,6 +53,9 @@ export const Default: Story = {
|
||||
expect(await canvas.findByText('Support')).toBeInTheDocument();
|
||||
await userEvent.click(canvas.getByText('Support'));
|
||||
|
||||
// Add delay to account for the timeout in useSupportChat
|
||||
await new Promise((resolve) => setTimeout(resolve, 600));
|
||||
|
||||
expect(await canvas.findByText('Documentation')).toBeInTheDocument();
|
||||
expect(await canvas.findByText('Talk to us')).toBeInTheDocument();
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user