Package dagger.hilt.android.testing
Annotation Type BindValue
-
@Retention(CLASS) @Target(FIELD) public @interface BindValue
An annotation that can be used on a test field to contribute the value into theSingletonComponent
. Example usage:
Herepublic class FooTest{ ... @BindValue Bar boundBar = new Bar(); ... }
boundBar
will be accessible to the entire application for your test.