diff --git a/app/views/decidim/conferences/conferences/show.html.erb b/app/views/decidim/conferences/conferences/show.html.erb index f228280..bfcb920 100644 --- a/app/views/decidim/conferences/conferences/show.html.erb +++ b/app/views/decidim/conferences/conferences/show.html.erb @@ -20,12 +20,12 @@ edit_link(

<%= t("conferences.show.introduction", scope: "decidim") %>

- <%= decidim_sanitize translated_attribute(current_participatory_space.short_description) %> + <%= decidim_sanitize_editor_admin translated_attribute(current_participatory_space.short_description) %>

<%= t("conferences.show.details", scope: "decidim") %>

- <%= decidim_sanitize translated_attribute(current_participatory_space.description) %> + <%= decidim_sanitize_editor_admin translated_attribute(current_participatory_space.description) %>
<% if current_participatory_space.registrations_enabled? %> diff --git a/spec/factories.rb b/spec/factories.rb index 66c8dbf..df5f116 100644 --- a/spec/factories.rb +++ b/spec/factories.rb @@ -3,3 +3,4 @@ require "decidim/core/test/factories" require "decidim/proposals/test/factories" require "decidim/decidim_awesome/test/factories" +require "decidim/conferences/test/factories" diff --git a/spec/system/conferences_with_image_spec.rb b/spec/system/conferences_with_image_spec.rb new file mode 100644 index 0000000..3820fe5 --- /dev/null +++ b/spec/system/conferences_with_image_spec.rb @@ -0,0 +1,20 @@ +# frozen_string_literal: true + +require "rails_helper" + +describe "Conference with images", type: :system do + let(:organization) { create :organization } + let(:short_description) { { en: "

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.

" } } + let!(:conference) { create :conference, organization: organization, short_description: short_description } + + before do + switch_to_host(organization.host) + page.visit "/conferences/#{conference.slug}" + end + + it "shows the image" do + within "#content" do + expect(page).to have_xpath("//img[contains(@src,'favicon.ico')]") + end + end +end