RailsCasts Pro episodes are now free!
Learn more or hide this
GitHub User: xlprojects
Site: www.xlprojects.com
Hey everyone,
I've implemented a way to change the password (not reset the password) see here.
However I have trouble hooking up rspec tests for this bit of code... If anyone can help me out...
Here is how:
def update_password(current_password, new_password, new_password_confirmation) if new_password == new_password_confirmation if !User.authenticate(self.username, current_password).nil? return self.change_password!(new_password) else return false end else return false end end
Same here, any luck solving the issue?
Hey everyone,
I've implemented a way to change the password (not reset the password) see here.
However I have trouble hooking up rspec tests for this bit of code... If anyone can help me out...
Here is how:
Same here, any luck solving the issue?