summaryrefslogtreecommitdiff
path: root/features
diff options
context:
space:
mode:
authorPhil Hughes <me@iamphill.com>2017-03-07 11:40:27 +0000
committerPhil Hughes <me@iamphill.com>2017-03-07 11:40:27 +0000
commit12fe94c388ae9ec73e34852ef7d7b90f2f347df7 (patch)
tree5182f89deddf9428b1d6ca70720f8ac8ee2b940a /features
parent002d3a3e72de57c76a077ed5d09e857243c7effd (diff)
parentac9d792946deb17a402646e5481087e4d92f88ad (diff)
downloadgitlab-ce-12fe94c388ae9ec73e34852ef7d7b90f2f347df7.tar.gz
Merge branch 'master' into 26732-combine-deploy-keys-and-push-rules-and-mirror-repository-and-protect-branches-settings-pages26732-combine-deploy-keys-and-push-rules-and-mirror-repository-and-protect-branches-settings-pages
Diffstat (limited to 'features')
-rw-r--r--features/project/active_tab.feature23
-rw-r--r--features/project/shortcuts.feature15
-rw-r--r--features/steps/project/active_tab.rb16
-rw-r--r--features/steps/project/issues/award_emoji.rb2
-rw-r--r--features/steps/project/project_shortcuts.rb5
-rw-r--r--features/steps/shared/project_tab.rb14
6 files changed, 69 insertions, 6 deletions
diff --git a/features/project/active_tab.feature b/features/project/active_tab.feature
index 4bdaa6266c3..ba04b03c3cc 100644
--- a/features/project/active_tab.feature
+++ b/features/project/active_tab.feature
@@ -7,8 +7,9 @@ Feature: Project Active Tab
Scenario: On Project Home
Given I visit my project's home page
- Then the active main tab should be Home
- And no other main tabs should be active
+ Then the active sub tab should be Home
+ And no other sub tabs should be active
+ And the active main tab should be Project
Scenario: On Project Repository
Given I visit my project's files page
@@ -34,9 +35,18 @@ Feature: Project Active Tab
Scenario: On Project Home/Show
Given I visit my project's home page
- Then the active main tab should be Home
+ Then the active sub tab should be Home
+ And no other sub tabs should be active
+ And the active main tab should be Project
And no other main tabs should be active
+ Scenario: On Project Home/Activity
+ Given I visit my project's home page
+ And I click the "Activity" tab
+ Then the active sub tab should be Activity
+ And no other sub tabs should be active
+ And the active main tab should be Project
+
# Sub Tabs: Settings
Scenario: On Project Settings/Integrations
@@ -93,6 +103,13 @@ Feature: Project Active Tab
And no other sub tabs should be active
And the active main tab should be Repository
+ Scenario: On Project Repository/Charts
+ Given I visit my project's commits page
+ And I click the "Charts" tab
+ Then the active sub tab should be Charts
+ And no other sub tabs should be active
+ And the active main tab should be Repository
+
Scenario: On Project Repository/Branches
Given I visit my project's commits page
And I click the "Branches" tab
diff --git a/features/project/shortcuts.feature b/features/project/shortcuts.feature
index 95de63ba21a..b47fca31ef2 100644
--- a/features/project/shortcuts.feature
+++ b/features/project/shortcuts.feature
@@ -25,6 +25,12 @@ Feature: Project Shortcuts
And the active main tab should be Repository
@javascript
+ Scenario: Navigate to repository charts tab
+ Given I press "g" and "g"
+ Then the active sub tab should be Charts
+ And the active main tab should be Repository
+
+ @javascript
Scenario: Navigate to issues tab
Given I press "g" and "i"
Then the active main tab should be Issues
@@ -47,4 +53,11 @@ Feature: Project Shortcuts
@javascript
Scenario: Navigate to project home
Given I press "g" and "p"
- Then the active main tab should be Home
+ Then the active sub tab should be Home
+ And the active main tab should be Project
+
+ @javascript
+ Scenario: Navigate to project feed
+ Given I press "g" and "e"
+ Then the active sub tab should be Activity
+ And the active main tab should be Project
diff --git a/features/steps/project/active_tab.rb b/features/steps/project/active_tab.rb
index 218d5c6164b..f901f4889dd 100644
--- a/features/steps/project/active_tab.rb
+++ b/features/steps/project/active_tab.rb
@@ -41,6 +41,12 @@ class Spinach::Features::ProjectActiveTab < Spinach::FeatureSteps
click_link('Pages')
end
+ step 'I click the "Activity" tab' do
+ page.within '.sub-nav' do
+ click_link('Activity')
+ end
+ end
+
step 'the active sub nav should be Members' do
ensure_active_sub_nav('Members')
end
@@ -57,6 +63,10 @@ class Spinach::Features::ProjectActiveTab < Spinach::FeatureSteps
ensure_active_sub_nav('Pages')
end
+ step 'the active sub tab should be Activity' do
+ ensure_active_sub_tab('Activity')
+ end
+
# Sub Tabs: Commits
step 'I click the "Compare" tab' do
@@ -73,6 +83,12 @@ class Spinach::Features::ProjectActiveTab < Spinach::FeatureSteps
click_link('Tags')
end
+ step 'I click the "Charts" tab' do
+ page.within '.sub-nav' do
+ click_link('Charts')
+ end
+ end
+
step 'the active sub tab should be Compare' do
ensure_active_sub_tab('Compare')
end
diff --git a/features/steps/project/issues/award_emoji.rb b/features/steps/project/issues/award_emoji.rb
index dd7a58b454a..1762d5bdf95 100644
--- a/features/steps/project/issues/award_emoji.rb
+++ b/features/steps/project/issues/award_emoji.rb
@@ -90,7 +90,7 @@ class Spinach::Features::AwardEmoji < Spinach::FeatureSteps
step 'I see search result for "hand"' do
page.within '.emoji-menu-content' do
- expect(page).to have_selector '[data-emoji="raised_hand"]'
+ expect(page).to have_selector '[data-name="raised_hand"]'
end
end
diff --git a/features/steps/project/project_shortcuts.rb b/features/steps/project/project_shortcuts.rb
index 02c08b784bc..8143b01ca40 100644
--- a/features/steps/project/project_shortcuts.rb
+++ b/features/steps/project/project_shortcuts.rb
@@ -34,4 +34,9 @@ class Spinach::Features::ProjectShortcuts < Spinach::FeatureSteps
find('body').native.send_key('g')
find('body').native.send_key('w')
end
+
+ step 'I press "g" and "e"' do
+ find('body').native.send_key('g')
+ find('body').native.send_key('e')
+ end
end
diff --git a/features/steps/shared/project_tab.rb b/features/steps/shared/project_tab.rb
index 83446afe424..400114f03c0 100644
--- a/features/steps/shared/project_tab.rb
+++ b/features/steps/shared/project_tab.rb
@@ -4,7 +4,7 @@ module SharedProjectTab
include Spinach::DSL
include SharedActiveTab
- step 'the active main tab should be Home' do
+ step 'the active main tab should be Project' do
ensure_active_main_tab('Project')
end
@@ -47,4 +47,16 @@ module SharedProjectTab
step 'the active sub tab should be Commits' do
ensure_active_sub_tab('Commits')
end
+
+ step 'the active sub tab should be Home' do
+ ensure_active_sub_tab('Home')
+ end
+
+ step 'the active sub tab should be Activity' do
+ ensure_active_sub_tab('Activity')
+ end
+
+ step 'the active sub tab should be Charts' do
+ ensure_active_sub_tab('Charts')
+ end
end