public class Injector
extends java.lang.Object
| Constructor and Description |
|---|
Injector() |
| Modifier and Type | Method and Description |
|---|---|
static void |
injectMocks(java.lang.Object host)
Inject a mock to every fields annotated with
Mock on the class passed
in parameter. |
public static void injectMocks(java.lang.Object host)
Mock on the class passed
in parameter. Then, inject these mocks to the fields of every class annotated with TestSubject.
The rules are
Note: If the parameter extends EasyMockSupport, the mocks will be created using it to allow
replayAll/verifyAll to work afterwards
host - the object on which to inject mocks