【问题标题】:CTS execution using junit categories使用 junit 类别执行 CTS
【发布时间】:2020-02-25 22:44:12
【问题描述】:

CTS 执行:

我们如何通过命令行使用注解和类别来触发Junit的测试套件?

【问题讨论】:

  • 欢迎堆栈溢出!不幸的是,这个问题不够详细,无法为您提供任何有意义的帮助。请编辑您的问题以包含该问题的最小可重现示例,包括示例输入、首选输出和您迄今为止尝试过的代码。

标签: android junit4 cts


【解决方案1】:

您可以使用 android 检测命令运行 C​​TS 单个测试方法或整个类。

例如:本例中提到了运行特定方法的 CTS 测试类,您可以从以下命令中删除该测试方法以运行该类中的所有测试方法。

adb shell am instrument -w -e class android.animation.AnimatorSetEventsTest#testCancel \com.android.frameworks.coretests android.support.test.runner.AndroidJUnitRunner

有关通过仪器运行测试的更多详细信息,请点击此链接 - https://source.android.com/compatibility/tests/development/instrumentation

【讨论】:

    猜你喜欢
    • 2023-03-23
    • 2018-11-10
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2017-10-07
    相关资源
    最近更新 更多