diff options
author | James Lopez <james@jameslopez.es> | 2016-02-17 17:53:24 +0100 |
---|---|---|
committer | James Lopez <james@jameslopez.es> | 2016-02-17 17:53:24 +0100 |
commit | dd68d100e659d315ce6b21dac914beeda0fd1d4c (patch) | |
tree | 0742729ee62b1396172f2b6f6da02c286376453f /features | |
parent | b1731adf4385b982348746564e7365b7b70e50fb (diff) | |
parent | a4ffdf922da488b2f04e81f5fc29243413e42cd3 (diff) | |
download | gitlab-ce-dd68d100e659d315ce6b21dac914beeda0fd1d4c.tar.gz |
Merge branch 'master' of gitlab.com:gitlab-org/gitlab-ce into fix/project-forks-page
Diffstat (limited to 'features')
-rw-r--r-- | features/project/issues/issues.feature | 9 | ||||
-rw-r--r-- | features/project/merge_requests.feature | 1 | ||||
-rw-r--r-- | features/steps/project/issues/award_emoji.rb | 2 | ||||
-rw-r--r-- | features/steps/project/issues/issues.rb | 5 | ||||
-rw-r--r-- | features/steps/shared/issuable.rb | 24 |
5 files changed, 40 insertions, 1 deletions
diff --git a/features/project/issues/issues.feature b/features/project/issues/issues.feature index 0b3d03aa2a5..ca2399d85a9 100644 --- a/features/project/issues/issues.feature +++ b/features/project/issues/issues.feature @@ -25,9 +25,16 @@ Feature: Project Issues Scenario: I visit issue page Given I click link "Release 0.4" Then I should see issue "Release 0.4" + And I should see "1 of 2" in the sidebar + + Scenario: I navigate between issues + Given I click link "Release 0.4" + Then I click link "Next" in the sidebar + Then I should see issue "Tweet control" + And I should see "2 of 2" in the sidebar @javascript - Scenario: I visit issue page + Scenario: I filter by author Given I add a user to project "Shop" And I click "author" dropdown Then I see current user as the first user diff --git a/features/project/merge_requests.feature b/features/project/merge_requests.feature index ca1ee6b3c2b..5995e787961 100644 --- a/features/project/merge_requests.feature +++ b/features/project/merge_requests.feature @@ -39,6 +39,7 @@ Feature: Project Merge Requests Scenario: I visit merge request page Given I click link "Bug NS-04" Then I should see merge request "Bug NS-04" + And I should see "1 of 1" in the sidebar Scenario: I close merge request page Given I click link "Bug NS-04" diff --git a/features/steps/project/issues/award_emoji.rb b/features/steps/project/issues/award_emoji.rb index 8b9aa6aabfa..93cf608cc62 100644 --- a/features/steps/project/issues/award_emoji.rb +++ b/features/steps/project/issues/award_emoji.rb @@ -46,6 +46,8 @@ class Spinach::Features::AwardEmoji < Spinach::FeatureSteps end step 'I have award added' do + sleep 0.2 + page.within '.awards' do expect(page).to have_selector '.award' expect(page.find('.award.active .counter')).to have_content '1' diff --git a/features/steps/project/issues/issues.rb b/features/steps/project/issues/issues.rb index d556b73f9fd..09a89e99831 100644 --- a/features/steps/project/issues/issues.rb +++ b/features/steps/project/issues/issues.rb @@ -54,6 +54,10 @@ class Spinach::Features::ProjectIssues < Spinach::FeatureSteps expect(page).to have_content "Release 0.4" end + step 'I should see issue "Tweet control"' do + expect(page).to have_content "Tweet control" + end + step 'I click link "New Issue"' do click_link "New Issue" end @@ -301,4 +305,5 @@ class Spinach::Features::ProjectIssues < Spinach::FeatureSteps def filter_issue(text) fill_in 'issue_search', with: text end + end diff --git a/features/steps/shared/issuable.rb b/features/steps/shared/issuable.rb index 25c2b476f43..2117feaedb8 100644 --- a/features/steps/shared/issuable.rb +++ b/features/steps/shared/issuable.rb @@ -119,6 +119,24 @@ module SharedIssuable end end + step 'I should see "1 of 1" in the sidebar' do + expect_sidebar_content('1 of 1') + end + + step 'I should see "1 of 2" in the sidebar' do + expect_sidebar_content('1 of 2') + end + + step 'I should see "2 of 2" in the sidebar' do + expect_sidebar_content('2 of 2') + end + + step 'I click link "Next" in the sidebar' do + page.within '.issuable-sidebar' do + click_link 'Next' + end + end + def create_issuable_for_project(project_name:, title:, type: :issue) project = Project.find_by(name: project_name) @@ -159,4 +177,10 @@ module SharedIssuable expect(page).to have_content("mentioned in #{issuable.class.to_s.titleize.downcase} #{issuable.to_reference(project)}") end + def expect_sidebar_content(content) + page.within '.issuable-sidebar' do + expect(page).to have_content content + end + end + end |