android CTS

1. 下载cts工具

https://source.android.com/compatibility/cts/downloads

或者make cts,

out/host/linux-x86/cts, cts-verifier

 

2. Setting up

https://source.android.com/compatibility/cts/setup

Wi-Fi and IPv6

CTS tests require a Wi-Fi network that supports IPv6, can treat the DUT as an isolated client, and has an internet connection.

ADB and AAPT

export PATH=$PATH:$HOME/android-sdk-linux/build-tools/version

  put in .bashrc, run "source .bashrc"

  or put in /etc/profile run "source /etc/profile"

 

Java Development Kit

Install the proper version of the Java Development Kit (JDK). For Android 7.0 and higher:

CTS files

Download and open the latest version of the CTS media files.

 

User builds

First API level for Android 9 and higher

For devices launched with Android 9 or higher, set the ro.product.first_api_level property to a valid value found on Codenames, Tags, and Build Numbers.

Android device configuration

  1. Factory data reset the device: Settings > Backup & reset > Factory data reset
  2. Set your device's language to English (United States): Settings > Language & input > Language
  3. Turn on the location setting if there's a GPS or Wi-Fi/cellular network feature on the device: Settings > Location > On
  4. Connect to a Wi-Fi network that supports IPv6, can treat the DUT as an isolated client (see Physical Environment above), and has an internet connection: Settings > Wi-Fi
  5. Make sure that no lock pattern or password is set on the device: Settings > Security > Screen lock > None
  6. Enable USB debugging on your device: Settings > Developer options > USB debugging

    Note: On Android 4.2 and higher, Developer options is hidden by default. To make it available, go to Settings > About phone and tap Build number seven times. Return to the previous screen to find Developer options. See Enabling On-device Developer Options for additional details.

  7. Set the time to 12-hour format: Settings > Date & time > Use 24-hour format > Off
  8. Set the device to stay awake: Settings > Developer options > Stay Awake > On
  9. In Android 5.x and 4.4.x only, set the device to allow mock locations: Settings > Developer options > Allow mock locations > On
  10. In Android 4.2 and higher, turn off USB app verification: Settings > Developer options > Verify apps over USB > Off
  11. Launch the browser and dismiss any startup/setup screen.

Running CTS tests

https://source.android.com/compatibility/cts/run

./android-cts/tools/cts-tradefed

.verison

.help

.help run

.run cts --module/-m <module name>

.run cts --module/-m <module name> --test/-t <test name>

test name can package/class/class#function or native binary name

 

logs and results are under android-cts

 

https://ressrc.com/2018/03/27/android-gms%E8%AE%A4%E8%AF%81-cts-gts-ctsv/

3)CTS Verifier测试相关

1、测试准备

        1、根目录下安装CtsVerifier.apk、NotificationBot.apk

            adb install -r CtsVerifier.apk         

            adb install -r  NotificationBot.apk

        2、设置里security-Device administrators开启cts verifier

        3、打开手机上的CTS Verifier应用,根据提示测试每一项

2、保存查看结果

        所有测试完成后,点击CTS Verifier测试工具右上角的保存按钮,会提示结果保存位置,连接电脑,将结果拷贝到电脑即可查看。

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值