Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2023-06-16 12:09:20 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2023-06-16 12:09:20 +0300
commit8ae36d93f1a63874b584f0488fde88c1fee999c4 (patch)
treef1788ba1a7fb00248ff008f817f6feea89304339 /spec/controllers
parentb394e58cc2e52e17e7991e3d7b705aa383c362ee (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/controllers')
-rw-r--r--spec/controllers/search_controller_spec.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/spec/controllers/search_controller_spec.rb b/spec/controllers/search_controller_spec.rb
index 7fce39950e5..9e69566d18f 100644
--- a/spec/controllers/search_controller_spec.rb
+++ b/spec/controllers/search_controller_spec.rb
@@ -477,6 +477,12 @@ RSpec.describe SearchController, feature_category: :global_search do
expect(json_response.first['label']).to match(/User settings/)
end
+ it 'can be scoped with params[:scope]' do
+ expect(controller).to receive(:search_autocomplete_opts).with('setting', filter: nil, scope: 'project')
+
+ get :autocomplete, params: { term: 'setting', scope: 'project' }
+ end
+
it 'makes a call to search_autocomplete_opts' do
expect(controller).to receive(:search_autocomplete_opts).once