create migration for purposes table
run pending migrations
create spec for purpose model
create purpose model
create purpose factory
expect entrances to have a valid purpose
an entrance belong to a purpose
declare belongs_to association in entrances tableg
expect entrances api to adapt to new association
define entrance-purpose association in entrance factory
permit purpose_id entrance parameter
run pending migratiojs
expect a purpose without description to be invalid
make purpose model to validate its description presence
create expect for purposes api
define routes and actions for purposes api
create shared examples for crud api
refactor api specs to use the crud examples
add post_params callback to crud examples
merge passwords into user params right before a POST request