Skip to content

Commit

Permalink
Merge pull request #9583 from alphagov/content-modelling/676-fix-link…
Browse files Browse the repository at this point in the history
…-to-frontend

fix link to frontend for live host documents
  • Loading branch information
Harriethw authored Nov 5, 2024
2 parents 49c1491 + ece220a commit 236056e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ def frontend_path(content_item)
if @is_preview
Plek.external_url_for("draft-origin") + content_item.base_path
else
Plek.external_url_for("government-frontend") + content_item.base_path
Plek.website_root + content_item.base_path
end
end

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def self.it_returns_unknown_user

assert_selector ".govuk-link" do |link|
assert_equal "#{host_content_item.title} (opens in new tab)", link.text
assert_equal Plek.external_url_for("government-frontend") + host_content_item.base_path, link[:href]
assert_equal Plek.website_root + host_content_item.base_path, link[:href]
assert_equal "noopener", link[:rel]
assert_equal "_blank", link[:target]
end
Expand Down

0 comments on commit 236056e

Please sign in to comment.