Skip to content

LLM:End to end testing

elbywan edited this page Oct 25, 2022 · 8 revisions

This unfinished guide is about a feature in development, stuff will change

End-to-end testing

Config

Configuration is located inside detox.config.js.

Android

You must make sure that the architecture of the executable that will be chosen for the test corresponds to that of the emulator.

This variable will determine which executable will be used.

const androidArch = "XXX";

It must match the result of this command, retrieving the architecture of your

adb shell getprop ro.product.cpu.abi

Commands

First, launch a dev (Metro) instance of LLM in another terminal.

pnpm dev:llm

Then build the app executables that will be used for testing.

pnpm mobile detox build-framework-cache

Then launch a test ! Configurations are defined inside detox.config.js under "configurations" variable.

pnpm mobile e2e:test -c {configuration name} {path to test spec}
ex:
pnpm mobile e2e:test -c android.emu.debug apps/ledger-live-mobile/e2e/specs/onboarding.spec.ts

Notes

Issues

On my setup, Pixel 2 API 29 architecture x86 with Ubuntu 20.04, I couldn't pass any test steps that try to prompt the device's bluetooth, like tests involving SelectDevice component. I needed to comment calls to NativeModules.BluetoothHelperModule.prompt() to make them work.

Clone this wiki locally