public class AsyncMethodTest extends WiremockArquillianTest
CDIInvokeSimpleGetOperationTest
but uses async methods.| Constructor and Description |
|---|
AsyncMethodTest() |
| Modifier and Type | Method and Description |
|---|---|
static org.jboss.shrinkwrap.api.spec.WebArchive |
createDeployment() |
void |
testAsyncInvocationInterceptorProvider()
This test uses a
ClientRequestFilter to update the
destination URI. |
void |
testExecutorService()
Tests that the MP Rest Client implementation uses the specified
ExecutorService.
|
void |
testInterfaceMethodWithCompletionStageObjectReturnIsInvokedAsynchronously()
Tests that a Rest Client interface method that returns a CompletionStage
where it's parameterized type is some Object type other than Response) is
invoked asychronously - checking that the thread ID of the response does
not match the thread ID of the calling thread.
|
void |
testInterfaceMethodWithCompletionStageResponseReturnIsInvokedAsynchronously()
Tests that a Rest Client interface method that returns CompletionStage
is invoked asychronously - checking that the thread ID of the response
does not match the thread ID of the calling thread.
|
void |
testNullExecutorServiceThrowsIllegalArgumentException()
This test verifies that the
RestClientBuilder implementation
will throw an IllegalArgumentException when a null value is
passed to the executorService method. |
getPort, getServerURI, getServerURL, getStringURL, setupServer@Deployment public static org.jboss.shrinkwrap.api.spec.WebArchive createDeployment()
public void testInterfaceMethodWithCompletionStageResponseReturnIsInvokedAsynchronously()
throws Exception
Exception - - indicates test failurepublic void testInterfaceMethodWithCompletionStageObjectReturnIsInvokedAsynchronously()
throws Exception
Exception - - indicates test failurepublic void testExecutorService()
throws Exception
Exception - - indicates test failurepublic void testAsyncInvocationInterceptorProvider()
throws Exception
ClientRequestFilter to update the
destination URI. It attempts to update it based on a ThreadLocal object
on the calling thread. It uses an
AsyncInvocationInterceptorFactory provider to copy the
ThreadLocal value from the calling thread to the async thread.Exception - - indicates test failurepublic void testNullExecutorServiceThrowsIllegalArgumentException()
RestClientBuilder implementation
will throw an IllegalArgumentException when a null value is
passed to the executorService method.IllegalArgumentException - - expected when passing nullCopyright © 2021 Eclipse Foundation. All rights reserved.