FactoryGirl.define do factory :user do sequence(:name) { |n| "name#{n}" } sequence(:email) {|e| "email#{e}"} end end