Uses of Interface
io.avaje.inject.BeanScopeBuilder.ForTesting
| Package | Description |
|---|---|
| io.avaje.inject |
Avaje Inject API - see
BeanScope. |
-
Uses of BeanScopeBuilder.ForTesting in io.avaje.inject
Methods in io.avaje.inject that return BeanScopeBuilder.ForTesting Modifier and Type Method Description BeanScopeBuilder.ForTestingBeanScopeBuilder. forTesting()Extend the builder to support testing using mockito withwithMock()andwithSpy()methods.BeanScopeBuilder.ForTestingBeanScopeBuilder.ForTesting. withMock(Class<?> type)Use a mockito mock when injecting this bean type.BeanScopeBuilder.ForTestingBeanScopeBuilder.ForTesting. withMock(Class<?> type, String name)Register as a Mockito mock with a qualifier name.<D> BeanScopeBuilder.ForTestingBeanScopeBuilder.ForTesting. withMock(Class<D> type, Consumer<D> consumer)Use a mockito mock when injecting this bean type additionally running setup on the mock instance.BeanScopeBuilder.ForTestingBeanScopeBuilder.ForTesting. withSpy(Class<?> type)Use a mockito spy when injecting this bean type.BeanScopeBuilder.ForTestingBeanScopeBuilder.ForTesting. withSpy(Class<?> type, String name)Register a Mockito spy with a qualifier name.<D> BeanScopeBuilder.ForTestingBeanScopeBuilder.ForTesting. withSpy(Class<D> type, Consumer<D> consumer)Use a mockito spy when injecting this bean type additionally running setup on the spy instance.