package fitnesse.slim.fixtureInteraction;
import java.lang.reflect.Constructor;
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import org.mockito.Mockito;
public class MockingInteraction extends DefaultInteraction {
@Override
public Object newInstance(Constructor<?> constructor, Object... initargs) throws InvocationTargetException, InstantiationException, IllegalAccessException {
return Mockito.mock(constructor.getDeclaringClass());
}
@Override
public Object methodInvoke(Method method, Object instance, Object... convertedArgs) throws InvocationTargetException, IllegalAccessException {
return "----mockingOnly----";
}
}