예제 #1
0
 @Test(groups = "require-test-server-running")
 public void testEndpointVoidResult() {
   TestEndpoint te = applicationContext.getBean(TestEndpoint.class);
   TestRequest tr1 = new TestRequest();
   tr1.setStringField("string");
   tr1.setCreated(new Date());
   tr1.setRequestId(System.currentTimeMillis() + ":");
   tr1.setRequestSource("src");
   tr1.setSessionId("session" + System.currentTimeMillis());
   te.testVoidResult(tr1);
 }
예제 #2
0
 @Test(groups = "require-test-server-running")
 public void testEndpointException() {
   TestEndpoint te = applicationContext.getBean(TestEndpoint.class);
   TestRequest tr1 = new TestRequest();
   tr1.setStringField("string");
   tr1.setCreated(new Date());
   tr1.setRequestId(System.currentTimeMillis() + ":");
   tr1.setRequestSource("src");
   tr1.setSessionId("session" + System.currentTimeMillis());
   TestResponse tr = te.testException(tr1);
   assertEquals(EndpointResponseStatus.ERROR, tr.getStatus());
 }