How to delete androidTest & test folders for ever that not show up when creating new app
Date : March 29 2020, 07:55 AM
this will help How can I delete androidTest & test folders that creates automatically when you create an app in Android Studio?
|
Organize shared code between androidTest and test
Date : March 29 2020, 07:55 AM
seems to work fine I often get around this by creating a src/commonTest/java sourceset and expose that to both the instrumentation tests and unit tests by adding the following to my gradle file: android {
sourceSets {
String sharedTestDir = 'src/commonTest/java'
test {
java.srcDir sharedTestDir
}
androidTest {
java.srcDir sharedTestDir
}
}
}
|
Creating dependent component in dagger 2
Date : March 29 2020, 07:55 AM
around this issue When you create a builder to your dependent component never mark a setter of your main component with @BindsInstance @MyTestScope
@Component(dependencies = [AppComponent::class],
modules = [TestModule::class])
interface DependentComponent {
@Component.Builder
interface Builder {
fun appComponent(component: AppComponent): Builder
fun build(): DependentComponent
}
fun inject(application: Application)
}
|
Dagger not generating Component classes for androidTest
Date : March 29 2020, 07:55 AM
|
Dagger test component not found
Date : March 29 2020, 07:55 AM
|