mirror of
https://github.com/discourse/discourse.git
synced 2026-03-05 15:27:34 +08:00
### Before <img width="1079" height="981" alt="Screenshot 2025-08-27 at 12 20 30 PM" src="https://github.com/user-attachments/assets/8b38ef86-e602-440f-8d59-321af1677c95" /> ### After <img width="1106" height="1059" alt="Screenshot 2025-08-27 at 12 20 01 PM" src="https://github.com/user-attachments/assets/1f9e3c61-5a17-4067-ad67-2c9a2e1ba382" />
20 lines
474 B
Ruby
20 lines
474 B
Ruby
# frozen_string_literal: true
|
|
|
|
RSpec.describe Admin::SearchController do
|
|
fab!(:admin)
|
|
|
|
before { sign_in(admin) }
|
|
|
|
describe "#index" do
|
|
it "includes default_locale setting in search results for general searches" do
|
|
get "/admin/search/all.json"
|
|
|
|
expect(response.status).to eq(200)
|
|
|
|
locale_setting =
|
|
response.parsed_body["settings"].find { |s| s["setting"] == "default_locale" }
|
|
|
|
expect(locale_setting).to be_present
|
|
end
|
|
end
|
|
end
|