diff options
author | Gabriel Mazetto <gabriel@gitlab.com> | 2015-12-15 00:53:52 -0200 |
---|---|---|
committer | Gabriel Mazetto <gabriel@gitlab.com> | 2015-12-15 00:53:52 -0200 |
commit | b5291f95996743067bbec5a32f9c6cf0d34b36c7 (patch) | |
tree | 9933fe5c9c224a175fb49fceff829b8b4441c970 /spec/workers | |
parent | d1f1c5c60bfd58f966671d7895c1ef612e8f8897 (diff) | |
download | gitlab-ce-b5291f95996743067bbec5a32f9c6cf0d34b36c7.tar.gz |
Fixed Rubocop offenses
Diffstat (limited to 'spec/workers')
-rw-r--r-- | spec/workers/repository_fork_worker_spec.rb | 20 | ||||
-rw-r--r-- | spec/workers/stuck_ci_builds_worker_spec.rb | 4 |
2 files changed, 13 insertions, 11 deletions
diff --git a/spec/workers/repository_fork_worker_spec.rb b/spec/workers/repository_fork_worker_spec.rb index 245f066df1f..dae31992620 100644 --- a/spec/workers/repository_fork_worker_spec.rb +++ b/spec/workers/repository_fork_worker_spec.rb @@ -9,20 +9,22 @@ describe RepositoryForkWorker do describe "#perform" do it "creates a new repository from a fork" do expect_any_instance_of(Gitlab::Shell).to receive(:fork_repository).with( - project.path_with_namespace, - fork_project.namespace.path). - and_return(true) + project.path_with_namespace, + fork_project.namespace.path + ).and_return(true) - subject.perform(project.id, - project.path_with_namespace, - fork_project.namespace.path) + subject.perform( + project.id, + project.path_with_namespace, + fork_project.namespace.path) end it "handles bad fork" do expect_any_instance_of(Gitlab::Shell).to receive(:fork_repository).and_return(false) - subject.perform(project.id, - project.path_with_namespace, - fork_project.namespace.path) + subject.perform( + project.id, + project.path_with_namespace, + fork_project.namespace.path) end end end diff --git a/spec/workers/stuck_ci_builds_worker_spec.rb b/spec/workers/stuck_ci_builds_worker_spec.rb index f9d87d97014..665ec20f224 100644 --- a/spec/workers/stuck_ci_builds_worker_spec.rb +++ b/spec/workers/stuck_ci_builds_worker_spec.rb @@ -15,7 +15,7 @@ describe StuckCiBuildsWorker do end it 'gets dropped if it was updated over 2 days ago' do - build.update!(updated_at: 2.day.ago) + build.update!(updated_at: 2.days.ago) StuckCiBuildsWorker.new.perform is_expected.to eq('failed') end @@ -35,7 +35,7 @@ describe StuckCiBuildsWorker do end it "is still #{status}" do - build.update!(updated_at: 2.day.ago) + build.update!(updated_at: 2.days.ago) StuckCiBuildsWorker.new.perform is_expected.to eq(status) end |