summaryrefslogtreecommitdiff
path: root/spec/requests
diff options
context:
space:
mode:
authorNick Thomas <nick@gitlab.com>2018-08-06 10:51:37 +0000
committerNick Thomas <nick@gitlab.com>2018-08-06 10:51:37 +0000
commitf6e6faee68e16fde00e44caa9b8c0c527aa79689 (patch)
treea5a357c4e596c27a96d4a12e2b83f982939588ca /spec/requests
parentbc1f851fdfaf9cc2bba5b67fd762e8802023bf5c (diff)
parent79d90cb6bd99b7af572c65af89597c2e55217aea (diff)
downloadgitlab-ce-f6e6faee68e16fde00e44caa9b8c0c527aa79689.tar.gz
Merge branch 'jr-archive-hook' into 'master'
Trigger `project_update` system hook when archiving projects See merge request gitlab-org/gitlab-ce!20995
Diffstat (limited to 'spec/requests')
-rw-r--r--spec/requests/api/internal_spec.rb2
-rw-r--r--spec/requests/api/projects_spec.rb4
2 files changed, 3 insertions, 3 deletions
diff --git a/spec/requests/api/internal_spec.rb b/spec/requests/api/internal_spec.rb
index b537b6e1667..85c93f35c20 100644
--- a/spec/requests/api/internal_spec.rb
+++ b/spec/requests/api/internal_spec.rb
@@ -429,7 +429,7 @@ describe API::Internal do
context "archived project" do
before do
project.add_developer(user)
- project.archive!
+ ::Projects::UpdateService.new(project, user, archived: true).execute
end
context "git pull" do
diff --git a/spec/requests/api/projects_spec.rb b/spec/requests/api/projects_spec.rb
index 71e3436fa76..eb41750bf47 100644
--- a/spec/requests/api/projects_spec.rb
+++ b/spec/requests/api/projects_spec.rb
@@ -1677,7 +1677,7 @@ describe API::Projects do
context 'on an archived project' do
before do
- project.archive!
+ ::Projects::UpdateService.new(project, user, archived: true).execute
end
it 'remains archived' do
@@ -1713,7 +1713,7 @@ describe API::Projects do
context 'on an archived project' do
before do
- project.archive!
+ ::Projects::UpdateService.new(project, user, archived: true).execute
end
it 'unarchives the project' do