Månedsarkiv: oktober 2016

How to run UiAutomator 2.0 tests from command line

In your projects base folder execute the following runTests.sh file: adb install -r app/build/outputs/apk/app-debug.apk adb install -r app/build/outputs/apk/app-debug-androidTest-unaligned.apk # Grant permissions requested adb shell pm grant com.example.test.uiautomatortest android.permission.READ_EXTERNAL_STORAGE adb shell pm grant com.example.test.uiautomatortest android.permission.WRITE_EXTERNAL_STORAGE # Run Ui tests from test … Læs resten

Udgivet i Ikke kategoriseret | Skriv en kommentar

How to take screenshots with UiAutomator 2.0 in Android Studio

Note, this example is a standalone test project. Using Android Studio create a new project e.g. “com.example.test.uiautomatortest” – Use option “Add no activity” – Delete test project androidTest – Remove resource folders from “res” – Update manifest according to image … Læs resten

Udgivet i Ikke kategoriseret | Skriv en kommentar