summaryrefslogtreecommitdiff
path: root/features/steps/search.rb
diff options
context:
space:
mode:
Diffstat (limited to 'features/steps/search.rb')
-rw-r--r--features/steps/search.rb20
1 files changed, 20 insertions, 0 deletions
diff --git a/features/steps/search.rb b/features/steps/search.rb
index 6f0e038c4d6..8197cd410aa 100644
--- a/features/steps/search.rb
+++ b/features/steps/search.rb
@@ -18,6 +18,11 @@ class Spinach::Features::Search < Spinach::FeatureSteps
click_button "Search"
end
+ step 'I search for "Wiki content"' do
+ fill_in "dashboard_search", with: "content"
+ click_button "Search"
+ end
+
step 'I click "Issues" link' do
within '.search-filter' do
click_link 'Issues'
@@ -36,6 +41,12 @@ class Spinach::Features::Search < Spinach::FeatureSteps
end
end
+ step 'I click "Wiki" link' do
+ within '.search-filter' do
+ click_link 'Wiki'
+ end
+ end
+
step 'I should see "Shop" project link' do
page.should have_link "Shop"
end
@@ -66,4 +77,13 @@ class Spinach::Features::Search < Spinach::FeatureSteps
step 'I should not see "Bar" link in the search results' do
find(:css, '.search-results').should_not have_link 'Bar'
end
+
+ step 'I should see "test_wiki" link in the search results' do
+ find(:css, '.search-results').should have_link 'test_wiki.md'
+ end
+
+ step 'project has Wiki content' do
+ @wiki = ::ProjectWiki.new(project, current_user)
+ @wiki.create_page("test_wiki", "Some Wiki content", :markdown, "first commit")
+ end
end