Wednesday 13 August 2014

Android QA Essential ADB Commands

Finally after long time i am glad to post QA Essential ADB commands
------------------------------------------------------------------------------------------------------------
ADB -  Android Device Bridge
------------------------------------------------------------------------------------------------------------

Start ADB 

adb start or adb start-server
adb stop  or adb kell-server
________________________________________________

List of devices [Emulator/ Hardware] attached system

adb devices
________________________________________________

Install APK

adb install "Path of apk"
________________________________________________

List on Packages 

adb pm shell list packages

________________________________________________

Uninstall APK

adb unistall "packege name"

_______________________________________________

Remotely Input

adb shell input text "Text"
________________________________________________

Monkey Runner

adb shell monkey -p your.package.name -v 500
________________________________________________

Log Write

adb -d shell logcat > xyz.txt

adb -d shell logcat > logss.txt

________________________________________________

Replace Package

adb install -r myapp-release.apk

__________________________________________________

Copying Files

adb push foo.txt /sdcard/foo.txt

adb pull  /sdcard/foo.txt  newfoo.txt

__________________________________________________

ScreenRecord Video file

adb shell screenrecord /sdcard/demo.mp4
adb pull  /sdcard/demo.mp4
__________________________________________________

To clear application data

adb shell clear com.packagename

No comments:

Post a Comment

MobileAutomation - Handle Pop-ups, Alerts and Prompts in Automate and App Automate Tests

This article shows you how to handle user permission pop-ups, alerts, and prompts in your automated tests on BrowserStack. Introductio...