Skip to content

Commit

Permalink
Extend 'user' spec factory with 'tijuana_user_with_everything'
Browse files Browse the repository at this point in the history
  • Loading branch information
ivanb777 committed Dec 5, 2024
1 parent 53b5e6c commit ec9a97a
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions spec/test_identity_app/spec/factories/tijuana/user.rb
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,29 @@ module IdentityTijuana
suburb { Faker::Address.city }
postcode { IdentityTijuana::Postcode.new(number: Faker::Address.zip_code, state: Faker::Address.state_abbr) }
end

factory :tijuana_user_with_everything do
home_number { "612#{::Kernel.rand(10_000_000..99_999_999)}" }
mobile_number { "614#{::Kernel.rand(10_000_000..99_999_999)}" }
street_address { Faker::Address.street_address }
suburb { Faker::Address.city }
postcode { IdentityTijuana::Postcode.new(number: Faker::Address.zip_code, state: Faker::Address.state_abbr) }
country_iso { Faker::Address.country_code }
encrypted_password { Faker::Internet.password }
password_salt { Faker::Crypto.md5 }
reset_password_token { Faker::Crypto.md5 }
reset_password_sent_at { 20.days.ago }
remember_created_at { 2.hours.ago }
current_sign_in_at { 1.hours.ago }
last_sign_in_at { 10.days.ago }
last_sign_in_ip { Faker::Internet.ip_v4_address }
random { rand(0.0..0.001) }
notes { Faker::Lorem.paragraph }
quick_donate_trigger_id { Faker::Alphanumeric.alphanumeric(number: 12) }
facebook_id { Faker::Alphanumeric.alphanumeric(number: 12) }
otp_secret_key { Faker::Alphanumeric.alphanumeric(number: 32) }
tracking_token { Faker::Alphanumeric.alphanumeric(number: 8) }
end
end
end
end

0 comments on commit ec9a97a

Please sign in to comment.