Welcome to mirror list, hosted at ThFree Co, Russian Federation.

stage_methods_shared_examples.rb « github_import « gitlab « workers « shared_examples « support « spec - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: af5bf33a9a6408c09d870426afbb4d3e194f96da (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# frozen_string_literal: true

RSpec.shared_examples Gitlab::GithubImport::StageMethods do
  describe '.sidekiq_retries_exhausted' do
    it 'tracks the exception and marks the import as failed' do
      expect(Gitlab::Import::ImportFailureService).to receive(:track)
        .with(
          project_id: 1,
          exception: StandardError,
          fail_import: true,
          error_source: anything
        )

      described_class.sidekiq_retries_exhausted_block.call({ 'args' => [1] }, StandardError.new)
    end
  end
end