title: Android multi module test dependency
body: <p><em>With Android Studio 3.0 / android_gradle_version = '3.0.1' / gradle-4.5</em></p>
  
  <p>Let's say I have two android modules</p>
  
  <pre><code>module-base
  module-a
  </code></pre>
  
  <p>When I want to access sources from module-base in module-a , I just need to write this in my 
  module-a.gradle</p>
  
  <pre><code>dependencies {
  implementation project(path: ':module-base')
  }
  </code></pre>
  
  <p><strong>But, what if I want to access test sources from module-base in test of module-a</strong>?
  <em>Here does not work approach like above</em></p>
  
  <pre><code>dependencies {
  testImplementation project(path: ':module-base')
  }
  </code></pre>
  
  <p>I found lot of advices (few years old) which says something like </p>
  
  <pre><code>    compileTestJava.dependsOn tasks.getByPath(':module-base:testClasses')
      testCompile files(project(':module-base').sourceSets.test.output.classesDir)
  </code></pre>
  
  <p>or 
  <code>testCompile project(':module-base).sourceSets.test.classes</code></p>
  
  <p>But no one from mentioned works. There is always something wrong from the compiler point of view :-/</p>
  
  <p><strong>Can you someone help me how to create Android test code dependency between two modules?</strong></p>