summaryrefslogtreecommitdiff
path: root/features
diff options
context:
space:
mode:
authorAnnabel Dunstone Gray <annabel.dunstone@gmail.com>2017-05-12 21:35:15 +0000
committerAnnabel Dunstone Gray <annabel.dunstone@gmail.com>2017-05-12 21:35:15 +0000
commitd63de44d26f1b50e62d25c6db8f3a63d98f13d45 (patch)
tree6388ced3ae488e9ba4342cad501488a6a16671f8 /features
parent09ca4c92d2c6991e0b6e58894bd381758bcfd0da (diff)
parentc757000e83f57eb9e71dbf5505a3b1cd21bd8105 (diff)
downloadgitlab-ce-d63de44d26f1b50e62d25c6db8f3a63d98f13d45.tar.gz
Merge branch '30975-fixed-top-nav-POC' into 'master'
Add fixed positioning to top level navbar Closes #30975 See merge request !10751
Diffstat (limited to 'features')
-rw-r--r--features/search.feature4
-rw-r--r--features/steps/dashboard/todos.rb6
-rw-r--r--features/steps/project/merge_requests.rb4
-rw-r--r--features/steps/search.rb8
4 files changed, 13 insertions, 9 deletions
diff --git a/features/search.feature b/features/search.feature
index 818ef436db6..f894b6b84a1 100644
--- a/features/search.feature
+++ b/features/search.feature
@@ -9,6 +9,7 @@ Feature: Search
Given I search for "Sho"
Then I should see "Shop" project link
+ @javascript
Scenario: I should see issues I am looking for
And project has issues
When I search for "Foo"
@@ -16,6 +17,7 @@ Feature: Search
Then I should see "Foo" link in the search results
And I should not see "Bar" link in the search results
+ @javascript
Scenario: I should see merge requests I am looking for
And project has merge requests
When I search for "Foo"
@@ -23,6 +25,7 @@ Feature: Search
Then I should see "Foo" link in the search results
And I should not see "Bar" link in the search results
+ @javascript
Scenario: I should see milestones I am looking for
And project has milestones
When I search for "Foo"
@@ -78,6 +81,7 @@ Feature: Search
And I search for "Sho"
Then I should see "Shop" project link
+ @javascript
Scenario: I logout and should see issues I am looking for
Given project "Shop" is public
And I logout directly
diff --git a/features/steps/dashboard/todos.rb b/features/steps/dashboard/todos.rb
index b56558ba0d2..14c13c4818a 100644
--- a/features/steps/dashboard/todos.rb
+++ b/features/steps/dashboard/todos.rb
@@ -55,7 +55,7 @@ class Spinach::Features::DashboardTodos < Spinach::FeatureSteps
merge_request_reference = merge_request.to_reference(full: true)
issue_reference = issue.to_reference(full: true)
- click_link 'Mark all as done'
+ find('.js-todos-mark-all').trigger('click')
page.within('.todos-count') { expect(page).to have_content '0' }
expect(page).to have_content 'To do 0'
@@ -69,7 +69,7 @@ class Spinach::Features::DashboardTodos < Spinach::FeatureSteps
end
step 'I should see the todo marked as done' do
- click_link 'Done 1'
+ find('.todos-done a').trigger('click')
expect(page).to have_link project.name_with_namespace
should_see_todo(1, "John Doe assigned you merge request #{merge_request.to_reference(full: true)}", merge_request.title, state: :done_irreversible)
@@ -79,7 +79,7 @@ class Spinach::Features::DashboardTodos < Spinach::FeatureSteps
merge_request_reference = merge_request.to_reference(full: true)
issue_reference = issue.to_reference(full: true)
- click_link 'Done 4'
+ find('.todos-done a').trigger('click')
expect(page).to have_link project.name_with_namespace
should_see_todo(1, "John Doe assigned you merge request #{merge_request_reference}", merge_request.title, state: :done_irreversible)
diff --git a/features/steps/project/merge_requests.rb b/features/steps/project/merge_requests.rb
index d15417fa173..8133760e619 100644
--- a/features/steps/project/merge_requests.rb
+++ b/features/steps/project/merge_requests.rb
@@ -33,7 +33,7 @@ class Spinach::Features::ProjectMergeRequests < Spinach::FeatureSteps
end
step 'I click link "Merged"' do
- click_link "Merged"
+ find('#state-merged').trigger('click')
end
step 'I click link "Closed"' do
@@ -331,7 +331,7 @@ class Spinach::Features::ProjectMergeRequests < Spinach::FeatureSteps
step 'I click on the Discussion tab' do
page.within '.merge-request-tabs' do
- click_link 'Discussion'
+ find('.notes-tab').trigger('click')
end
# Waits for load
diff --git a/features/steps/search.rb b/features/steps/search.rb
index f885baf8453..16c4a5ab2e4 100644
--- a/features/steps/search.rb
+++ b/features/steps/search.rb
@@ -10,12 +10,12 @@ class Spinach::Features::Search < Spinach::FeatureSteps
step 'I search for "Foo"' do
fill_in "dashboard_search", with: "Foo"
- click_button "Search"
+ find('.btn-search').trigger('click')
end
step 'I search for "rspec"' do
fill_in "dashboard_search", with: "rspec"
- click_button "Search"
+ find('.btn-search').trigger('click')
end
step 'I search for "rspec" on project page' do
@@ -25,7 +25,7 @@ class Spinach::Features::Search < Spinach::FeatureSteps
step 'I search for "Wiki content"' do
fill_in "dashboard_search", with: "content"
- click_button "Search"
+ find('.btn-search').trigger('click')
end
step 'I click "Issues" link' do
@@ -35,7 +35,7 @@ class Spinach::Features::Search < Spinach::FeatureSteps
end
step 'I click project "Shop" link' do
- click_button 'Project'
+ find('.js-search-project-dropdown').trigger('click')
page.within '.project-filter' do
click_link project.name_with_namespace
end