@Test public void testToInvocation() throws Exception { final RequestMethod<?> requestMethod = spy(RequestMethod.class); final String expected = randomUUID().toString(); when(requestMethod.runInternal(anyList())).thenReturn(expected); final Invocation<?> invocation = requestMethod.toInvocation(); final Object actual = invocation.invoke(); assertEquals(expected, actual); }
public Invocation<T> toInvocation() { return toInvocation(emptyList()); }
RequestMethod { public Invocation<T> toInvocation() { return toInvocation(emptyList()); } }
RequestMethod { public Invocation<T> toInvocation() { return toInvocation(emptyList()); }  }
RequestMethod { public Invocation<T> toInvocation() { return toInvocation(emptyList()); }  String getName(); T invoke(); T invoke(final List<Object> parameters); Invocation<T> toInvocation(); Invocation<T> toInvocation(final List<Object> parameters); @Override String toString(); @Override boolean equals(final Object obj); @Override int hashCode(); }
RequestMethod { public Invocation<T> toInvocation() { return toInvocation(emptyList()); }  String getName(); T invoke(); T invoke(final List<Object> parameters); Invocation<T> toInvocation(); Invocation<T> toInvocation(final List<Object> parameters); @Override String toString(); @Override boolean equals(final Object obj); @Override int hashCode();  }