Skip to content

Commit

Permalink
test: first receive
Browse files Browse the repository at this point in the history
  • Loading branch information
abdurrahman-ledger committed Nov 22, 2024
1 parent 30da4cd commit 2f98e98
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 0 deletions.
38 changes: 38 additions & 0 deletions apps/ledger-live-mobile/e2e/specs/speculos/receive/receive.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
import { CLI } from "../../../utils/cliUtils";
import { Application } from "../../../page";
import { Account } from "@ledgerhq/live-common/e2e/enum/Account";

export async function runReceiveTest(account: Account, tmsLink: string) {
const app = new Application();

describe(`Receive - ${account.currency.name}`, () => {
beforeAll(async () => {
await app.init({
speculosApp: account.currency.speculosApp,
cliCommands: [
CLI.liveData({
currency: account.currency.currencyId,
index: account.index,
appjson: app.userdataPath,
add: true,
}),
],
});
await app.portfolio.waitForPortfolioPageToLoad();
});

$TmsLink(tmsLink);
it(`receive on ${account.currency.name} (through scanning)`, async () => {
await app.receive.openViaDeeplink();
await app.common.performSearch(account.currency.name);
await app.receive.selectCurrency(account.currency.name);
await app.receive.selectAccount(account.accountName);
await app.receive.doNotVerifyAddress();
await app.receive.expectReceivePageIsDisplayed(account.currency.ticker, account.accountName);
});

afterAll(async () => {
await app?.common.removeSpeculos();
});
});
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
import { runReceiveTest } from "./receive";
import { Account } from "@ledgerhq/live-common/e2e/enum/Account";

runReceiveTest(Account.BTC_NATIVE_SEGWIT_1, "B2CQA-2559, B2CQA-2687");

0 comments on commit 2f98e98

Please sign in to comment.