FactoryGirl.define do
  factory :user do
    confirmed_at Time.now
    name 'Test User'
    sequence(:email) { |n| "test#{n}@example.com" }
    password 'password'
    sequence(:soft_token) { |n| "soft_token#{n}" }

    trait :admin do
      role 'admin'
    end
  end
end
