gitlab-org--gitlab-foss/features/steps/project/active_tab.rb

112 lines
2.3 KiB
Ruby
Raw Normal View History

class Spinach::Features::ProjectActiveTab < Spinach::FeatureSteps
include SharedAuthentication
include SharedPaths
include SharedProject
include SharedActiveTab
2014-08-21 04:14:31 -04:00
include SharedProjectTab
# Sub Tabs: Home
step 'I click the "Team" tab' do
2013-06-18 10:09:04 -04:00
click_link('Members')
end
step 'I click the "Attachments" tab' do
click_link('Attachments')
end
step 'I click the "Snippets" tab' do
page.within('.layout-nav') do
click_link('Snippets')
end
end
step 'I click the "Edit Project"' do
page.within '.layout-nav .controls' do
click_link('Edit Project')
end
end
2016-12-30 16:09:31 -05:00
step 'I click the "Integrations" tab' do
click_link('Integrations')
end
step 'I click the "Deploy Keys" tab' do
click_link('Deploy Keys')
end
2016-02-14 14:28:02 -05:00
step 'I click the "Pages" tab' do
click_link('Pages')
end
step 'the active sub nav should be Members' do
ensure_active_sub_nav('Members')
end
2016-12-30 16:09:31 -05:00
step 'the active sub nav should be Integrations' do
ensure_active_sub_nav('Integrations')
end
step 'the active sub nav should be Deploy Keys' do
ensure_active_sub_nav('Deploy Keys')
end
2016-02-14 14:28:02 -05:00
step 'the active sub nav should be Pages' do
ensure_active_sub_nav('Pages')
end
# Sub Tabs: Commits
step 'I click the "Compare" tab' do
click_link('Compare')
end
step 'I click the "Branches" tab' do
page.within '.sub-nav' do
click_link('Branches')
end
end
step 'I click the "Tags" tab' do
click_link('Tags')
end
step 'the active sub tab should be Compare' do
ensure_active_sub_tab('Compare')
end
step 'the active sub tab should be Branches' do
ensure_active_sub_tab('Branches')
end
step 'the active sub tab should be Tags' do
ensure_active_sub_tab('Tags')
end
# Sub Tabs: Issues
step 'I click the "Milestones" sub tab' do
page.within('.sub-nav') do
click_link('Milestones')
end
end
step 'I click the "Labels" sub tab' do
page.within('.sub-nav') do
click_link('Labels')
end
end
step 'the active sub tab should be Issues' do
ensure_active_sub_tab('Issues')
end
step 'the active sub tab should be Milestones' do
ensure_active_sub_tab('Milestones')
end
step 'the active sub tab should be Labels' do
ensure_active_sub_tab('Labels')
end
end