Skip to content

Commit bd2ceb4

Browse files
committed
Testing rest controller
Signed-off-by: Kemal Žigović <kvant800@gmail.com>
1 parent 9c309d9 commit bd2ceb4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/test/java/com/kvark900/TestControllers.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public void testController() throws Exception{
4242

4343
List<Author> allAuthors = Collections.singletonList(author);
4444

45-
given(authorService.findAll()).willReturn();
45+
given(authorService.findAll()).willReturn(allAuthors);
4646

4747
mockMvc.perform(get("/authors")
4848
.contentType(MediaType.APPLICATION_JSON))

0 commit comments

Comments
 (0)