diff options
Diffstat (limited to 'features/steps')
-rw-r--r-- | features/steps/admin/admin_active_tab.rb | 2 | ||||
-rw-r--r-- | features/steps/group/group.rb | 11 | ||||
-rw-r--r-- | features/steps/profile/profile_active_tab.rb | 2 | ||||
-rw-r--r-- | features/steps/project/project_active_tab.rb | 2 | ||||
-rw-r--r-- | features/steps/project/project_network_graph.rb | 2 | ||||
-rw-r--r-- | features/steps/project/project_team_management.rb | 2 | ||||
-rw-r--r-- | features/steps/shared/active_tab.rb | 6 | ||||
-rw-r--r-- | features/steps/shared/paths.rb | 6 |
8 files changed, 26 insertions, 7 deletions
diff --git a/features/steps/admin/admin_active_tab.rb b/features/steps/admin/admin_active_tab.rb index 48ec7bac0d6..f14c5f396be 100644 --- a/features/steps/admin/admin_active_tab.rb +++ b/features/steps/admin/admin_active_tab.rb @@ -4,7 +4,7 @@ class AdminActiveTab < Spinach::FeatureSteps include SharedActiveTab Then 'the active main tab should be Home' do - ensure_active_main_tab('Stats') + ensure_active_main_tab('Home') end Then 'the active main tab should be Projects' do diff --git a/features/steps/group/group.rb b/features/steps/group/group.rb index c6c6b4b5e5b..5cfa4756ac3 100644 --- a/features/steps/group/group.rb +++ b/features/steps/group/group.rb @@ -82,6 +82,17 @@ class Groups < Spinach::FeatureSteps current_path.should == group_path(Group.last) end + And 'I change group name' do + fill_in 'group_name', :with => 'new-name' + click_button "Save group" + end + + Then 'I should see new group name' do + within ".navbar-gitlab" do + page.should have_content "group: new-name" + end + end + protected def current_group diff --git a/features/steps/profile/profile_active_tab.rb b/features/steps/profile/profile_active_tab.rb index 1924a6fa785..ee9f5f201cf 100644 --- a/features/steps/profile/profile_active_tab.rb +++ b/features/steps/profile/profile_active_tab.rb @@ -4,7 +4,7 @@ class ProfileActiveTab < Spinach::FeatureSteps include SharedActiveTab Then 'the active main tab should be Home' do - ensure_active_main_tab('Profile') + ensure_active_main_tab('Home') end Then 'the active main tab should be Account' do diff --git a/features/steps/project/project_active_tab.rb b/features/steps/project/project_active_tab.rb index a5c80353862..bce67c82962 100644 --- a/features/steps/project/project_active_tab.rb +++ b/features/steps/project/project_active_tab.rb @@ -7,7 +7,7 @@ class ProjectActiveTab < Spinach::FeatureSteps # Main Tabs Then 'the active main tab should be Home' do - ensure_active_main_tab(@project.name) + ensure_active_main_tab('Home') end Then 'the active main tab should be Files' do diff --git a/features/steps/project/project_network_graph.rb b/features/steps/project/project_network_graph.rb index 77149bfe2c3..f26deff9367 100644 --- a/features/steps/project/project_network_graph.rb +++ b/features/steps/project/project_network_graph.rb @@ -14,6 +14,6 @@ class ProjectNetworkGraph < Spinach::FeatureSteps Gitlab::Graph::JsonBuilder.stub(max_count: 10) project = Project.find_by_name("Shop") - visit graph_project_path(project) + visit project_graph_path(project, "master") end end diff --git a/features/steps/project/project_team_management.rb b/features/steps/project/project_team_management.rb index 91b3ffeee9a..19352fe0ab8 100644 --- a/features/steps/project/project_team_management.rb +++ b/features/steps/project/project_team_management.rb @@ -24,7 +24,7 @@ class ProjectTeamManagement < Spinach::FeatureSteps select user.name, :from => "user_ids" select "Reporter", :from => "project_access" end - click_button "Save" + click_button "Add users" end Then 'I should see "Mike" in team list as "Reporter"' do diff --git a/features/steps/shared/active_tab.rb b/features/steps/shared/active_tab.rb index 884f2d5fb71..446e3b9a8b3 100644 --- a/features/steps/shared/active_tab.rb +++ b/features/steps/shared/active_tab.rb @@ -2,7 +2,11 @@ module SharedActiveTab include Spinach::DSL def ensure_active_main_tab(content) - page.find('ul.main_menu li.active').should have_content(content) + if content == "Home" + page.find('ul.main_menu li.active').should have_css('i.icon-home') + else + page.find('ul.main_menu li.active').should have_content(content) + end end def ensure_active_sub_tab(content) diff --git a/features/steps/shared/paths.rb b/features/steps/shared/paths.rb index 42ef40d6b95..a8e68012d05 100644 --- a/features/steps/shared/paths.rb +++ b/features/steps/shared/paths.rb @@ -25,6 +25,10 @@ module SharedPaths visit people_group_path(current_group) end + When 'I visit group settings page' do + visit edit_group_path(current_group) + end + # ---------------------------------------- # Dashboard # ---------------------------------------- @@ -141,7 +145,7 @@ module SharedPaths # Stub Graph::JsonBuilder max_size to speed up test (10 commits vs. 650) Gitlab::Graph::JsonBuilder.stub(max_count: 10) - visit graph_project_path(@project) + visit project_graph_path(@project, root_ref) end Given "I visit my project's issues page" do |