diff --git a/src/main/java/hello/GreetingController.java b/src/main/java/hello/GreetingController.java index c74cec2..9a1c7bf 100644 --- a/src/main/java/hello/GreetingController.java +++ b/src/main/java/hello/GreetingController.java @@ -8,7 +8,7 @@ @RestController public class GreetingController { - private static final String template = "Hello there, %s!"; + private static final String template = "Hello again there, %s!"; private final AtomicLong counter = new AtomicLong(); @RequestMapping("/greeting") diff --git a/src/test/java/hello/GreetingControllerTests.java b/src/test/java/hello/GreetingControllerTests.java index 86e0f0a..6ca88d0 100644 --- a/src/test/java/hello/GreetingControllerTests.java +++ b/src/test/java/hello/GreetingControllerTests.java @@ -40,7 +40,7 @@ public class GreetingControllerTests { public void noParamGreetingShouldReturnDefaultMessage() throws Exception { this.mockMvc.perform(get("/greeting")).andDo(print()).andExpect(status().isOk()) - .andExpect(jsonPath("$.content").value("Hello there, World!")); + .andExpect(jsonPath("$.content").value("Hello again there, World!")); } @Test @@ -48,7 +48,7 @@ public void paramGreetingShouldReturnTailoredMessage() throws Exception { this.mockMvc.perform(get("/greeting").param("name", "Spring Community")) .andDo(print()).andExpect(status().isOk()) - .andExpect(jsonPath("$.content").value("Hello there, Spring Community!")); + .andExpect(jsonPath("$.content").value("Hello again there, Spring Community!")); } }