1 package de.spring.webservices.services;
3 import org.junit.Assert;
4 import org.junit.Before;
7 import de.spring.webservices.auto.ExampleRequest;
8 import de.spring.webservices.auto.ExampleResponse;
9 import de.spring.webservices.services.impl.ExampleServiceImpl;
11 public class ExampleServiceTest {
13 private ExampleService exampleService;
17 exampleService = new ExampleServiceImpl();
21 public void givenExampleRequestThenReturnExampleResponse() {
22 ExampleRequest request = new ExampleRequest();
23 request.setData("SCARLETT");
24 ExampleResponse expected = new ExampleResponse();
25 expected.setData("SNAKE EYES AND " + request.getData());
27 ExampleResponse actual = exampleService.doResponse(request);
29 Assert.assertEquals(expected.getData(), actual.getData());