Skip to content

Commit 55eeeca

Browse files
committed
Run in parallel
1 parent d2280bd commit 55eeeca

7 files changed

Lines changed: 307 additions & 245 deletions
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
import { describe, it } from 'vitest';
2+
3+
import {
4+
defaultTokenCases,
5+
expectTokenButtonSymbol,
6+
expectTokenPanelSymbol,
7+
nonConnectedDestinationAddress,
8+
renderTransferPanel,
9+
setupTransferPanelLifiIntegrationSuite,
10+
} from './TransferPanel.integration.helpers';
11+
12+
describe.sequential('TransferPanel LiFi Integration - Default Token', () => {
13+
setupTransferPanelLifiIntegrationSuite();
14+
15+
it.each(defaultTokenCases)(
16+
'renders source $expectedSourceSymbol and destination $expectedDestinationSymbol for default token transfer: $sourceChain -> $destinationChain',
17+
async ({
18+
sourceChain,
19+
destinationChain,
20+
expectedSourceSymbol,
21+
expectedDestinationSymbol,
22+
expectedSourcePanelSymbols,
23+
expectedDestinationPanelSymbols,
24+
}) => {
25+
renderTransferPanel({
26+
sourceChain,
27+
destinationChain,
28+
destinationAddress: nonConnectedDestinationAddress,
29+
});
30+
31+
await expectTokenButtonSymbol({
32+
isDestination: false,
33+
symbol: expectedSourceSymbol,
34+
});
35+
await expectTokenButtonSymbol({
36+
isDestination: true,
37+
symbol: expectedDestinationSymbol,
38+
});
39+
40+
if (expectedSourcePanelSymbols) {
41+
await expectTokenPanelSymbol({
42+
isDestination: false,
43+
symbolsToContain: expectedSourcePanelSymbols,
44+
});
45+
}
46+
if (expectedDestinationPanelSymbols) {
47+
await expectTokenPanelSymbol({
48+
isDestination: true,
49+
symbolsToContain: expectedDestinationPanelSymbols,
50+
});
51+
}
52+
},
53+
);
54+
});
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
import { constants } from 'ethers';
2+
import { describe, it } from 'vitest';
3+
4+
import {
5+
ethWethCases,
6+
expectTokenButtonSymbol,
7+
expectTokenPanelSymbol,
8+
nonConnectedDestinationAddress,
9+
renderTransferPanel,
10+
setupTransferPanelLifiIntegrationSuite,
11+
} from './TransferPanel.integration.helpers';
12+
13+
describe.sequential('TransferPanel LiFi Integration - ETH/WETH Override', () => {
14+
setupTransferPanelLifiIntegrationSuite();
15+
16+
it.each(ethWethCases)(
17+
'renders source $expectedSourceSymbol and destination $expectedDestinationSymbol for ETH/WETH override: $sourceChain -> $destinationChain',
18+
async ({
19+
sourceChain,
20+
destinationChain,
21+
expectedSourceSymbol,
22+
expectedDestinationSymbol,
23+
expectedSourcePanelSymbols,
24+
expectedDestinationPanelSymbols,
25+
}) => {
26+
renderTransferPanel({
27+
sourceChain,
28+
destinationChain,
29+
destinationToken: constants.AddressZero,
30+
destinationAddress: nonConnectedDestinationAddress,
31+
});
32+
33+
await expectTokenButtonSymbol({
34+
isDestination: false,
35+
symbol: expectedSourceSymbol,
36+
});
37+
await expectTokenButtonSymbol({
38+
isDestination: true,
39+
symbol: expectedDestinationSymbol,
40+
});
41+
42+
if (expectedSourcePanelSymbols) {
43+
await expectTokenPanelSymbol({
44+
isDestination: false,
45+
symbolsToContain: expectedSourcePanelSymbols,
46+
});
47+
}
48+
if (expectedDestinationPanelSymbols) {
49+
await expectTokenPanelSymbol({
50+
isDestination: true,
51+
symbolsToContain: expectedDestinationPanelSymbols,
52+
});
53+
}
54+
},
55+
);
56+
});

0 commit comments

Comments
 (0)