update tests and code for reset password