unit test IDE execution improvements (#463)

* update README about Run Configuration setting
* update task that needs to depend on assembleFullDebug
** this was needed to run individual local tests
This commit is contained in:
Tamás Varga 2017-10-01 13:34:45 +02:00 committed by Synced Synapse
parent d447789dc6
commit 8fb24ee806
2 changed files with 5 additions and 4 deletions

View File

@ -169,7 +169,7 @@ afterEvaluate {
* so this dependency fixes the issue.
*/
tasks.whenTaskAdded { task ->
if (task.name.contains("testFullDebugUnitTest")) {
if (task.name.contains("compileFullDebugUnitTestSources")) {
task.dependsOn assembleFullDebug
}
}

View File

@ -6,9 +6,10 @@ You can run the tests as follows:
### Android Studio
1. Select build variant "fullDebug"
2. Set the [Project view](https://developer.android.com/studio/projects/index.html) to Android
3. Right-click on the directory "test" and select "Run tests"
1. Make sure in the Run/Debug Configurations - Android JUnit - Defaults for Working directory: `$MODULE_DIR$` is set.
2. Select build variant "fullDebug"
3. Set the [Project view](https://developer.android.com/studio/projects/index.html) to Android
4. Right-click on the directory "test" and select "Run tests"
### Commandline