diff options
author | Lin Jen-Shin <godfat@godfat.org> | 2016-11-08 23:52:17 +0800 |
---|---|---|
committer | Lin Jen-Shin <godfat@godfat.org> | 2016-11-08 23:52:17 +0800 |
commit | 3744d629e894afa3cb54c7edd2b61e0f17deb34f (patch) | |
tree | 50bcc4cc425b0cdfff9c220418caf2ccf2a59239 /spec/features/search_spec.rb | |
parent | d03615736f29cb791db6e98ad658a532d6c8d271 (diff) | |
parent | 0108387053ac78bb2354511950fb5847a033e5d5 (diff) | |
download | gitlab-ce-3744d629e894afa3cb54c7edd2b61e0f17deb34f.tar.gz |
Merge remote-tracking branch 'upstream/master' into pipeline-notifications
* upstream/master: (70 commits)
Fix routing spec for group controller
Add small improvements to constrainers and specs
Faster search
Fix broken commits search
Changed helper method to check for none on params Moved if statements around in view
API: Return 400 when creating a systemhook fails
Update non-exist group spinach test to match routing
Bump omniauth-gitlab to 1.0.2 to fix incompatibility with omniauth-oauth2
Replace trigger with the new ID of the docs project
Refactor method name
17492 Update link color for more accessible contrast
Fixed todos empty state when filtering
Refactor namespace regex
implements reset incoming email token on issues modal and account page, reactivates all tests and writes more tests for it
Use separate email-friendly token for incoming email and let incoming email token be reset
Use the Gitlab Workhorse HTTP header in the admin dashboard
Refactor project routing
Fix 404 when visit /projects page
Rewritten spinach git_blame tests to rspec feature tests
Add tests for project#index routing
...
Diffstat (limited to 'spec/features/search_spec.rb')
-rw-r--r-- | spec/features/search_spec.rb | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/spec/features/search_spec.rb b/spec/features/search_spec.rb index 1806200c82c..caecd027aaa 100644 --- a/spec/features/search_spec.rb +++ b/spec/features/search_spec.rb @@ -100,6 +100,32 @@ describe "Search", feature: true do expect(page).to have_link(snippet.title) end + + it 'finds a commit' do + visit namespace_project_path(project.namespace, project) + + page.within '.search' do + fill_in 'search', with: 'add' + click_button 'Go' + end + + click_link "Commits" + + expect(page).to have_selector('.commit-row-description') + end + + it 'finds a code' do + visit namespace_project_path(project.namespace, project) + + page.within '.search' do + fill_in 'search', with: 'def' + click_button 'Go' + end + + click_link "Code" + + expect(page).to have_selector('.file-content .code') + end end describe 'Right header search field', feature: true do |