f2prateek/dart

"Cannot access class" when using Henson in Espresso test written in Kotlin

joharei opened this issue · 0 comments

I'm trying to use Henson in my Espresso test like this:

activityRule.launchActivity(Henson.with(MainApplication.getAppContext())
    .gotoMyActivity()
    .build())

Compilation fails with the following error:

Error:(31, 18) Cannot access class 'my.package.MyActivity$.IntentBuilder'. Check your module classpath for missing or conflicting dependencies

I'm using kapt for all my annotation processors. The code is indeed generated under /build/generated/source/kapt/main/my/package/MyActivity$$IntentBuilder.java, and the Android Studio lint doesn't complain.