summaryrefslogtreecommitdiff
path: root/spec/factories
diff options
context:
space:
mode:
Diffstat (limited to 'spec/factories')
-rw-r--r--spec/factories/address.rb11
1 files changed, 11 insertions, 0 deletions
diff --git a/spec/factories/address.rb b/spec/factories/address.rb
new file mode 100644
index 0000000..c5c7170
--- /dev/null
+++ b/spec/factories/address.rb
@@ -0,0 +1,11 @@
+# frozen_string_literal: true
+
+FactoryBot.define do
+ factory :address, class: 'Address' do
+ number { Faker::Address.building_number.to_i }
+ street { Faker::Address.street_name }
+ zip_code { Faker::Address.zip_code }
+ country { ISO3166::Country.codes.sample }
+ city { Faker::Address.city }
+ end
+end