This commits sets the ground work to allow Bento
to support users that belongs to more then one
account.
It does this by shifting the database from using
a simple belongs to relation and instead sets up
a memberships join table. This allows users to
have many accounts through memberships.
This commit doesn't really add any new features
but rather changed the underlaying structure. To
make all the test pass it adds a account accessor
to the user model. This allows you to work with
users and accounts as if it was a simple belongs to
relations.
The recommended aprotch is to use the generated
migrations as they are. And keep the accesor if
you want to simplfy the user-account interaction.
In that way no database migrations is needed when
you decide that you need users that belongs to
several accounts.
The next few commits aims to add features that
depends on the fact that users can have several
accounts. At that point it might be that gem users
that decide to run without the has_many :through
setup won't be compatible with the bento code base
at all. In that case you shouln't use Bento for
more then a simple scaffold generator if you can't
live with the fact that a join table are being used
for the user-account associations.