Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fe e2e handle addr mixed case #480

Merged
merged 2 commits into from
Aug 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion test/rollup-test/rollup-main.deposit.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ describe("Gasp UI deposit tests", () => {

driver = await DriverBuilder.getInstance();
acc_addr = await importMetamaskExtension(driver, true);
acc_addr_short = acc_addr.slice(-4).toLowerCase();
acc_addr_short = acc_addr.slice(-4);

await setupPage(driver);
await connectWallet(driver, "MetaMask", acc_addr_short);
Expand Down
4 changes: 3 additions & 1 deletion test/rollup-test/rollup-main.metamask.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ import {
} from "../../utils/frontend/rollup-utils/Handlers";
import { WalletConnectModal } from "../../utils/frontend/rollup-pages/WalletConnectModal";
import { WalletWrapper } from "../../utils/frontend/rollup-pages/WalletWrapper";
import { sleep } from "../../utils/utils";

jest.spyOn(console, "log").mockImplementation(jest.fn());

Expand All @@ -37,7 +38,7 @@ describe("Gasp UI wallet tests", () => {

driver = await DriverBuilder.getInstance();
acc_addr = await importMetamaskExtension(driver);
acc_addr_short = acc_addr.slice(-4).toLowerCase();
acc_addr_short = acc_addr.slice(-4);

await setupPage(driver);
await connectWallet(driver, "MetaMask", acc_addr_short);
Expand All @@ -58,6 +59,7 @@ describe("Gasp UI wallet tests", () => {
expect(isAccInfoDisplayed).toBeTruthy();

await walletModal.disconnect();
await sleep(1000);
const isWalletConnected = await walletWrapper.isWalletConnected();
expect(isWalletConnected).toBeFalsy();
});
Expand Down
4 changes: 3 additions & 1 deletion test/rollup-test/rollup-main.my-positions.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ import { WalletWrapper } from "../../utils/frontend/rollup-pages/WalletWrapper";
import { TransactionType } from "../../utils/frontend/rollup-pages/NotificationToast";
import { Sidebar } from "../../utils/frontend/rollup-pages/Sidebar";
import { MyPositionsPage } from "../../utils/frontend/rollup-pages/MyPositionsPage";
import { sleep } from "../../utils/utils";

jest.spyOn(console, "log").mockImplementation(jest.fn());

Expand All @@ -46,7 +47,7 @@ describe("Gasp UI swap tests", () => {

driver = await DriverBuilder.getInstance();
acc_addr = await importMetamaskExtension(driver, true);
acc_addr_short = acc_addr.slice(-4).toLowerCase();
acc_addr_short = acc_addr.slice(-4);

await setupPage(driver);
await connectWallet(driver, "MetaMask", acc_addr_short);
Expand All @@ -72,6 +73,7 @@ describe("Gasp UI swap tests", () => {

await myPositionsPage.clickSwitchNetwork();
await acceptNetworkSwitchInNewWindow(driver);
await sleep(500);
await myPositionsPage.clickRemoveLiquidity();
await myPositionsPage.clickConfirmFeeAmount();
await waitForActionNotification(driver, TransactionType.RemoveLiquidity);
Expand Down
2 changes: 1 addition & 1 deletion test/rollup-test/rollup-main.swap.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ describe("Gasp UI swap tests", () => {

driver = await DriverBuilder.getInstance();
acc_addr = await importMetamaskExtension(driver, true);
acc_addr_short = acc_addr.slice(-4).toLowerCase();
acc_addr_short = acc_addr.slice(-4);

await setupPage(driver);
await connectWallet(driver, "MetaMask", acc_addr_short);
Expand Down
2 changes: 1 addition & 1 deletion test/rollup-test/rollup-main.withdraw.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ describe("Gasp UI withdraw tests", () => {

driver = await DriverBuilder.getInstance();
acc_addr = await importMetamaskExtension(driver, true);
acc_addr_short = acc_addr.slice(-4).toLowerCase();
acc_addr_short = acc_addr.slice(-4);

await setupPage(driver);
await connectWallet(driver, "MetaMask", acc_addr_short);
Expand Down
2 changes: 1 addition & 1 deletion test/rollup-test/rollup-prod.deposit.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ describe("Gasp Prod UI deposit tests", () => {

driver = await DriverBuilder.getInstance();
acc_addr = await importMetamaskExtension(driver, true);
acc_addr_short = acc_addr.slice(-4).toLowerCase();
acc_addr_short = acc_addr.slice(-4);

await setupPage(driver);
await connectWallet(driver, "MetaMask", acc_addr_short);
Expand Down
2 changes: 1 addition & 1 deletion test/rollup-test/rollup-prod.withdraw.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ describe("Gasp Prod UI withdraw tests", () => {

driver = await DriverBuilder.getInstance();
acc_addr = await importMetamaskExtension(driver, true);
acc_addr_short = acc_addr.slice(-4).toLowerCase();
acc_addr_short = acc_addr.slice(-4);

await setupPage(driver);
await connectWallet(driver, "MetaMask", acc_addr_short);
Expand Down
Loading