debian-mirror-gitlab/spec/features/profiles/user_visits_notifications_tab_spec.rb

22 lines
516 B
Ruby
Raw Normal View History

2017-09-10 17:25:29 +05:30
require 'spec_helper'
2018-11-08 19:23:39 +05:30
describe 'User visits the notifications tab', :js do
2017-09-10 17:25:29 +05:30
let(:project) { create(:project) }
let(:user) { create(:user) }
before do
2018-11-18 11:00:15 +05:30
project.add_maintainer(user)
2017-09-10 17:25:29 +05:30
sign_in(user)
visit(profile_notifications_path)
end
it 'changes the project notifications setting' do
expect(page).to have_content('Notifications')
2018-03-17 18:26:18 +05:30
first('#notifications-button').click
2017-09-10 17:25:29 +05:30
click_link('On mention')
2018-03-27 19:54:05 +05:30
expect(page).to have_selector('#notifications-button', text: 'On mention')
2017-09-10 17:25:29 +05:30
end
end