Commit 1f6ebcb9 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Add tests for group active tab

Signed-off-by: default avatarDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
parent f790206a
Feature: Group Active Tab
Background:
Given I sign in as "John Doe"
And "John Doe" is owner of group "Owned"
When I visit group "Owned" settings page
Scenario: On Audit events
When I go to "Audit Events"
Then the active sub nav should be Audit Events
And no other sub navs should be active
And the active main tab should be Settings
Scenario: On Web Hooks
When I go to "Web Hooks"
Then the active sub nav should be Web Hooks
And no other sub navs should be active
And the active main tab should be Settings
class Spinach::Features::GroupActiveTab < Spinach::FeatureSteps
include SharedAuthentication
include SharedUser
include SharedGroup
include SharedPaths
include SharedActiveTab
step 'the active sub nav should be Audit Events' do
ensure_active_sub_nav('Audit Events')
end
step 'the active main tab should be Settings' do
page.within '.nav-sidebar' do
expect(page).to have_content('Back to group')
end
end
step 'the active sub nav should be Web Hooks' do
ensure_active_sub_nav('Web Hooks')
end
step 'I go to "Audit Events"' do
click_link 'Audit Events'
end
step 'I go to "Web Hooks"' do
click_link 'Web Hooks'
end
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment