@Test void testResetPasswordUnknownEmailAddress() { String emailAddress = "unkown@email.com"; assertThrows( InvalidEmailAddressException.class, () -> passwordResetServiceImpl.resetPassword(emailAddress)); }
@Transactional @RunAsSystem @Override public void resetPassword(String emailAddress) { User user = getUserByEmail(emailAddress); String token = passwordResetTokenService.createToken(user); sendPasswordResetMail(user, token); }
PasswordResetterImpl implements PasswordResetter { @Transactional @RunAsSystem @Override public void resetPassword(String emailAddress) { User user = getUserByEmail(emailAddress); String token = passwordResetTokenService.createToken(user); sendPasswordResetMail(user, token); } }
PasswordResetterImpl implements PasswordResetter { @Transactional @RunAsSystem @Override public void resetPassword(String emailAddress) { User user = getUserByEmail(emailAddress); String token = passwordResetTokenService.createToken(user); sendPasswordResetMail(user, token); } PasswordResetterImpl(
      PasswordResetTokenRepository passwordResetTokenRepository,
      UserService userService,
      MailSender mailSender,
      AppSettings appSettings); }
PasswordResetterImpl implements PasswordResetter { @Transactional @RunAsSystem @Override public void resetPassword(String emailAddress) { User user = getUserByEmail(emailAddress); String token = passwordResetTokenService.createToken(user); sendPasswordResetMail(user, token); } PasswordResetterImpl(
      PasswordResetTokenRepository passwordResetTokenRepository,
      UserService userService,
      MailSender mailSender,
      AppSettings appSettings); @Transactional @RunAsSystem @Override void resetPassword(String emailAddress); @Transactional(readOnly = true) @RunAsSystem @Override void validatePasswordResetToken(String username, String token); @Transactional @RunAsSystem @Override void changePassword(String username, String token, String password); @Transactional @Override void changePasswordAuthenticatedUser(String password); }
PasswordResetterImpl implements PasswordResetter { @Transactional @RunAsSystem @Override public void resetPassword(String emailAddress) { User user = getUserByEmail(emailAddress); String token = passwordResetTokenService.createToken(user); sendPasswordResetMail(user, token); } PasswordResetterImpl(
      PasswordResetTokenRepository passwordResetTokenRepository,
      UserService userService,
      MailSender mailSender,
      AppSettings appSettings); @Transactional @RunAsSystem @Override void resetPassword(String emailAddress); @Transactional(readOnly = true) @RunAsSystem @Override void validatePasswordResetToken(String username, String token); @Transactional @RunAsSystem @Override void changePassword(String username, String token, String password); @Transactional @Override void changePasswordAuthenticatedUser(String password);  }