summaryrefslogtreecommitdiff
path: root/spec/features/snippets
diff options
context:
space:
mode:
authorMarkus Koller <mkoller@gitlab.com>2019-08-30 09:49:14 +0000
committerLin Jen-Shin <godfat@godfat.org>2019-08-30 09:49:14 +0000
commit1bccd36f04f1e1c4efe9155ea9037910c42a3749 (patch)
tree5fa93f57ef35c07ee4cd9c15480404d15f0c47b3 /spec/features/snippets
parentb76bc2762a245c61089fae486e61c9fd83d45f95 (diff)
downloadgitlab-ce-1bccd36f04f1e1c4efe9155ea9037910c42a3749.tar.gz
Improve search result labels
- Use "results" instead of "blobs", "wiki blobs", "snippet blobs" - Use "comments" instead of "notes" - Use correct pluralization - Don't add "1 - 10 of" if there's only one page
Diffstat (limited to 'spec/features/snippets')
-rw-r--r--spec/features/snippets/search_snippets_spec.rb14
1 files changed, 3 insertions, 11 deletions
diff --git a/spec/features/snippets/search_snippets_spec.rb b/spec/features/snippets/search_snippets_spec.rb
index 4a8c5f9b1fe..bbdf544bd0c 100644
--- a/spec/features/snippets/search_snippets_spec.rb
+++ b/spec/features/snippets/search_snippets_spec.rb
@@ -10,12 +10,8 @@ describe 'Search Snippets' do
sign_in private_snippet.author
visit dashboard_snippets_path
- page.within '.search' do
- fill_in 'search', with: 'Middle'
- click_button 'Go'
- end
-
- click_link 'Titles and Filenames'
+ submit_search('Middle')
+ select_search_scope('Titles and Filenames')
expect(page).to have_link(public_snippet.title)
expect(page).to have_link(private_snippet.title)
@@ -45,11 +41,7 @@ describe 'Search Snippets' do
sign_in create(:user)
visit dashboard_snippets_path
-
- page.within '.search' do
- fill_in 'search', with: 'line seven'
- click_button 'Go'
- end
+ submit_search('line seven')
expect(page).to have_content('line seven')