title: jacocoTestReport task not being generated
body: <pre><code>Android Studio 3.1 Canary 8
  Build #AI-173.4529993, built on January 6, 2018
  JRE: 1.8.0_152-release-1024-b01 amd64
  JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
  Linux 4.14.14-300.fc27.x86_64
  </code></pre>
  
  <p>I am trying to use the jacoco to generate code coverage. However, when I run the command <code>./gradlew tasks</code> I don't see any tasks called <code>jacocoTestReport</code>.</p>
  
  <p>I get the below error when I try and run the tasks <code>./gradlew jacocoTestReport</code>:</p>
  
  <blockquote>
    <p>Task 'jacocoTestReport' not found in root project 'EnumSample'</p>
  </blockquote>
  
  <p>This is my build.gradlew file:</p>
  
  <pre><code>apply plugin: 'com.android.application'
  apply plugin: 'jacoco'
  
  android {
      compileSdkVersion 27
      defaultConfig {
          applicationId "me.androidbox.enumsample"
          minSdkVersion 19
          targetSdkVersion 27
          versionCode 1
          versionName "1.0"
          testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
      }
      buildTypes {
          release {
              minifyEnabled false
              proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
          }
          debug {
              testCoverageEnabled true
          }
      }
  }
  
  jacoco {
      toolVersion "0.8.0"
  }
  
  task jacocoTestReport(type: JacocoReport) {
      executionData fileTree(project.rootDir.absolutePath).include("**/build/jacoco/*.exec")
  
      subprojects.each {
          sourceSets it.sourceSets.main
      }
  
      reports {
          xml.enabled true
          html.enabled false
          csv.enabled false
      }
  }
  
  dependencies {
      implementation fileTree(dir: 'libs', include: ['*.jar'])
      implementation 'com.android.support:appcompat-v7:27.0.2'
      implementation 'com.android.support.constraint:constraint-layout:1.0.2'
      testImplementation 'junit:junit:4.12'
      androidTestImplementation 'com.android.support.test:runner:1.0.1'
      androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.1'
  }
  </code></pre>
  
  <p>I have tried to clean and rebuild the project. However, the reporting task isn't there. </p>
  
  <p>Many thanks for any suggestions.</p>