Sha256: f7f72b94f85a8d3d69c8195f3ef56bb3502923a689ab15b92717e220d0c0ccb2

Contents?: true

Size: 349 Bytes

Versions: 27

Compression:

Stored size: 349 Bytes

Contents

FactoryBot.define do
  factory :expense_gun_expense, class: ::Dorsale::ExpenseGun::Expense do
    name { Faker::Lorem.sentence(3) }
    date { Date.current             }
    user { create(:user)            }

    after(:create) { |expense|
      rand(2..5).times {
        create(:expense_gun_expense_line, expense: expense)
      }
    }
  end
end

Version data entries

27 entries across 27 versions & 1 rubygems

Version Path
dorsale-3.9.6 spec/factories/expense_gun_expenses.rb
dorsale-3.9.5 spec/factories/expense_gun_expenses.rb
dorsale-3.9.4 spec/factories/expense_gun_expenses.rb
dorsale-3.9.3 spec/factories/expense_gun_expenses.rb
dorsale-3.9.2 spec/factories/expense_gun_expenses.rb
dorsale-3.9.1 spec/factories/expense_gun_expenses.rb
dorsale-3.9.0 spec/factories/expense_gun_expenses.rb