title: Why is my androidx instrumented test suite process crashing?
body: <p>Starting a new project with the following dependencies:</p>
  
  <pre><code>dependencies {
      implementation fileTree(dir: 'libs', include: ['*.jar'])
      implementation"org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
      implementation 'com.android.support:appcompat-v7:28.0.0'
      implementation 'com.android.support.constraint:constraint-layout:1.1.3'
      testImplementation 'junit:junit:4.12'
      testImplementation 'org.robolectric:robolectric:4.0.2'
      androidTestImplementation "androidx.test.ext:junit:1.0.0"
  androidTestImplementation "androidx.test:rules:1.1.0"
  androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.0'
  }
  </code></pre>
  
  <p>With a default config set to this:</p>
  
  <pre><code>android {
    ...
    defaultConfig {
      testInstrumentationRunner 'androidx.test.ext.junit.runners.AndroidJUnit4'
    }
  }
  </code></pre>
  
  <p>I've written the following test class:</p>
  
  <pre><code>import androidx.test.espresso.Espresso.onView
  import androidx.test.espresso.action.ViewActions.*
  import androidx.test.espresso.assertion.ViewAssertions.matches
  import androidx.test.espresso.matcher.ViewMatchers.withId
  import androidx.test.espresso.matcher.ViewMatchers.withText
  import androidx.test.ext.junit.runners.AndroidJUnit4
  import androidx.test.filters.LargeTest
  import androidx.test.rule.ActivityTestRule 
  import org.junit.runner.RunWith
  
  import org.junit.Rule
  import org.junit.Test
  import org.pos.activities.Checkout
  
  @RunWith(AndroidJUnit4::class)
  @LargeTest
  class CheckoutInstrumentedTest {
  
    @get:Rule
    var activityRule: ActivityTestRule&lt;Checkout&gt; = 
           ActivityTestRule(Checkout::class.java)
  
    @Test
    fun testAddItem_computeTotal() {
        onView(withId(R.id.itemValue))
            .perform(typeText("5"), closeSoftKeyboard())
  
        onView(withId(R.id.addItemButton)).perform(click())
  
        onView(withId(R.id.total)).check(matches(withText("$5.00")))
    }
  }
  </code></pre>
  
  <p>When I run the test using Android studio, I get the following error in the test output</p>
  
  <pre><code>Test running failed: Instrumentation run failed due to 'Process crashed.'
  Empty test suite.
  </code></pre>
  
  <p>Along with the following error in <code>logcat</code>:</p>
  
  <pre><code>java.lang.RuntimeException: Unable to instantiate instrumentation ComponentInfo{org.pos.test/androidx.test.ext.junit.runners.AndroidJUnit4}: java.lang.InstantiationException: java.lang.Class&lt;androidx.test.ext.junit.runners.AndroidJUnit4&gt; has no zero argument constructor
          at android.app.ActivityThread.handleBindApplication(ActivityThread.java:5956)
          at android.app.ActivityThread.-wrap3(ActivityThread.java)
          at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1727)
          at android.os.Handler.dispatchMessage(Handler.java:102)
          at android.os.Looper.loop(Looper.java:154)
          at android.app.ActivityThread.main(ActivityThread.java:6823)
          at java.lang.reflect.Method.invoke(Native Method)
          at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1557)
          at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1445)
       Caused by: java.lang.InstantiationException: java.lang.Class&lt;androidx.test.ext.junit.runners.AndroidJUnit4&gt; has no zero argument constructor
          at java.lang.Class.newInstance(Native Method)
          at android.app.ActivityThread.handleBindApplication(ActivityThread.java:5954)
  </code></pre>
  
  <p>What is causing the runner to fail to load? I'm running this on a Samsung Galaxy Tab A running Android v7.1. </p>