From 963a31144b0d69af7b08e1912965a920636ce600 Mon Sep 17 00:00:00 2001 From: Dmitriy Zaporozhets Date: Tue, 12 Nov 2013 14:32:17 +0200 Subject: [PATCH] Active tab tests for admin broadcast messages --- features/admin/active_tab.feature | 5 +++++ features/steps/admin/admin_active_tab.rb | 4 ++++ features/steps/shared/paths.rb | 4 ++++ 3 files changed, 13 insertions(+), 0 deletions(-) diff --git a/features/admin/active_tab.feature b/features/admin/active_tab.feature index 226d3d5..15fcda4 100644 --- a/features/admin/active_tab.feature +++ b/features/admin/active_tab.feature @@ -27,6 +27,11 @@ Feature: Admin active tab Then the active main tab should be Logs And no other main tabs should be active + Scenario: On Admin Messages + Given I visit admin messages page + Then the active main tab should be Messages + And no other main tabs should be active + Scenario: On Admin Hooks Given I visit admin hooks page Then the active main tab should be Hooks diff --git a/features/steps/admin/admin_active_tab.rb b/features/steps/admin/admin_active_tab.rb index f14c5f3..ccafe09 100644 --- a/features/steps/admin/admin_active_tab.rb +++ b/features/steps/admin/admin_active_tab.rb @@ -30,4 +30,8 @@ class AdminActiveTab < Spinach::FeatureSteps Then 'the active main tab should be Resque' do ensure_active_main_tab('Background Jobs') end + + Then 'the active main tab should be Messages' do + ensure_active_main_tab('Messages') + end end diff --git a/features/steps/shared/paths.rb b/features/steps/shared/paths.rb index 156fa5b..987cd31 100644 --- a/features/steps/shared/paths.rb +++ b/features/steps/shared/paths.rb @@ -105,6 +105,10 @@ module SharedPaths visit admin_logs_path end + step 'I visit admin messages page' do + visit admin_broadcast_messages_path + end + step 'I visit admin hooks page' do visit admin_hooks_path end -- libgit2 0.21.2