2018-12-05 19:51:30 -05:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
|
|
|
require 'spec_helper'
|
|
|
|
|
2020-06-24 11:08:50 -04:00
|
|
|
RSpec.describe Issues::ImportCsvService do
|
2018-12-05 19:51:30 -05:00
|
|
|
let(:project) { create(:project) }
|
|
|
|
let(:user) { create(:user) }
|
2020-11-05 19:09:14 -05:00
|
|
|
let(:service) do
|
2018-12-05 19:51:30 -05:00
|
|
|
uploader = FileUploader.new(project)
|
|
|
|
uploader.store!(file)
|
|
|
|
|
2020-11-05 19:09:14 -05:00
|
|
|
described_class.new(user, project, uploader)
|
2020-10-20 11:08:57 -04:00
|
|
|
end
|
|
|
|
|
2020-11-05 19:09:14 -05:00
|
|
|
include_examples 'issuable import csv service', 'issue' do
|
|
|
|
let(:issuables) { project.issues }
|
|
|
|
let(:email_method) { :import_issues_csv_email }
|
2018-12-05 19:51:30 -05:00
|
|
|
end
|
|
|
|
end
|