diff options
Diffstat (limited to 'spec/services/git_push_service_spec.rb')
-rw-r--r-- | spec/services/git_push_service_spec.rb | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/spec/services/git_push_service_spec.rb b/spec/services/git_push_service_spec.rb index 2807d735eec..b3e59d7a0db 100644 --- a/spec/services/git_push_service_spec.rb +++ b/spec/services/git_push_service_spec.rb @@ -218,18 +218,18 @@ describe GitPushService do end it "doesn't create cross-reference notes for a closing reference" do - expect { + expect do service.execute(project, user, @oldrev, @newrev, @ref) - }.not_to change { Note.where(project_id: project.id, system: true, commit_id: closing_commit.id).count } + end.not_to change { Note.where(project_id: project.id, system: true, commit_id: closing_commit.id).count } end it "doesn't close issues when pushed to non-default branches" do project.stub(default_branch: 'durf') # The push still shouldn't create cross-reference notes. - expect { + expect do service.execute(project, user, @oldrev, @newrev, 'refs/heads/hurf') - }.not_to change { Note.where(project_id: project.id, system: true).count } + end.not_to change { Note.where(project_id: project.id, system: true).count } expect(Issue.find(issue.id)).to be_opened end @@ -238,9 +238,9 @@ describe GitPushService do allow(project).to receive(:default_issues_tracker?).and_return(false) # The push still shouldn't create cross-reference notes. - expect { + expect do service.execute(project, user, @oldrev, @newrev, 'refs/heads/hurf') - }.not_to change { Note.where(project_id: project.id, system: true).count } + end.not_to change { Note.where(project_id: project.id, system: true).count } end end |