Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorValery Sizov <vsv2711@gmail.com>2015-08-13 17:48:21 +0300
committerValery Sizov <vsv2711@gmail.com>2015-08-24 13:59:01 +0300
commit56527b63e8a09e0fe4967eabf08638d853e6b2b5 (patch)
tree0ee484fe1bb0dbdae4333e30ad7c3c36251c1bcf /features
parent24b282aeeaf5ba41c6b73100051eb48428787770 (diff)
Ability to search milestones
Diffstat (limited to 'features')
-rw-r--r--features/search.feature15
-rw-r--r--features/steps/search.rb11
2 files changed, 26 insertions, 0 deletions
diff --git a/features/search.feature b/features/search.feature
index 1608e824671..a9234c1a611 100644
--- a/features/search.feature
+++ b/features/search.feature
@@ -23,6 +23,13 @@ Feature: Search
Then I should see "Foo" link in the search results
And I should not see "Bar" link in the search results
+ Scenario: I should see milestones I am looking for
+ And project has milestones
+ When I search for "Foo"
+ When I click "Milestones" link
+ Then I should see "Foo" link in the search results
+ And I should not see "Bar" link in the search results
+
Scenario: I should see project code I am looking for
When I click project "Shop" link
And I search for "rspec"
@@ -44,6 +51,14 @@ Feature: Search
Then I should see "Foo" link in the search results
And I should not see "Bar" link in the search results
+ Scenario: I should see project milestones
+ And project has milestones
+ When I click project "Shop" link
+ And I search for "Foo"
+ And I click "Milestones" link
+ Then I should see "Foo" link in the search results
+ And I should not see "Bar" link in the search results
+
Scenario: I should see Wiki blobs
And project has Wiki content
When I click project "Shop" link
diff --git a/features/steps/search.rb b/features/steps/search.rb
index 87893aa0205..79273cbad9a 100644
--- a/features/steps/search.rb
+++ b/features/steps/search.rb
@@ -41,6 +41,12 @@ class Spinach::Features::Search < Spinach::FeatureSteps
end
end
+ step 'I click "Milestones" link' do
+ page.within '.search-filter' do
+ click_link 'Milestones'
+ end
+ end
+
step 'I click "Wiki" link' do
page.within '.search-filter' do
click_link 'Wiki'
@@ -72,6 +78,11 @@ class Spinach::Features::Search < Spinach::FeatureSteps
create(:merge_request, :simple, title: "Bar", source_project: project, target_project: project)
end
+ step 'project has milestones' do
+ create(:milestone, title: "Foo", project: project)
+ create(:milestone, title: "Bar", project: project)
+ end
+
step 'I should see "Foo" link in the search results' do
page.within('.results') do
find(:css, '.search-results').should have_link 'Foo'