### Question:
ConsumedThingAction extends ThingAction<I, O> { public CompletableFuture<O> invoke() { return invoke(Collections.emptyMap()); } ConsumedThingAction(String name,
                               ThingAction<I, O> action,
                               ConsumedThing thing); CompletableFuture<O> invoke(); CompletableFuture<O> invoke(Map<String, Object> parameters); @Override int hashCode(); @Override boolean equals(Object o); @Override String toString();  }### Answer:
@Test public void invokeShouldCallUnderlyingClient() throws ConsumedThingException { when(thing.getClientFor(any(List.class), any())).thenReturn(new Pair(client, form)); when(form.getHref()).thenReturn("test:/myAction"); when(client.invokeResource(any(), any())).thenReturn(completedFuture(null)); ConsumedThingAction consumedThingAction = new ConsumedThingAction("myAction", action, thing); consumedThingAction.invoke(); verify(client).invokeResource(any(), any()); }