Command line run Android Robotium automation use case or unit test case

Source: Internet
Author: User

Tag: Reg order number func NES pad run add list

Directory of this document
    • 1. run all the test cases

    • 2. run a single test class or a testsuite

    • 3. run A test method inside a test class

    • 4. run a method in two different test classes or classes

Command line run Android robotium Automation use case or unit Test case

1. RunAll the TestCase

Give me a chestnut: run All the use cases under the test project

1 adb shell am instrument -w com.taobao.taobao.test/android.test.InstrumentationTestRunner

2. RunSingle TestClass or a Testsuite

For a chestnut: run test class Com.taobao.taobao.test.TestRegister

1 adb shell am instrument -e class com.taobao.taobao.test.TestRegister -w com.taobao.taobao.test/android.test.InstrumentationTestRunner

3. Run A test method inside a test class

For a chestnut: run the test method in Com.taobao.taobao.test.TestRegister Testregister

ADB shell AM Instrument -e class com.taobao.taobao.test.TestRegister#testRegister-W Com.taobao.taobao.test/android.test.instrumentationtestrunner  

4. Run a method in two different test classes or classes

For a chestnut: run com.taobao.taobao.test.TestLogin

And the methods in the Com.taobao.taobao.test.TestRegister class Testregister

1 adb shell am instrument -e class com.taobao.taobao.test.TestLogin,com.taobao.taobao.test.TestRegister#testRegister  -w com.taobao.taobao.test/android.test.InstrumentationTestRunner

Command line run Android Robotium automation use case or unit test case

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.