diff options
Diffstat (limited to 'spec/features/profiles/user_visits_notifications_tab_spec.rb')
-rw-r--r-- | spec/features/profiles/user_visits_notifications_tab_spec.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/spec/features/profiles/user_visits_notifications_tab_spec.rb b/spec/features/profiles/user_visits_notifications_tab_spec.rb index db797bb586f..d788c0574e2 100644 --- a/spec/features/profiles/user_visits_notifications_tab_spec.rb +++ b/spec/features/profiles/user_visits_notifications_tab_spec.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + require 'spec_helper' describe 'User visits the notifications tab', :js do @@ -18,4 +20,12 @@ describe 'User visits the notifications tab', :js do expect(page).to have_selector('#notifications-button', text: 'On mention') end + + context 'when project emails are disabled' do + let(:project) { create(:project, emails_disabled: true) } + + it 'notification button is disabled' do + expect(page).to have_selector('.notifications-btn.disabled', visible: true) + end + end end |