debian-mirror-gitlab/features/steps/project/active_tab.rb

104 lines
2.1 KiB
Ruby
Raw Normal View History

2015-04-26 12:48:37 +05:30
class Spinach::Features::ProjectActiveTab < Spinach::FeatureSteps
2014-09-02 18:07:02 +05:30
include SharedAuthentication
include SharedPaths
include SharedProject
include SharedActiveTab
2015-04-26 12:48:37 +05:30
include SharedProjectTab
2014-09-02 18:07:02 +05:30
# Sub Tabs: Home
2015-04-26 12:48:37 +05:30
step 'I click the "Team" tab' do
2014-09-02 18:07:02 +05:30
click_link('Members')
end
2015-04-26 12:48:37 +05:30
step 'I click the "Attachments" tab' do
2014-09-02 18:07:02 +05:30
click_link('Attachments')
end
2015-04-26 12:48:37 +05:30
step 'I click the "Snippets" tab' do
2014-09-02 18:07:02 +05:30
click_link('Snippets')
end
2015-04-26 12:48:37 +05:30
step 'I click the "Edit" tab' do
2015-09-11 14:41:01 +05:30
page.within '.sidebar-subnav' do
click_link('Project Settings')
2014-09-02 18:07:02 +05:30
end
end
2015-04-26 12:48:37 +05:30
step 'I click the "Hooks" tab' do
2014-09-02 18:07:02 +05:30
click_link('Web Hooks')
end
2015-04-26 12:48:37 +05:30
step 'I click the "Deploy Keys" tab' do
2014-09-02 18:07:02 +05:30
click_link('Deploy Keys')
end
2015-04-26 12:48:37 +05:30
step 'the active sub nav should be Team' do
2014-09-02 18:07:02 +05:30
ensure_active_sub_nav('Members')
end
2015-04-26 12:48:37 +05:30
step 'the active sub nav should be Edit' do
2014-09-02 18:07:02 +05:30
ensure_active_sub_nav('Project')
end
2015-04-26 12:48:37 +05:30
step 'the active sub nav should be Hooks' do
2014-09-02 18:07:02 +05:30
ensure_active_sub_nav('Web Hooks')
end
2015-04-26 12:48:37 +05:30
step 'the active sub nav should be Deploy Keys' do
2014-09-02 18:07:02 +05:30
ensure_active_sub_nav('Deploy Keys')
end
# Sub Tabs: Commits
2015-04-26 12:48:37 +05:30
step 'I click the "Compare" tab' do
2014-09-02 18:07:02 +05:30
click_link('Compare')
end
2015-04-26 12:48:37 +05:30
step 'I click the "Branches" tab' do
2014-09-02 18:07:02 +05:30
click_link('Branches')
end
2015-04-26 12:48:37 +05:30
step 'I click the "Tags" tab' do
2014-09-02 18:07:02 +05:30
click_link('Tags')
end
2015-04-26 12:48:37 +05:30
step 'the active sub tab should be Commits' do
2014-09-02 18:07:02 +05:30
ensure_active_sub_tab('Commits')
end
2015-04-26 12:48:37 +05:30
step 'the active sub tab should be Compare' do
2014-09-02 18:07:02 +05:30
ensure_active_sub_tab('Compare')
end
2015-04-26 12:48:37 +05:30
step 'the active sub tab should be Branches' do
2014-09-02 18:07:02 +05:30
ensure_active_sub_tab('Branches')
end
2015-04-26 12:48:37 +05:30
step 'the active sub tab should be Tags' do
2014-09-02 18:07:02 +05:30
ensure_active_sub_tab('Tags')
end
# Sub Tabs: Issues
2015-04-26 12:48:37 +05:30
step 'I click the "Milestones" tab' do
2014-09-02 18:07:02 +05:30
click_link('Milestones')
end
2015-04-26 12:48:37 +05:30
step 'I click the "Labels" tab' do
2014-09-02 18:07:02 +05:30
click_link('Labels')
end
2015-04-26 12:48:37 +05:30
step 'the active sub tab should be Issues' do
ensure_active_sub_tab('Issues')
2014-09-02 18:07:02 +05:30
end
2015-04-26 12:48:37 +05:30
step 'the active main tab should be Milestones' do
ensure_active_main_tab('Milestones')
2014-09-02 18:07:02 +05:30
end
2015-04-26 12:48:37 +05:30
step 'the active main tab should be Labels' do
ensure_active_main_tab('Labels')
2014-09-02 18:07:02 +05:30
end
end