@Test public void shouldUpdateAUser() throws NotFoundException { User user = createUser(); userDAO.update(user); Mockito.verify(userRepository).save(user); }
public void update(User user) throws ValidationException { saveUser(user); }
UserDAO { public void update(User user) throws ValidationException { saveUser(user); } }
UserDAO { public void update(User user) throws ValidationException { saveUser(user); } @Autowired  UserDAO(UserRepository userRepository, FileDAO fileDAO, ProjectDAO projectDAO,
                   ProjectRepository projectRepository); }
UserDAO { public void update(User user) throws ValidationException { saveUser(user); } @Autowired  UserDAO(UserRepository userRepository, FileDAO fileDAO, ProjectDAO projectDAO,
                   ProjectRepository projectRepository); void create(User newUser); List<User> getAll(); List<User> getAllByRole(UserRole role); User getById(Long id); User getByEmail(String email); User getByUsername(String username); void update(User user); void delete(User authUser, Long id); void delete(User authUser, List<Long> userIds); }
UserDAO { public void update(User user) throws ValidationException { saveUser(user); } @Autowired  UserDAO(UserRepository userRepository, FileDAO fileDAO, ProjectDAO projectDAO,
                   ProjectRepository projectRepository); void create(User newUser); List<User> getAll(); List<User> getAllByRole(UserRole role); User getById(Long id); User getByEmail(String email); User getByUsername(String username); void update(User user); void delete(User authUser, Long id); void delete(User authUser, List<Long> userIds);  }