Refactors referral controller, adds affiliated user spec, adds affiliate action for referral controller spec, updates rspec to 2.3, adds affiliate_record to User