- 一天笑嘻嘻是一名測試人員,想了解Android的測試方法,因而,就找到了小測試。
- 笑嘻嘻:身爲一名測試人員須要瞭解ADB的哪些內容?
- 小測試:瞭解原理和簡單的命令使用就能夠了。
- 笑嘻嘻:你有毒啊,都瞭解原理了,還簡單實用?
- 小測試:用工具不疑,疑工具不用,知道這個工具怎麼運行的用起來才駕輕就熟啊。另外ADB命令就像Linux的命令同樣,記住經常使用的,瞭解大部分的,遇到問題知道百度什麼就好。
adb daemon(守護進程):運行在Android設備上的adb後臺進程。android
安裝方法大同小異,不少文章都推薦安裝Android sdk,其實adb工具是包含在Android sdk平臺工具軟件包裏的一個,咱們把adb下載了就好。舉個例子:王者榮耀是應用寶的一個應用,若是咱們要玩王者榮耀,須要把全部的應用都下載了麼?固然不須要。
下載連接服務器
得到到上面的安裝包或者安裝好Android SDK以後,找到:platform-tools文件夾(複製路徑)
架構
因爲咱們的adb命令是在cmd環境下使用,全部要添加環境變量ide
把platform-tools和tools(tools在platform-tools下面)的路徑添加進來。工具
- 打開cmd環境,輸入adb,回車,若是有出現下面的,恭喜你,安裝成功!!!
C:\Users\wy.DESKTOP-KENPKKP>adb Android Debug Bridge version 1.0.36 Revision 0e9850346394-android -a - directs adb to listen on all interfaces for a connection -d - directs command to the only connected USB device returns an error if more than one USB device is present. -e - directs command to the only running emulator. returns an error if more than one emulator is running. -s <specific device> - directs command to the device or emulator with the given serial number or qualifier. Overrides ANDROID_SERIAL environment variable. -p <product name or path> - simple product name like 'sooner', or a relative/absolute path to a product out directory like 'out/target/product/sooner'. If -p is not specified, the ANDROID_PRODUCT_OUT environment variable is used, which must be an absolute path. -H - Name of adb server host (default: localhost) -P - Port of adb server (default: 5037) devices [-l] - list all connected devices ('-l' will also list device qualifiers) connect <host>[:<port>] - connect to a device via TCP/IP Port 5555 is used by default if no port number is specified. disconnect [<host>[:<port>]] - disconnect from a TCP/IP device. Port 5555 is used by default if no port number is specified. Using this command with no additional arguments will disconnect from all connected TCP/IP devices.
今天就先到這裏,若是有問題的請留言指正。
QQ:1545626293
測試