diff --git a/e2e/models/onboarding/onboardingSteps.js b/e2e/models/onboarding/onboardingSteps.js index 7ba8c6bf20..9f8701426c 100644 --- a/e2e/models/onboarding/onboardingSteps.js +++ b/e2e/models/onboarding/onboardingSteps.js @@ -3,46 +3,55 @@ import * as testHelpers from "../../helpers"; export default class OnboardingSteps { static async waitForPageToBeVisible() { - await testHelpers.waitForElement("Proceed"); + await testHelpers.waitForElement("Onboarding - Start"); } static async getStarted() { - await testHelpers.tap("Proceed"); + await testHelpers.tap("Onboarding - Start"); } - static async acceptTerms() { - await testHelpers.tap("TermsAcceptSwitch"); - await testHelpers.tap("Proceed"); + static async chooseToSetupLedger() { + await testHelpers.tap("Onboarding PostWelcome - Selection|SetupLedger"); } + // static async acceptTerms() { + // await testHelpers.tap("TermsAcceptSwitch"); + // await testHelpers.tap("Proceed"); + // } + static async selectDevice(device) { await testHelpers.tap(`Onboarding Device - Selection|${device}`); } - static async connectYourNano(device) { - await testHelpers.scrollToElementById( - `Onboarding - Connect|${device}`, - "UseCaseSelectScrollView", - 200, - "down", - NaN, - 0.5, - ); - - await testHelpers.tap(`Onboarding - Connect|${device}`); + static async connectYourNano() { + // scroll probably not needed now + // await testHelpers.scrollToElementById( + // `Onboarding - Connect|${device}`, + // "UseCaseSelectScrollView", + // 200, + // "down", + // NaN, + // 0.5, + // ); + + await testHelpers.tap(`Onboarding - Connect`); } - static async acceptSeedWarning() { - await testHelpers.delay(1000); + static async checkTheContentsOfThisBox() { + // await testHelpers.delay(1000); await testHelpers.tap("Onboarding - Seed warning"); } - static async startPairing() { - await testHelpers.tap("OnboardingStemPairNewContinue"); + static async letsPairMyNano() { + await testHelpers.tap("Onboarding - Pair New Nano"); } - static async addNewNano() { - await testHelpers.tap("Proceed"); + // static async addNewNano() { + // await testHelpers.tap("Proceed"); + // } + + static async pairWithBluetooth() { + await testHelpers.tap("Onboarding - Pair with Bluetooth"); } static async addDeviceViaBluetooth() { diff --git a/e2e/specs/onboarding.spec.js b/e2e/specs/onboarding.spec.js index 96dd0a24dd..6c5dcdf5f7 100644 --- a/e2e/specs/onboarding.spec.js +++ b/e2e/specs/onboarding.spec.js @@ -15,12 +15,14 @@ describe("Onboarding", () => { console.log("==============> STARTING ONBOARDING TEST"); await OnboardingSteps.waitForPageToBeVisible(); await OnboardingSteps.getStarted(); - await OnboardingSteps.acceptTerms(); + // await OnboardingSteps.acceptTerms(); + await OnboardingSteps.chooseToSetupLedger(); await OnboardingSteps.selectDevice("nanoX"); - await OnboardingSteps.connectYourNano("nanoX"); - await OnboardingSteps.acceptSeedWarning(); + await OnboardingSteps.connectYourNano(); + await OnboardingSteps.checkTheContentsOfThisBox(); await OnboardingSteps.startPairing(); - await OnboardingSteps.addNewNano(); + // await OnboardingSteps.addNewNano(); + await OnboardingSteps.pairWithBluetooth(); await OnboardingSteps.addDeviceViaBluetooth(); await OnboardingSteps.openLedgerLive(); diff --git a/src/components/SelectDevice/BluetoothEmpty.tsx b/src/components/SelectDevice/BluetoothEmpty.tsx index 428c6a1b56..3a20d067a3 100644 --- a/src/components/SelectDevice/BluetoothEmpty.tsx +++ b/src/components/SelectDevice/BluetoothEmpty.tsx @@ -34,7 +34,13 @@ function BluetoothEmpty({ onPairNewDevice, hideAnimation }: Props) { - diff --git a/src/components/SelectDevice/DeviceItem.tsx b/src/components/SelectDevice/DeviceItem.tsx index 30b1f7b546..0ccbb91d58 100644 --- a/src/components/SelectDevice/DeviceItem.tsx +++ b/src/components/SelectDevice/DeviceItem.tsx @@ -61,6 +61,7 @@ function DeviceItem({ Icon={CustomIcon || NanoFoldedMedium} renderRight={onMore ? renderOnMore : undefined} disabled={disabled} + testID={`DeviceItemEnter ${deviceMeta.deviceName ?? ""}`} > {deviceMeta.deviceName} {description && ( diff --git a/src/screens/Onboarding/steps/setupDevice/scenes/PairNew.tsx b/src/screens/Onboarding/steps/setupDevice/scenes/PairNew.tsx index 951ccf1e73..01979b49f0 100644 --- a/src/screens/Onboarding/steps/setupDevice/scenes/PairNew.tsx +++ b/src/screens/Onboarding/steps/setupDevice/scenes/PairNew.tsx @@ -30,7 +30,12 @@ const Next = ({ const { t } = useTranslation(); return ( - ); diff --git a/yarn.lock b/yarn.lock index 12d09487f1..5257fd4c7a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -4839,6 +4839,16 @@ ajv@^8.0.1: require-from-string "^2.0.2" uri-js "^4.2.2" +ajv@^8.6.3: + version "8.11.0" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-8.11.0.tgz#977e91dd96ca669f54a11e23e378e33b884a565f" + integrity sha512-wGgprdCvMalC0BztXvitD2hC04YffAvtsUn93JbGXYLAtCUO4xd17mCCZQxUOItiBwZvJScWo8NIvQMQ71rdpg== + dependencies: + fast-deep-equal "^3.1.1" + json-schema-traverse "^1.0.0" + require-from-string "^2.0.2" + uri-js "^4.2.2" + algo-msgpack-with-bigint@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/algo-msgpack-with-bigint/-/algo-msgpack-with-bigint-2.1.1.tgz#38bb717220525b3ff42232eefdcd9efb9ad405d6"