Permalink
Browse files

add MVP example

  • Loading branch information...
1 parent 2be26af commit d2b58d079f6f086ad46e5d35bfb880de8b62e289 @Zhuinden committed Jan 2, 2017
Showing with 9,007 additions and 1 deletion.
  1. +1 −0 build.gradle
  2. +1 −0 flowless-mvp-example/.gitignore
  3. +195 −0 flowless-mvp-example/build.gradle
  4. +255 −0 flowless-mvp-example/proguard-rules.pro
  5. +16 −0 flowless-mvp-example/src/androidTest/java/com/zhuinden/examplegithubclient/InstrumentationSuite.java
  6. +91 −0 ...idTest/java/com/zhuinden/examplegithubclient/presentation/activity/main/MainInstrumentedTest.java
  7. +56 −0 ...le/src/androidTest/java/com/zhuinden/examplegithubclient/presentation/activity/main/MainPage.java
  8. +83 −0 ...oidTest/java/com/zhuinden/examplegithubclient/presentation/paths/login/LoginInstrumentedTest.java
  9. +29 −0 ...ple/src/androidTest/java/com/zhuinden/examplegithubclient/presentation/paths/login/LoginPage.java
  10. +25 −0 ...java/com/zhuinden/examplegithubclient/presentation/paths/login/LoginWaitForDialogInstruction.java
  11. +61 −0 ...om/zhuinden/examplegithubclient/presentation/paths/repositories/RepositoriesInstrumentedTest.java
  12. +15 −0 ...dTest/java/com/zhuinden/examplegithubclient/presentation/paths/repositories/RepositoriesPage.java
  13. +78 −0 ...ss-mvp-example/src/androidTest/java/com/zhuinden/examplegithubclient/util/FlowViewAssertions.java
  14. +21 −0 flowless-mvp-example/src/main/AndroidManifest.xml
  15. +41 −0 flowless-mvp-example/src/main/java/com/google/auto/value/AutoValue.java
  16. +14 −0 flowless-mvp-example/src/main/java/com/zhuinden/examplegithubclient/application/BoltsExecutors.java
  17. +26 −0 ...ess-mvp-example/src/main/java/com/zhuinden/examplegithubclient/application/CustomApplication.java
  18. +14 −0 ...p-example/src/main/java/com/zhuinden/examplegithubclient/application/injection/ActivityScope.java
  19. +15 −0 ...ss-mvp-example/src/main/java/com/zhuinden/examplegithubclient/application/injection/KeyScope.java
  20. +31 −0 .../main/java/com/zhuinden/examplegithubclient/application/injection/config/MainComponentConfig.java
  21. +26 −0 ...rc/main/java/com/zhuinden/examplegithubclient/application/injection/modules/InteractorModule.java
  22. +22 −0 ...le/src/main/java/com/zhuinden/examplegithubclient/application/injection/modules/OkHttpModule.java
  23. +19 −0 ...rc/main/java/com/zhuinden/examplegithubclient/application/injection/modules/RepositoryModule.java
  24. +41 −0 .../src/main/java/com/zhuinden/examplegithubclient/application/injection/modules/RetrofitModule.java
  25. +19 −0 ...e/src/main/java/com/zhuinden/examplegithubclient/application/injection/modules/ServiceModule.java
  26. +42 −0 flowless-mvp-example/src/main/java/com/zhuinden/examplegithubclient/data/model/BaseDataSource.java
  27. +25 −0 flowless-mvp-example/src/main/java/com/zhuinden/examplegithubclient/data/model/DataSource.java
  28. +28 −0 ...s-mvp-example/src/main/java/com/zhuinden/examplegithubclient/data/model/RepositoryDataSource.java
  29. +30 −0 flowless-mvp-example/src/main/java/com/zhuinden/examplegithubclient/data/repository/Repository.java
  30. +10 −0 ...-example/src/main/java/com/zhuinden/examplegithubclient/data/repository/RepositoryRepository.java
  31. +121 −0 .../java/com/zhuinden/examplegithubclient/data/repository/impl/RepositoryRepositoryInMemoryImpl.java
  32. +285 −0 flowless-mvp-example/src/main/java/com/zhuinden/examplegithubclient/domain/data/response/Owner.java
  33. +59 −0 ...-mvp-example/src/main/java/com/zhuinden/examplegithubclient/domain/data/response/error/Error.java
  34. +56 −0 ...mple/src/main/java/com/zhuinden/examplegithubclient/domain/data/response/error/ErrorResponse.java
  35. +1,119 −0 ...rc/main/java/com/zhuinden/examplegithubclient/domain/data/response/organization/Organization.java
  36. +59 −0 .../src/main/java/com/zhuinden/examplegithubclient/domain/data/response/organization/Permission.java
  37. +1,097 −0 .../src/main/java/com/zhuinden/examplegithubclient/domain/data/response/repositories/Repository.java
  38. +15 −0 ...e/src/main/java/com/zhuinden/examplegithubclient/domain/interactor/GetRepositoriesInteractor.java
  39. +11 −0 ...mvp-example/src/main/java/com/zhuinden/examplegithubclient/domain/interactor/LoginInteractor.java
  40. +41 −0 ...n/java/com/zhuinden/examplegithubclient/domain/interactor/impl/GetRepositoriesInteractorImpl.java
  41. +29 −0 ...le/src/main/java/com/zhuinden/examplegithubclient/domain/interactor/impl/LoginInteractorImpl.java
  42. +30 −0 ...p-example/src/main/java/com/zhuinden/examplegithubclient/domain/networking/HeaderInterceptor.java
  43. +18 −0 ...less-mvp-example/src/main/java/com/zhuinden/examplegithubclient/domain/service/GithubService.java
  44. +37 −0 ...example/src/main/java/com/zhuinden/examplegithubclient/domain/service/impl/GithubServiceImpl.java
  45. +23 −0 ...src/main/java/com/zhuinden/examplegithubclient/domain/service/retrofit/RetrofitGithubService.java
  46. +164 −0 ...ample/src/main/java/com/zhuinden/examplegithubclient/presentation/activity/main/MainActivity.java
  47. +53 −0 ...mple/src/main/java/com/zhuinden/examplegithubclient/presentation/activity/main/MainComponent.java
  48. +43 −0 ...vp-example/src/main/java/com/zhuinden/examplegithubclient/presentation/activity/main/MainKey.java
  49. +226 −0 ...mple/src/main/java/com/zhuinden/examplegithubclient/presentation/activity/main/MainPresenter.java
  50. +135 −0 ...p-example/src/main/java/com/zhuinden/examplegithubclient/presentation/activity/main/MainView.java
  51. +22 −0 ...mvp-example/src/main/java/com/zhuinden/examplegithubclient/presentation/paths/about/AboutKey.java
  52. +40 −0 ...vp-example/src/main/java/com/zhuinden/examplegithubclient/presentation/paths/about/AboutView.java
  53. +17 −0 ...ample/src/main/java/com/zhuinden/examplegithubclient/presentation/paths/login/LoginComponent.java
  54. +20 −0 ...rc/main/java/com/zhuinden/examplegithubclient/presentation/paths/login/LoginComponentFactory.java
  55. +29 −0 ...mvp-example/src/main/java/com/zhuinden/examplegithubclient/presentation/paths/login/LoginKey.java
  56. +119 −0 ...ample/src/main/java/com/zhuinden/examplegithubclient/presentation/paths/login/LoginPresenter.java
  57. +164 −0 ...vp-example/src/main/java/com/zhuinden/examplegithubclient/presentation/paths/login/LoginView.java
  58. +110 −0 ...in/java/com/zhuinden/examplegithubclient/presentation/paths/repositories/RepositoriesAdapter.java
  59. +21 −0 .../java/com/zhuinden/examplegithubclient/presentation/paths/repositories/RepositoriesComponent.java
  60. +20 −0 ...om/zhuinden/examplegithubclient/presentation/paths/repositories/RepositoriesComponentFactory.java
  61. +24 −0 ...c/main/java/com/zhuinden/examplegithubclient/presentation/paths/repositories/RepositoriesKey.java
  62. +113 −0 .../java/com/zhuinden/examplegithubclient/presentation/paths/repositories/RepositoriesPresenter.java
  63. +109 −0 .../main/java/com/zhuinden/examplegithubclient/presentation/paths/repositories/RepositoriesView.java
  64. +17 −0 ...zhuinden/examplegithubclient/presentation/paths/repositorydetails/RepositoryDetailsComponent.java
  65. +20 −0 ...n/examplegithubclient/presentation/paths/repositorydetails/RepositoryDetailsComponentFactory.java
  66. +33 −0 ...a/com/zhuinden/examplegithubclient/presentation/paths/repositorydetails/RepositoryDetailsKey.java
  67. +37 −0 ...zhuinden/examplegithubclient/presentation/paths/repositorydetails/RepositoryDetailsPresenter.java
  68. +365 −0 .../com/zhuinden/examplegithubclient/presentation/paths/repositorydetails/RepositoryDetailsView.java
  69. +78 −0 ...c/main/java/com/zhuinden/examplegithubclient/presentation/views/leftdrawer/LeftDrawerAdapter.java
  70. +46 −0 ...src/main/java/com/zhuinden/examplegithubclient/presentation/views/leftdrawer/LeftDrawerItems.java
  71. +60 −0 .../src/main/java/com/zhuinden/examplegithubclient/presentation/views/leftdrawer/LeftDrawerView.java
  72. +121 −0 flowless-mvp-example/src/main/java/com/zhuinden/examplegithubclient/util/AnnotationCache.java
  73. +39 −0 flowless-mvp-example/src/main/java/com/zhuinden/examplegithubclient/util/BasePresenter.java
  74. +19 −0 flowless-mvp-example/src/main/java/com/zhuinden/examplegithubclient/util/BundleFactory.java
  75. +20 −0 flowless-mvp-example/src/main/java/com/zhuinden/examplegithubclient/util/ComponentFactory.java
  76. +27 −0 flowless-mvp-example/src/main/java/com/zhuinden/examplegithubclient/util/DaggerService.java
  77. +62 −0 flowless-mvp-example/src/main/java/com/zhuinden/examplegithubclient/util/FlowlessActivity.java
  78. +64 −0 flowless-mvp-example/src/main/java/com/zhuinden/examplegithubclient/util/GlideImageView.java
  79. +15 −0 flowless-mvp-example/src/main/java/com/zhuinden/examplegithubclient/util/IsChildOf.java
  80. +18 −0 flowless-mvp-example/src/main/java/com/zhuinden/examplegithubclient/util/Layout.java
  81. +14 −0 flowless-mvp-example/src/main/java/com/zhuinden/examplegithubclient/util/LeftDrawerEnabled.java
  82. +14 −0 flowless-mvp-example/src/main/java/com/zhuinden/examplegithubclient/util/Presenter.java
  83. +17 −0 flowless-mvp-example/src/main/java/com/zhuinden/examplegithubclient/util/Title.java
  84. +14 −0 ...less-mvp-example/src/main/java/com/zhuinden/examplegithubclient/util/ToolbarButtonVisibility.java
  85. +87 −0 flowless-mvp-example/src/main/java/com/zhuinden/examplegithubclient/util/TransitionDispatcher.java
  86. +232 −0 ...vp-example/src/main/java/com/zhuinden/examplegithubclient/util/bolts/BoltsCallAdapterFactory.java
  87. +63 −0 ...xample/src/main/java/com/zhuinden/examplegithubclient/util/conditionwatcher/ConditionWatcher.java
  88. +25 −0 ...mvp-example/src/main/java/com/zhuinden/examplegithubclient/util/conditionwatcher/Instruction.java
  89. +108 −0 ...le/src/main/java/com/zhuinden/examplegithubclient/util/idlingresource/EspressoIdlingResource.java
  90. +25 −0 ...le/src/main/java/com/zhuinden/examplegithubclient/util/idlingresource/FlowlessIdlingResource.java
  91. +7 −0 flowless-mvp-example/src/main/java/javax/microedition/khronos/opengles/GL.java
  92. BIN flowless-mvp-example/src/main/res/drawable-hdpi/icon_about.png
  93. BIN flowless-mvp-example/src/main/res/drawable-hdpi/icon_arrow_back.png
  94. BIN flowless-mvp-example/src/main/res/drawable-hdpi/icon_hamburger.png
  95. BIN flowless-mvp-example/src/main/res/drawable-hdpi/icon_logout.png
  96. BIN flowless-mvp-example/src/main/res/drawable-hdpi/icon_repositories.png
  97. BIN flowless-mvp-example/src/main/res/drawable-ldrtl-hdpi/icon_arrow_back.png
  98. BIN flowless-mvp-example/src/main/res/drawable-ldrtl-mdpi/icon_arrow_back.png
  99. BIN flowless-mvp-example/src/main/res/drawable-ldrtl-xhdpi/icon_arrow_back.png
  100. BIN flowless-mvp-example/src/main/res/drawable-ldrtl-xxhdpi/icon_arrow_back.png
  101. BIN flowless-mvp-example/src/main/res/drawable-ldrtl-xxxhdpi/icon_arrow_back.png
  102. BIN flowless-mvp-example/src/main/res/drawable-mdpi/icon_about.png
  103. BIN flowless-mvp-example/src/main/res/drawable-mdpi/icon_arrow_back.png
  104. BIN flowless-mvp-example/src/main/res/drawable-mdpi/icon_hamburger.png
  105. BIN flowless-mvp-example/src/main/res/drawable-mdpi/icon_logout.png
  106. BIN flowless-mvp-example/src/main/res/drawable-mdpi/icon_repositories.png
  107. BIN flowless-mvp-example/src/main/res/drawable-xhdpi/icon_about.png
  108. BIN flowless-mvp-example/src/main/res/drawable-xhdpi/icon_arrow_back.png
  109. BIN flowless-mvp-example/src/main/res/drawable-xhdpi/icon_hamburger.png
  110. BIN flowless-mvp-example/src/main/res/drawable-xhdpi/icon_logout.png
  111. BIN flowless-mvp-example/src/main/res/drawable-xhdpi/icon_repositories.png
  112. BIN flowless-mvp-example/src/main/res/drawable-xxhdpi/icon_about.png
  113. BIN flowless-mvp-example/src/main/res/drawable-xxhdpi/icon_arrow_back.png
  114. BIN flowless-mvp-example/src/main/res/drawable-xxhdpi/icon_hamburger.png
  115. BIN flowless-mvp-example/src/main/res/drawable-xxhdpi/icon_logout.png
  116. BIN flowless-mvp-example/src/main/res/drawable-xxhdpi/icon_repositories.png
  117. BIN flowless-mvp-example/src/main/res/drawable-xxxhdpi/icon_about.png
  118. BIN flowless-mvp-example/src/main/res/drawable-xxxhdpi/icon_arrow_back.png
  119. BIN flowless-mvp-example/src/main/res/drawable-xxxhdpi/icon_hamburger.png
  120. BIN flowless-mvp-example/src/main/res/drawable-xxxhdpi/icon_logout.png
  121. BIN flowless-mvp-example/src/main/res/drawable-xxxhdpi/icon_repositories.png
  122. +7 −0 flowless-mvp-example/src/main/res/drawable/drawer_button_selector.xml
  123. +7 −0 flowless-mvp-example/src/main/res/drawable/normal_button_selector.xml
  124. +34 −0 flowless-mvp-example/src/main/res/layout/activity_main.xml
  125. +14 −0 flowless-mvp-example/src/main/res/layout/path_about.xml
  126. +49 −0 flowless-mvp-example/src/main/res/layout/path_login.xml
  127. +11 −0 flowless-mvp-example/src/main/res/layout/path_repositories.xml
  128. +629 −0 flowless-mvp-example/src/main/res/layout/path_repositorydetails.xml
  129. +16 −0 flowless-mvp-example/src/main/res/layout/view_left_drawer.xml
  130. +45 −0 flowless-mvp-example/src/main/res/layout/view_left_drawer_item.xml
  131. +19 −0 flowless-mvp-example/src/main/res/layout/view_repositories_load_more_row.xml
  132. +24 −0 flowless-mvp-example/src/main/res/layout/view_repositories_row.xml
  133. +47 −0 flowless-mvp-example/src/main/res/layout/view_toolbar.xml
  134. BIN flowless-mvp-example/src/main/res/mipmap-hdpi/ic_launcher.png
  135. BIN flowless-mvp-example/src/main/res/mipmap-mdpi/ic_launcher.png
  136. BIN flowless-mvp-example/src/main/res/mipmap-xhdpi/ic_launcher.png
  137. BIN flowless-mvp-example/src/main/res/mipmap-xxhdpi/ic_launcher.png
  138. BIN flowless-mvp-example/src/main/res/mipmap-xxxhdpi/ic_launcher.png
  139. +6 −0 flowless-mvp-example/src/main/res/values-w820dp/dimens.xml
  140. +6 −0 flowless-mvp-example/src/main/res/values/attrs.xml
  141. +20 −0 flowless-mvp-example/src/main/res/values/colors.xml
  142. +5 −0 flowless-mvp-example/src/main/res/values/dimens.xml
  143. +17 −0 flowless-mvp-example/src/main/res/values/strings.xml
  144. +11 −0 flowless-mvp-example/src/main/res/values/styles.xml
  145. +16 −0 flowless-mvp-example/src/test/java/com/zhuinden/examplegithubclient/UnitTestSuite.java
  146. +76 −0 ...example/src/test/java/com/zhuinden/examplegithubclient/presentation/paths/login/LoginKeyTest.java
  147. +194 −0 ...e/src/test/java/com/zhuinden/examplegithubclient/presentation/paths/login/LoginPresenterTest.java
  148. +13 −0 ...ample/src/test/java/com/zhuinden/examplegithubclient/presentation/paths/login/LoginTestSuite.java
  149. +268 −0 ...a/com/zhuinden/examplegithubclient/presentation/paths/repositories/RepositoriesPresenterTest.java
  150. +13 −0 .../java/com/zhuinden/examplegithubclient/presentation/paths/repositories/RepositoriesTestSuite.java
  151. +21 −0 flowless-mvp-example/src/test/java/com/zhuinden/examplegithubclient/util/BoltsConfig.java
  152. +10 −0 flowless-mvp-example/src/test/java/com/zhuinden/examplegithubclient/util/BundleFactoryConfig.java
  153. +11 −0 flowless-mvp-example/src/test/java/com/zhuinden/examplegithubclient/util/PresenterUtils.java
  154. +11 −0 flowless-mvp-example/src/test/java/flowless/FlowFactory.java
  155. +1 −1 settings.gradle
View
@@ -10,6 +10,7 @@ buildscript {
dependencies {
classpath 'com.android.tools.build:gradle:2.2.2'
classpath 'com.neenbedankt.gradle.plugins:android-apt:1.8'
+ classpath 'me.tatarka:gradle-retrolambda:3.2.5'
classpath 'com.github.dcendents:android-maven-gradle-plugin:1.5'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
@@ -0,0 +1 @@
+/build
@@ -0,0 +1,195 @@
+apply plugin: 'com.android.application'
+apply plugin: 'com.neenbedankt.android-apt'
+apply plugin: 'me.tatarka.retrolambda'
+// apply plugin: 'realm-android'
+
+android {
+ compileSdkVersion 24
+ buildToolsVersion "24.0.3"
+
+ compileOptions {
+ sourceCompatibility JavaVersion.VERSION_1_8
+ targetCompatibility JavaVersion.VERSION_1_8
+ }
+ defaultConfig {
+ applicationId "com.zhuinden.examplegithubclient"
+ minSdkVersion 14
+ targetSdkVersion 24
+ versionCode 1
+ versionName "1.0"
+ testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
+ }
+ buildTypes {
+ release {
+ minifyEnabled false
+ proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
+ }
+ }
+
+ testOptions.unitTests.all {
+ testLogging {
+ events 'passed', 'skipped', 'failed', 'standardOut', 'standardError'
+ }
+ }
+ dexOptions {
+ jumboMode true
+ }
+ //sourceSets {
+ // main.res.srcDirs += ['src/main/res_sdp'] // doesn't work for some reason
+ //}
+ packagingOptions {
+ // Exclude file to avoid
+ // Error: Duplicate files during packaging of APK
+ exclude 'META-INF/DEPENDENCIES'
+ exclude 'META-INF/LICENSE'
+ exclude 'META-INF/LICENSE.txt'
+ exclude 'META-INF/license.txt'
+ exclude 'META-INF/NOTICE'
+ exclude 'META-INF/NOTICE.txt'
+ exclude 'META-INF/notice.txt'
+ exclude 'META-INF/ASL2.0'
+ exclude 'META-INF/services/javax.annotation.processing.Processor'
+ }
+ productFlavors {
+ }
+}
+
+dependencies {
+ compile fileTree(dir: 'libs', include: ['*.jar'])
+ compile project(':flowless-library')
+
+ compile 'com.android.support:appcompat-v7:24.2.1'
+ compile "com.android.support:recyclerview-v7:24.2.1"
+ compile "com.android.support:support-v4:24.2.1"
+
+ // view transitions
+ compile "com.andkulikov:transitionseverywhere:1.7.0"
+
+ // less boilerplate
+ compile 'com.jakewharton:butterknife:8.4.0'
+ apt 'com.jakewharton:butterknife-compiler:8.4.0'
+
+ // view sizes
+ compile 'com.intuit.sdp:sdp-android:1.0.4'
+
+ // DI
+ compile 'com.google.dagger:dagger:2.7'
+ apt 'com.google.dagger:dagger-compiler:2.7'
+ provided 'org.glassfish:javax.annotation:10.0-b28'
+
+ // auto-parcel for key
+ apt 'frankiesardo:auto-parcel:1.0.3'
+
+ // networking
+ compile 'com.squareup.retrofit2:retrofit:2.1.0'
+ compile 'com.squareup.okhttp3:okhttp:3.4.1'
+
+ // image loading
+ compile 'com.github.bumptech.glide:okhttp3-integration:1.4.0@aar'
+ compile 'com.github.bumptech.glide:glide:3.7.0'
+
+ // tasks instead of rx for now
+ compile 'com.parse.bolts:bolts-tasks:1.4.0'
+
+ // eventbus instead of rx for now
+ compile 'org.greenrobot:eventbus:3.0.0'
+
+ // json
+ apt 'com.bluelinelabs:logansquare-compiler:1.3.7'
+ compile 'com.bluelinelabs:logansquare:1.3.7'
+ compile "com.github.aurae.retrofit2:converter-logansquare:1.4.1"
+
+ testCompile 'junit:junit:4.12'
+ testCompile 'org.mockito:mockito-core:2.3.7'
+ //testCompile 'org.assertj:assertj-core:1.7.1'
+ testCompile 'com.squareup.assertj:assertj-android:1.1.1'
+ testCompile('com.squareup.assertj:assertj-android-support-v4:1.1.1') {
+ exclude group: 'com.android.support'
+ }
+ testCompile('com.squareup.assertj:assertj-android-appcompat-v7:1.1.1') {
+ exclude group: 'com.android.support'
+ }
+ testCompile('com.squareup.assertj:assertj-android-recyclerview-v7:1.1.1') {
+ exclude module: 'recyclerview-v7'
+ }
+
+// testCompile "org.powermock:powermock-module-junit4:1.6.4"
+// testCompile "org.powermock:powermock-module-junit4-rule:1.6.4"
+// testCompile "org.powermock:powermock-api-mockito:1.6.4"
+// testCompile "org.powermock:powermock-classloading-xstream:1.6.4"
+
+ //testCompile "org.hamcrest:hamcrest-all:1.3"
+ testCompile "org.robolectric:robolectric:3.1.1"
+
+ androidTestCompile("com.android.support.test:runner:0.5", {
+ exclude group: 'com.android.support', module: 'support-annotations'
+ })
+ androidTestCompile("com.android.support.test:rules:0.5", {
+ exclude group: 'com.android.support', module: 'support-annotations'
+ })
+
+ androidTestCompile("com.android.support.test.espresso:espresso-core:2.2.2") {
+ exclude group: 'javax.inject'
+ exclude group: 'com.android.support', module: 'support-annotations'
+ exclude group: 'com.android.support', module: 'appcompat'
+ exclude group: 'com.android.support', module: 'support-v4'
+ exclude module: 'recyclerview-v7'
+ }
+
+ compile('com.android.support.test.espresso:espresso-idling-resource:2.2.2') {
+ exclude group: 'javax.inject'
+ exclude group: 'com.android.support', module: 'appcompat'
+ exclude group: 'com.android.support', module: 'support-annotations'
+ exclude group: 'com.android.support', module: 'support-v4'
+ exclude module: 'recyclerview-v7'
+ exclude module: 'design'
+ }
+
+ androidTestCompile("com.android.support.test.espresso:espresso-contrib:2.2.2") {
+ exclude group: 'javax.inject'
+ exclude group: 'com.android.support', module: 'appcompat'
+ exclude group: 'com.android.support', module: 'support-annotations'
+ exclude group: 'com.android.support', module: 'support-v4'
+ exclude module: 'recyclerview-v7'
+ exclude module: 'design'
+ }
+
+ androidTestCompile("com.android.support.test.espresso:espresso-intents:2.2.2") {
+ exclude group: 'javax.inject'
+ exclude group: 'com.android.support', module: 'appcompat'
+ exclude group: 'com.android.support', module: 'support-v4'
+ exclude group: 'com.android.support', module: 'support-annotations'
+ exclude module: 'recyclerview-v7'
+ }
+
+ androidTestCompile 'com.squareup.assertj:assertj-android:1.1.1'
+ androidTestCompile('com.squareup.assertj:assertj-android-support-v4:1.1.1') {
+ exclude group: 'com.android.support'
+ }
+ androidTestCompile('com.squareup.assertj:assertj-android-appcompat-v7:1.1.1') {
+ exclude group: 'com.android.support'
+ }
+ androidTestCompile('com.squareup.assertj:assertj-android-recyclerview-v7:1.1.1') {
+ exclude module: 'recyclerview-v7'
+ }
+
+ testCompile 'com.squareup.okhttp3:mockwebserver:3.4.1'
+ androidTestCompile 'com.squareup.okhttp3:mockwebserver:3.4.1'
+
+ // for espresso without dagger
+ //androidTestCompile 'com.google.dagger:dagger:2.7'
+ //apt 'com.google.dagger:dagger-compiler:2.7'
+ //provided 'org.glassfish:javax.annotation:10.0-b28'
+
+}
+
+configurations.all {
+ resolutionStrategy.force "com.android.support:support-annotations:24.2.1"
+}
+
+configurations.compile.dependencies.each { compileDependency ->
+ println "Excluding compile dependency: ${compileDependency.getName()}"
+ configurations.androidTestCompile.dependencies.each { androidTestCompileDependency ->
+ configurations.androidTestCompile.exclude module: "${compileDependency.getName()}"
+ }
+}
Oops, something went wrong.

0 comments on commit d2b58d0

Please sign in to comment.