Skip to content

Commit

Permalink
Remove case study from canonicalisation test
Browse files Browse the repository at this point in the history
* This logic doesn’t need to be handled by Whitehall
* Note: government-frontend doesn’t do this redirect:
https://www.gov.uk/government/case-studies/bis-criminal-prosecutions?loc
ale=en
  • Loading branch information
fofr committed Jul 7, 2017
1 parent 3160bb7 commit 5759472
Showing 1 changed file with 1 addition and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,7 @@ def with_locale_param(path, locale)
u.to_s
end

document_types_with_no_index = %w(case_study)
normal_document_types = [
"world_location_news_article",
"publication",
"consultation",
]

(document_types_with_no_index + normal_document_types).each do |doc_type|
%w{world_location_news_article publication consultation}.each do |doc_type|
test "visiting a #{doc_type} with a spurious locale=en param will redirect to remove it" do
canonical_path = send("#{doc_type}_path", "a-#{doc_type}")
extra_path = with_locale_param(canonical_path, 'en')
Expand Down

0 comments on commit 5759472

Please sign in to comment.