### Question:
UserService { public List<User> list() { return userRepository.findAll(); } @Autowired  UserService(UserRepository userRepository, UserManagementProperties userManagementProperties); List<User> list(); User create(String name, String currency); User get(long id); String getTestProperty();  }### Answer:
@Test public void shouldReturnAllUser() throws Exception { final List<User> bobAndJane = UserTestUtils.createBobAndJane(); when(userRepositoryMock.findAll()).thenReturn(bobAndJane); final List<User> list = testSubject.list(); assertThat(list).isEqualTo(bobAndJane); }