final InvocationControl invocationBControl = new InvocationControl("B");
final InvocationControl invocationCControl = new InvocationControl("C");
final Map<String, Foo> invocationResults = new HashMap<String, Foo>();
final InvocationContext invocationA = new MockInvocationContext() {
@Override public Object getTarget() { return fooBar; }
@Override public Method getMethod() { return m; }
@Override public Object[] getParameters() { return new Object[] { invocationAControl }; }
@Override public Object proceed() throws Exception { return Reflections.invoke(getMethod(), getTarget(), getParameters()); }
};
final InvocationContext invocationB = new MockInvocationContext() {
@Override public Object getTarget() { return fooBar; }
@Override public Method getMethod() { return m; }
@Override public Object[] getParameters() { return new Object[] { invocationBControl }; }
@Override public Object proceed() throws Exception { return Reflections.invoke(getMethod(), getTarget(), getParameters()); }
};
final InvocationContext invocationC = new MockInvocationContext() {
@Override public Object getTarget() { return fooBar; }
@Override public Method getMethod() { return m; }
@Override public Object[] getParameters() { return new Object[] { invocationCControl }; }
@Override public Object proceed() throws Exception { return Reflections.invoke(getMethod(), getTarget(), getParameters()); }
};