<commit_before>require "test_helper"

class ConsultationsControllerTest < ActionController::TestCase
  should_be_a_public_facing_controller

  test 'index redirects to the publications index filtering consultations, retaining any other filter params' do
    get :index, params: { topics: ["a-topic-slug"], departments: ['an-org-slug'] }
    assert_redirected_to publications_path(publication_filter_option: Whitehall::PublicationFilterOption::Consultation.slug, topics: ["a-topic-slug"], departments: ['an-org-slug'])
  end
end<commit_msg>Fix consultations  controller test<commit_after>require "test_helper"

class ConsultationsControllerTest < ActionController::TestCase
  should_be_a_public_facing_controller

  test 'index redirects to the publications index filtering consultations, retaining any other filter params' do
    get :index, params: { topics: ["a-topic-slug"], departments: ['an-org-slug'] }
    assert_redirected_to(
      "http://test.host/government/publications.departments%255B%255D=an-org-slug&publication_filter_option=consultations&topics%255B%255D=a-topic-slug"
    )
  end
end
{'fraction_non_alphanumeric': 0.09972801450589303, 'fraction_numerical': 0.010879419764279238, 'mean_word_length': 6.666666666666667, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7143398', 'n_tokens_mistral': 330, 'n_tokens_neox': 317, 'n_words': 71}