summaryrefslogtreecommitdiff
path: root/users/test/unit/account_test.rb
AgeCommit message (Collapse)Author
2014-04-08moving users: app and test filesAzul
2013-11-05Identity.destroy_all_disabled will clean up disabled identitiesAzul
This is mostly for cleaning up after tests so far. But we might expand this to destroy all identities disabled before a certain date.
2013-11-05disabled identities to block handles after a user was deletedAzul
2013-09-18user.account shortcut to Account.new(user)Azul
2013-09-03Account: Composition to handle User and its identitiesAzul
We have a lot of things that act upon a user record and one or more of it's identities at the same time: * Sing up: Create a user and it's initial identity * Rename: Change the username and create a new identity, turn old into an alias * Cancel Account: Remove user and all their identities. In order to keep the User and Identity behaviour isolated but still have a this logic represented in a sinle place the Account model deals with all these things. We could have overwritten the User#create, User#update and User#destroy methods instead. But then we would always create identities, even if we only need a user (for example in tests).