diff --git a/app/presenters/content_item/news_image.rb b/app/presenters/content_item/news_image.rb index 237330f33..0a49663a5 100644 --- a/app/presenters/content_item/news_image.rb +++ b/app/presenters/content_item/news_image.rb @@ -12,7 +12,7 @@ def default_news_image end def placeholder_image - "https://assets.publishing.service.gov.uk/government/assets/placeholder.jpg" + { "url" => "https://assets.publishing.service.gov.uk/government/assets/placeholder.jpg" } end end end diff --git a/test/presenters/content_item/news_image_test.rb b/test/presenters/content_item/news_image_test.rb index 76fdd105f..98efa8e99 100644 --- a/test/presenters/content_item/news_image_test.rb +++ b/test/presenters/content_item/news_image_test.rb @@ -34,7 +34,7 @@ def initialize test "presents a placeholder image if document has no image or default news image" do item = DummyContentItem.new - placeholder_image = "https://assets.publishing.service.gov.uk/government/assets/placeholder.jpg" + placeholder_image = { "url" => "https://assets.publishing.service.gov.uk/government/assets/placeholder.jpg" } assert_equal placeholder_image, item.image end