lib/decidim/conferences/participatory_space.rb in decidim-conferences-0.26.10 vs lib/decidim/conferences/participatory_space.rb in decidim-conferences-0.27.0.rc1

- old
+ new

@@ -62,17 +62,17 @@ end, description: Decidim::Faker::Localized.wrapped("<p>", "</p>") do Decidim::Faker::Localized.paragraph(sentence_count: 3) end, organization: organization, - hero_image: ActiveStorage::Blob.create_after_upload!( + hero_image: ActiveStorage::Blob.create_and_upload!( io: File.open(File.join(seeds_root, "city.jpeg")), filename: "hero_image.jpeg", content_type: "image/jpeg", metadata: nil ), # Keep after organization - banner_image: ActiveStorage::Blob.create_after_upload!( + banner_image: ActiveStorage::Blob.create_and_upload!( io: File.open(File.join(seeds_root, "city2.jpeg")), filename: "banner_image.jpeg", content_type: "image/jpeg", metadata: nil ), # Keep after organization @@ -97,12 +97,12 @@ user = Decidim::User.find_or_initialize_by(email: email) user.update!( name: Faker::Name.name, nickname: Faker::Twitter.unique.screen_name, - password: "decidim123456", - password_confirmation: "decidim123456", + password: "decidim123456789", + password_confirmation: "decidim123456789", organization: organization, confirmed_at: Time.current, locale: I18n.default_locale, tos_agreement: true ) @@ -124,11 +124,11 @@ title: Decidim::Faker::Localized.sentence(word_count: 2), description: Decidim::Faker::Localized.sentence(word_count: 5), attachment_collection: attachment_collection, attached_to: conference, content_type: "application/pdf", - file: ActiveStorage::Blob.create_after_upload!( + file: ActiveStorage::Blob.create_and_upload!( io: File.open(File.join(seeds_root, "Exampledocument.pdf")), filename: "Exampledocument.pdf", content_type: "application/pdf", metadata: nil ) # Keep after attached_to @@ -137,11 +137,11 @@ Decidim::Attachment.create!( title: Decidim::Faker::Localized.sentence(word_count: 2), description: Decidim::Faker::Localized.sentence(word_count: 5), attached_to: conference, content_type: "image/jpeg", - file: ActiveStorage::Blob.create_after_upload!( + file: ActiveStorage::Blob.create_and_upload!( io: File.open(File.join(seeds_root, "city.jpeg")), filename: "city.jpeg", content_type: "image/jpeg", metadata: nil ) # Keep after attached_to @@ -150,11 +150,11 @@ Decidim::Attachment.create!( title: Decidim::Faker::Localized.sentence(word_count: 2), description: Decidim::Faker::Localized.sentence(word_count: 5), attached_to: conference, content_type: "application/pdf", - file: ActiveStorage::Blob.create_after_upload!( + file: ActiveStorage::Blob.create_and_upload!( io: File.open(File.join(seeds_root, "Exampledocument.pdf")), filename: "Exampledocument.pdf", content_type: "application/pdf", metadata: nil ) # Keep after attached_to @@ -191,10 +191,10 @@ name: Faker::Name.name, weight: Faker::Number.between(from: 1, to: 10), link: Faker::Internet.url, partner_type: type, conference: conference, - logo: ActiveStorage::Blob.create_after_upload!( + logo: ActiveStorage::Blob.create_and_upload!( io: File.open(File.join(seeds_root, "logo.png")), filename: "logo.png", content_type: "image/png", metadata: nil ) # Keep after conference