android 4.0 cts
16lz
2021-01-23
首先shell脚本变了,4.0里面叫cts-tradefed
$ ./cts-tradefed --helpCTS-tradefed host version 4.0.3_r3CTS-tradefed is the test harness for running the Android Compatibility Suite, built on top of the tradefed framework.Available commands and optionsHost: help: show this message help all: show the complete tradefed help exit: gracefully exit the cts console, waiting till all invocations are completeRun: run cts --plan test_plan_name: run a test plan run cts --package/-p : run a CTS test package run cts --class/-c [--method/-m] : run a specific test class and/ormethod run cts --continue-session session_ID: run all not executed tests from a previous CTS session run cts [options] --serial/s device_ID: run CTS on specified device run cts [options] --shards number_of_shards: shard a CTS run into given number of independent chunks, to run on multiple devices inparallel run cts --help/--help-all: get more help on running CTSList: l/list d/devices: list connected devices and their state l/list packages: list CTS test packages l/list p/plans: list CTS test plans l/list i/invocations: list invocations aka CTS test runs currentlyin progress l/list c/commands: list commands: aka CTS test run commands currently in the queue waiting to be allocated devices l/list r/results: list CTS results currently present in the repositoryAdd: add derivedplan --plan plane_name --session/-s session_id -r [pass/fail/notExecuted/timeout]: derive a plan from the given sessionDump: d/dump l/logs: dump the tradefed logs for all running invocations
列出所有的package:
$ ./cts-tradefed list packages
Android CTS 4.0.3_r3Using commandline arguments as starting command: [list, packages]09-06 14:05:32 I/DeviceManager: Detected new device 014971B509017018android.accelerationandroid.accessibilityserviceandroid.accountsandroid.adminandroid.animationandroid.apidemos.ctsandroid.appandroid.bluetoothandroid.contentandroid.core.tests.libcore.package.comandroid.core.tests.libcore.package.dalvikandroid.core.tests.libcore.package.libcoreandroid.core.tests.libcore.package.organdroid.core.tests.libcore.package.sunandroid.core.tests.libcore.package.testsandroid.core.vm-testsandroid.core.vm-tests-tfandroid.databaseandroid.dpiandroid.dpi2android.drmandroid.exampleandroid.gestureandroid.graphicsandroid.graphics2android.hardwareandroid.holoandroid.jniandroid.locationandroid.mediaandroid.mediastressandroid.nativemediaandroid.ndefandroid.netandroid.openglperfandroid.osandroid.permissionandroid.permission2android.preferenceandroid.preference2android.providerandroid.renderscriptandroid.saxandroid.securityandroid.speechandroid.telephonyandroid.tests.appsecurityandroid.tests.sigtestandroid.textandroid.textureviewandroid.utilandroid.viewandroid.webkitandroid.widget
以media为例,测试单一的package
$ ./cts-tradefed
Android CTS 4.0.3_r3cts-tf > 09-06 14:06:18 I/DeviceManager: Detected new device 014971B509017018cts-tf > run cts --package android.media--09-06 14:07:09 I/014971B509017018: Collecting device info09-06 14:07:11 I/014971B509017018: -----------------------------------------09-06 14:07:11 I/014971B509017018: Test package android.media started09-06 14:07:11 I/014971B509017018: -----------------------------------------
测试单独的case:
cts-tf > run cts -c android.mediastress.cts.H264R480pAacShortPlayerTest -m testPlay00
更多相关文章
- Android单击屏幕获得坐标,屏幕多点触摸测试器
- Android下的junit 单元测试
- 客户端性能测试
- Gradle for Android 脚本编写总结
- [camera drv]工厂模式下测试camera fail
- 清单文件,测试,打电话和发短信应用
- Android命令行测试BT,WIFI,Sensor工作状态