blob: 3396abaff9e2d0f956abf0bdcc80e575c3900d8a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
# frozen_string_literal: true
require 'spec_helper'
RSpec.describe ResourceEvents::SyntheticLabelNotesBuilderService, feature_category: :team_planning do
describe '#execute' do
let_it_be(:user) { create(:user) }
let_it_be(:issue) { create(:issue, author: user) }
let_it_be(:event1) { create(:resource_label_event, issue: issue) }
let_it_be(:event2) { create(:resource_label_event, issue: issue) }
let_it_be(:event3) { create(:resource_label_event, issue: issue) }
it 'returns the expected synthetic notes' do
notes = ResourceEvents::SyntheticLabelNotesBuilderService.new(issue, user).execute
expect(notes.size).to eq(3)
end
it_behaves_like 'filters by paginated notes', :resource_label_event
end
end
|