debian-mirror-gitlab/spec/services/resource_events/change_milestone_service_spec.rb

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

18 lines
570 B
Ruby
Raw Normal View History

2020-04-08 14:13:33 +05:30
# frozen_string_literal: true
require 'spec_helper'
2020-07-28 23:09:34 +05:30
RSpec.describe ResourceEvents::ChangeMilestoneService do
2020-10-24 23:57:45 +05:30
let_it_be(:timebox) { create(:milestone) }
let(:created_at_time) { Time.utc(2019, 12, 30) }
2021-03-11 19:13:27 +05:30
let(:add_timebox_args) { { old_milestone: nil } }
let(:remove_timebox_args) { { old_milestone: timebox } }
2020-10-24 23:57:45 +05:30
2020-05-24 23:13:21 +05:30
[:issue, :merge_request].each do |issuable|
2020-10-24 23:57:45 +05:30
it_behaves_like 'timebox(milestone or iteration) resource events creator', ResourceMilestoneEvent do
2021-01-29 00:20:46 +05:30
let_it_be(:resource) { create(issuable) } # rubocop:disable Rails/SaveBang
2020-05-24 23:13:21 +05:30
end
2020-04-08 14:13:33 +05:30
end
end