Change active tab and nav class to "active"

The main nav used active, the sub nav used current. This normalizes it.
This commit is contained in:
Robert Speicher 2012-09-25 22:07:41 -04:00
parent adcc6a0b0e
commit 51c1e49900
4 changed files with 18 additions and 21 deletions

View file

@ -2,10 +2,18 @@ module SharedActiveTab
include Spinach::DSL
def ensure_active_main_tab(content)
page.find('ul.main_menu li.current').should have_content(content)
page.find('ul.main_menu li.active').should have_content(content)
end
def ensure_active_sub_tab(content)
page.find('div.content ul.nav-tabs li.active').should have_content(content)
end
And 'no other main tabs should be active' do
page.should have_selector('ul.main_menu li.current', count: 1)
page.should have_selector('ul.main_menu li.active', count: 1)
end
And 'no other sub tabs should be active' do
page.should have_selector('div.content ul.nav-tabs li.active', count: 1)
end
end