From 243147833acff0e7d6e49b86de81e36837a176ea Mon Sep 17 00:00:00 2001 From: HombreLaser Date: Wed, 22 Mar 2023 20:24:50 -0600 Subject: AƱade factory de Address MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- spec/factories/address.rb | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 spec/factories/address.rb 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 -- cgit v1.2.3