|
|
@ -148,4 +148,19 @@ class ServerAppTest |
|
|
|
assertEquals(200, res.getStatus()); |
|
|
|
then(userController).should().getCompleteUser(any(), any()); |
|
|
|
} |
|
|
|
|
|
|
|
@Test |
|
|
|
void getPlayer() throws JsonProcessingException |
|
|
|
{ |
|
|
|
when(userController.getUser(any(), any())).thenReturn(mock(Response.class)); |
|
|
|
|
|
|
|
String url = "/users/12345"; |
|
|
|
|
|
|
|
ApiTestUtils.TestResponse<String> res = new ApiTestUtils<String>() |
|
|
|
.request("GET", url, null, null, String.class); |
|
|
|
|
|
|
|
assertNotNull(res); |
|
|
|
assertEquals(200, res.getStatus()); |
|
|
|
then(userController).should().getUser(any(), any()); |
|
|
|
} |
|
|
|
} |