From 85c16611a5da6eeee689f9290384c423e7645d76 Mon Sep 17 00:00:00 2001 From: Abdurrahman SASTIM Date: Fri, 3 Jan 2025 17:22:06 +0100 Subject: [PATCH] test: fix userdata --- apps/ledger-live-mobile/e2e/page/index.ts | 4 ++-- .../e2e/specs/speculos/verifyAddress/receiveFlowETH.spec.ts | 3 +-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/apps/ledger-live-mobile/e2e/page/index.ts b/apps/ledger-live-mobile/e2e/page/index.ts index 428c72bd49cc..dad053ccff10 100644 --- a/apps/ledger-live-mobile/e2e/page/index.ts +++ b/apps/ledger-live-mobile/e2e/page/index.ts @@ -82,10 +82,10 @@ export class Application { public transfertMenu = new TransfertMenuDrawer(); public walletTabNavigator = new WalletTabNavigatorPage(); - constructor() { + constructor(userdata?: string) { if (!getEnv("MOCK")) { // Create a temporary userdata file for Speculos tests - const originalUserdata = "skip-onboarding"; + const originalUserdata = userdata || "skip-onboarding"; this.userdataSpeculos = `temp-userdata-${Date.now()}`; this.userdataPath = getUserdataPath(this.userdataSpeculos); const originalFilePath = getUserdataPath(originalUserdata); diff --git a/apps/ledger-live-mobile/e2e/specs/speculos/verifyAddress/receiveFlowETH.spec.ts b/apps/ledger-live-mobile/e2e/specs/speculos/verifyAddress/receiveFlowETH.spec.ts index c74e26df13a2..fb5154a2a0ce 100644 --- a/apps/ledger-live-mobile/e2e/specs/speculos/verifyAddress/receiveFlowETH.spec.ts +++ b/apps/ledger-live-mobile/e2e/specs/speculos/verifyAddress/receiveFlowETH.spec.ts @@ -1,12 +1,11 @@ import { Account } from "@ledgerhq/live-common/e2e/enum/Account"; import { Application } from "../../../page"; -const app = new Application(); +const app = new Application("EthAccountXrpAccountReadOnlyFalse"); const account = Account.ETH_1; describe("Receive Flow", () => { beforeAll(async () => { - app.userdataSpeculos = "EthAccountXrpAccountReadOnlyFalse"; await app.init({ speculosApp: account.currency.speculosApp, });