diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2023-06-16 12:09:20 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2023-06-16 12:09:20 +0300 |
commit | 8ae36d93f1a63874b584f0488fde88c1fee999c4 (patch) | |
tree | f1788ba1a7fb00248ff008f817f6feea89304339 /spec/controllers | |
parent | b394e58cc2e52e17e7991e3d7b705aa383c362ee (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/controllers')
-rw-r--r-- | spec/controllers/search_controller_spec.rb | 6 |
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 |