metamaps--metamaps/spec/factories/users.rb

13 lines
339 B
Ruby
Raw Normal View History

2015-10-19 07:23:49 +00:00
FactoryGirl.define do
factory :user do
name { random_string(10) }
email { random_string(10) + '@' + random_string(10) + '.com' }
code { random_string(8) }
joinedwithcode { code }
2015-10-19 07:23:49 +00:00
password 'omgwtfbbq'
2015-12-16 14:33:29 +00:00
# bypass validation of the joinedwithcode
to_create { |instance| instance.save(validate: false) }
2015-10-19 07:23:49 +00:00
end
end