Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
BrodyHughes committed Oct 25, 2024
1 parent 70ffc77 commit df9b017
Showing 1 changed file with 18 additions and 6 deletions.
24 changes: 18 additions & 6 deletions e2e/serial/swap/1_swapFlow1.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -755,16 +755,28 @@ it('should be able to see no route explainer', async () => {
id: 'swap-confirmation-button-error',
driver,
});
expect(confirmButtonText).toEqual('No route found');

// TODO: Fix no quote instead of no route for some reason ??
expect(['No route found', 'No quote available']).toContain(confirmButtonText);
await findElementByTestIdAndClick({
id: 'swap-confirmation-button-error',
driver,
});
const noRouteExplainer = await findElementByTestId({
id: 'explainer-sheet-swap-no-route',
driver,
});
expect(noRouteExplainer).toBeTruthy();

try {
const noRouteExplainer = await findElementByTestId({
id: 'explainer-sheet-swap-no-route',
driver,
});
expect(noRouteExplainer).toBeTruthy();
} catch {
const noQuoteExplainer = await findElementByTestId({
id: 'explainer-sheet-swap-no-quote',
driver,
});
expect(noQuoteExplainer).toBeTruthy();
}

await findElementByTestIdAndClick({
id: 'explainer-action-button',
driver,
Expand Down

0 comments on commit df9b017

Please sign in to comment.