diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2012-11-07 03:51:20 -0800 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2012-11-07 03:51:20 -0800 |
commit | 8114d36cafa2bf0b51a337f900eee0d7ad7a84d6 (patch) | |
tree | dacf5ab28b00486336c2b5d6ad19fda86dfd0e3a /features | |
parent | d6a5e3dad7a8d5aa1eb2220c2c60f068455dbaed (diff) | |
parent | e6524a919ee4c92d82518c2520d5c0cabc32eb47 (diff) | |
download | gitlab-ce-8114d36cafa2bf0b51a337f900eee0d7ad7a84d6.tar.gz |
Merge pull request #1720 from coagulant/wiki_search
Wiki search
Diffstat (limited to 'features')
-rw-r--r-- | features/dashboard/search.feature | 5 | ||||
-rw-r--r-- | features/steps/dashboard/dashboard_search.rb | 17 |
2 files changed, 22 insertions, 0 deletions
diff --git a/features/dashboard/search.feature b/features/dashboard/search.feature index 91d870f46f3..9813d9d1e7c 100644 --- a/features/dashboard/search.feature +++ b/features/dashboard/search.feature @@ -2,8 +2,13 @@ Feature: Dashboard Search Background: Given I sign in as a user And I own project "Shop" + And Project "Shop" has wiki page "Contibuting guide" And I visit dashboard search page Scenario: I should see project I am looking for Given I search for "Sho" Then I should see "Shop" project link + + Scenario: I should see wiki page I am looking for + Given I search for "Contibuting" + Then I should see "Contibuting guide" wiki link
\ No newline at end of file diff --git a/features/steps/dashboard/dashboard_search.rb b/features/steps/dashboard/dashboard_search.rb index e35858985d6..e902e40456f 100644 --- a/features/steps/dashboard/dashboard_search.rb +++ b/features/steps/dashboard/dashboard_search.rb @@ -15,4 +15,21 @@ class DashboardSearch < Spinach::FeatureSteps @project = Factory :project, :name => "Shop" @project.add_access(@user, :admin) end + + Given 'I search for "Contibuting"' do + fill_in "dashboard_search", :with => "Contibuting" + click_button "Search" + end + + And 'Project "Shop" has wiki page "Contibuting guide"' do + @wiki_page = Factory :wiki, :project => @project, + :title => "Contibuting guide", + :slug => "contributing" + end + + Then 'I should see "Contibuting guide" wiki link' do + page.should have_link "Contibuting guide" + end + + end |