Sha256: 42cf5f43330578e004675c52ea07e4ffee1343406a02999f5ad75aafbae77193
Contents?: true
Size: 1.03 KB
Versions: 22
Compression:
Stored size: 1.03 KB
Contents
# frozen_string_literal: true FactoryGirl.define do factory :meeting, class: Decidim::Meetings::Meeting do title { Decidim::Faker::Localized.sentence(3) } description { Decidim::Faker::Localized.wrapped("<p>", "</p>") { Decidim::Faker::Localized.sentence(4) } } location { Decidim::Faker::Localized.wrapped("<p>", "</p>") { Decidim::Faker::Localized.sentence(4) } } location_hints { Decidim::Faker::Localized.wrapped("<p>", "</p>") { Decidim::Faker::Localized.sentence(4) } } address { Faker::Lorem.sentence(3) } latitude { Faker::Address.latitude } longitude { Faker::Address.longitude } start_time { 1.day.from_now } end_time { start_time.advance(hours: 2) } feature { build(:feature, manifest_name: "meetings") } trait :closed do closing_report { Decidim::Faker::Localized.sentence(3) } attendees_count { rand(50) } contributions_count { rand(50) } attending_organizations { Array.new(3) { Faker::GameOfThrones.house }.join(", ") } closed_at { Time.current } end end end
Version data entries
22 entries across 22 versions & 2 rubygems
Version | Path |
---|---|
decidim-meetings-0.2.0 | lib/decidim/meetings/test/factories.rb |
decidim-0.2.0 | decidim-meetings/lib/decidim/meetings/test/factories.rb |