summaryrefslogtreecommitdiff
path: root/spec/requests/api/project_hooks_spec.rb
diff options
context:
space:
mode:
authorRobert Speicher <rspeicher@gmail.com>2015-06-22 16:00:54 -0400
committerRobert Speicher <rspeicher@gmail.com>2015-06-22 16:00:54 -0400
commit15a05be70d7652a98f870c5b5d02373dabf363e0 (patch)
tree970f32c6d3fb705c5626b503dee5e683049f5c8e /spec/requests/api/project_hooks_spec.rb
parent88328392918deeb459c1d991559f9b40b5fc1026 (diff)
downloadgitlab-ce-15a05be70d7652a98f870c5b5d02373dabf363e0.tar.gz
Fix Style/Blocks cop violations
Diffstat (limited to 'spec/requests/api/project_hooks_spec.rb')
-rw-r--r--spec/requests/api/project_hooks_spec.rb11
1 files changed, 5 insertions, 6 deletions
diff --git a/spec/requests/api/project_hooks_spec.rb b/spec/requests/api/project_hooks_spec.rb
index 81fe68de662..5037575d355 100644
--- a/spec/requests/api/project_hooks_spec.rb
+++ b/spec/requests/api/project_hooks_spec.rb
@@ -61,10 +61,9 @@ describe API::API, 'ProjectHooks', api: true do
describe "POST /projects/:id/hooks" do
it "should add hook to project" do
- expect {
- post api("/projects/#{project.id}/hooks", user),
- url: "http://example.com", issues_events: true
- }.to change {project.hooks.count}.by(1)
+ expect do
+ post api("/projects/#{project.id}/hooks", user), url: "http://example.com", issues_events: true
+ end.to change {project.hooks.count}.by(1)
expect(response.status).to eq(201)
end
@@ -105,9 +104,9 @@ describe API::API, 'ProjectHooks', api: true do
describe "DELETE /projects/:id/hooks/:hook_id" do
it "should delete hook from project" do
- expect {
+ expect do
delete api("/projects/#{project.id}/hooks/#{hook.id}", user)
- }.to change {project.hooks.count}.by(-1)
+ end.to change {project.hooks.count}.by(-1)
expect(response.status).to eq(200)
end