Created
October 20, 2014 13:24
-
-
Save biscuitvile/c93eb90fcf69ccaeef42 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| it "encrypts a password before save when a password is set" do | |
| account.password = 'password' | |
| mock(PasswordEncryptor).new(account) do | |
| mock!.assign_encrypted_password(account.subdomain).subject | |
| end | |
| account.save | |
| end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment