diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2019-10-10 18:06:07 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2019-10-10 18:06:07 +0300 |
commit | d96abbee0b394ac40eb67253214fb9c41a31bd41 (patch) | |
tree | 4887c6f08cc902c79e2a31d21a85ce7909cf88bc /spec/services/system_notes | |
parent | 69849c280c5525d132ebaddb1200c390a42ecc06 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/services/system_notes')
-rw-r--r-- | spec/services/system_notes/zoom_service_spec.rb | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/spec/services/system_notes/zoom_service_spec.rb b/spec/services/system_notes/zoom_service_spec.rb new file mode 100644 index 00000000000..435cdb5748e --- /dev/null +++ b/spec/services/system_notes/zoom_service_spec.rb @@ -0,0 +1,36 @@ +# frozen_string_literal: true + +require 'spec_helper' + +describe ::SystemNotes::ZoomService do + let_it_be(:project) { create(:project, :repository) } + let_it_be(:author) { create(:user) } + + let(:noteable) { create(:issue, project: project) } + + let(:service) { described_class.new(noteable: noteable, project: project, author: author) } + + describe '#zoom_link_added' do + subject { service.zoom_link_added } + + it_behaves_like 'a system note' do + let(:action) { 'pinned_embed' } + end + + it 'sets the zoom link added note text' do + expect(subject.note).to eq('added a Zoom call to this issue') + end + end + + describe '#zoom_link_removed' do + subject { service.zoom_link_removed } + + it_behaves_like 'a system note' do + let(:action) { 'pinned_embed' } + end + + it 'sets the zoom link removed note text' do + expect(subject.note).to eq('removed a Zoom call from this issue') + end + end +end |