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:
authorStan Hu <stanhu@gmail.com>2016-08-06 17:25:51 +0300
committerStan Hu <stanhu@gmail.com>2016-08-10 19:28:21 +0300
commit4955a47cb1c52168114364e45a2fccf6bc105452 (patch)
tree50bb5ea1979a596edef53817aea75796686fc2a9 /spec/models
parentae2d3c417075c83e169ab7662f3dd11e3b2bf043 (diff)
Clean up project destruction
Instead of redirecting from the project service to the service and back to the model, put all destruction code in the service. Also removes a possible source of failure where run_after_commit may not destroy the project.
Diffstat (limited to 'spec/models')
-rw-r--r--spec/models/hooks/system_hook_spec.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/spec/models/hooks/system_hook_spec.rb b/spec/models/hooks/system_hook_spec.rb
index 4078b9e4ff5..cbdf7eec082 100644
--- a/spec/models/hooks/system_hook_spec.rb
+++ b/spec/models/hooks/system_hook_spec.rb
@@ -38,7 +38,7 @@ describe SystemHook, models: true do
end
it "project_destroy hook" do
- Projects::DestroyService.new(project, user, {}).pending_delete!
+ Projects::DestroyService.new(project, user, {}).async_execute
expect(WebMock).to have_requested(:post, system_hook.url).with(
body: /project_destroy/,