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

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJames Lopez <james@jameslopez.es>2017-03-24 14:08:34 +0300
committerJames Lopez <james@jameslopez.es>2017-04-05 17:11:51 +0300
commit58371efbb0bd051d3a82f82acac98ad4692efeb4 (patch)
tree226bfb1a920a6344d6efb3b0357473412aa9dade /spec/workers/repository_import_worker_spec.rb
parent7196adaaa4ce5aa259d285dbca6aa98f4deb046b (diff)
Periodically mark projects that are stuck in importing as failed
Adds import jid to projects Refactor middleware to set custom expiration time via sidekiq options Add completed_jids option to sidekiq status and a few other changes
Diffstat (limited to 'spec/workers/repository_import_worker_spec.rb')
-rw-r--r--spec/workers/repository_import_worker_spec.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/spec/workers/repository_import_worker_spec.rb b/spec/workers/repository_import_worker_spec.rb
index fbb22439f33..5a2c0671dac 100644
--- a/spec/workers/repository_import_worker_spec.rb
+++ b/spec/workers/repository_import_worker_spec.rb
@@ -23,10 +23,12 @@ describe RepositoryImportWorker do
error = %q{remote: Not Found fatal: repository 'https://user:pass@test.com/root/repoC.git/' not found }
expect_any_instance_of(Projects::ImportService).to receive(:execute).
and_return({ status: :error, message: error })
+ allow(subject).to receive(:jid).and_return('123')
subject.perform(project.id)
expect(project.reload.import_error).to include("https://*****:*****@test.com/root/repoC.git/")
+ expect(project.reload.import_jid).not_to be_nil
end
end
end