Files
grecia/db/dev_seeds/legislation_proposals.rb
taitus 76837919b8 Remove redundant .all in .all.sample calls
Rubocop doesn't detect this method because we've added it in the
ApplicationRecord class, but we're removing the `.all` calls for
consistency.
2023-11-20 14:23:41 +01:00

12 lines
557 B
Ruby

section "Creating legislation proposals" do
10.times do
Legislation::Proposal.create!(title: Faker::Lorem.sentence(word_count: 3).truncate(60),
description: Faker::Lorem.paragraphs.join("\n\n"),
summary: Faker::Lorem.paragraph,
author: User.sample,
process: Legislation::Process.sample,
terms_of_service: "1",
selected: rand <= 1.0 / 3)
end
end