有没有执行(使用摇篮)单Robolectric 2.3测试的方法吗? [英] Is there a way to execute a single Robolectric 2.3 test (using Gradle)?

查看:120
本文介绍了有没有执行(使用摇篮)单Robolectric 2.3测试的方法吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用Robolectric 2.3和执行我的单元测试

I'm using Robolectric 2.3 and execute my unit tests with

./gradlew testDebug

有执行单一测试或单个测试类的方法吗?

Is there a way to execute a single test or a single test class?

推荐答案

我运行他们的Andr​​oid Studio并从那里你可以执行一个测试,一个测试的情况下,包中的所有测试:
<一href=\"http://stackoverflow.com/questions/19891564/how-to-run-unit-tests-with-android-studio/24140796#24140796\">How到了Android工作室运行单元测试

I'm running them in Android Studio and from there you can execute one test, one test case, all tests in the package: How to run unit tests with Android Studio

有关命令行,你可以把这个插件一起来看看:
https://github.com/JCAndKSolutions/android-unit-test

About command line you can take a look on this plugin: https://github.com/JCAndKSolutions/android-unit-test

这篇关于有没有执行(使用摇篮)单Robolectric 2.3测试的方法吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆