use of com.linkedin.restli.examples.greetings.client.ActionsFluentClient in project rest.li by linkedin.
the class TestParseqBasedFluentClientApi method testActionSetActionWithTypeRef.
@Test
public void testActionSetActionWithTypeRef() throws Exception {
// This end point use typeref for both ActionParam and Action methods' return value
Actions actionsFluentClient = new ActionsFluentClient(_parSeqRestliClient, _parSeqUnitTestHelper.getEngine());
Assert.assertEquals(actionsFluentClient.customTypeRef(new CustomLong(500L)).toCompletableFuture().get(5000, TimeUnit.MILLISECONDS), new CustomLong(500L));
}
use of com.linkedin.restli.examples.greetings.client.ActionsFluentClient in project rest.li by linkedin.
the class TestParseqBasedFluentClientApi method testActionSetActionWithReturn.
@Test
public void testActionSetActionWithReturn() throws Exception {
Actions actionsFluentClient = new ActionsFluentClient(_parSeqRestliClient, _parSeqUnitTestHelper.getEngine());
Assert.assertTrue(actionsFluentClient.ultimateAnswer().toCompletableFuture().get(5000, TimeUnit.MILLISECONDS) == 42);
}
use of com.linkedin.restli.examples.greetings.client.ActionsFluentClient in project rest.li by linkedin.
the class TestParseqBasedFluentClientApi method testActionSetActionWithNoReturn.
@Test
public void testActionSetActionWithNoReturn() throws Exception {
Actions actionsFluentClient = new ActionsFluentClient(_parSeqRestliClient, _parSeqUnitTestHelper.getEngine());
Assert.assertNull(actionsFluentClient.returnVoid().toCompletableFuture().get(5000, TimeUnit.MILLISECONDS));
}
Aggregations