summaryrefslogtreecommitdiff
path: root/spec/services/projects
diff options
context:
space:
mode:
authorLuke Duncalfe <lduncalfe@eml.cc>2019-06-18 13:44:43 +1200
committerLuke Duncalfe <lduncalfe@eml.cc>2019-08-21 11:39:41 +1200
commit37b17fa61a1fb5efe5942ab2cb27b15685bf905e (patch)
treee9883b80bc7fe72b7e360c1f4bf32e889166b811 /spec/services/projects
parent330cbddec30840a72a52aade383286e58545ce98 (diff)
downloadgitlab-ce-37b17fa61a1fb5efe5942ab2cb27b15685bf905e.tar.gz
Add service classes for mutating AwardEmoji
Adding, destroying and toggling emoji previously lacked services and instead were performed through methods called on Awardable models. This led to inconsistencies where relevant todos would be marked as done only when emoji were awarded through our controllers, but not through the API. Todos could also be marked as done when an emoji was being removed. Behaviour changes - Awarding emoji through the API will now mark a relevant Todo as done - Toggling an emoji off (destroying it) through our controllers will no longer mark a relevant Todo as done Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/63372
Diffstat (limited to 'spec/services/projects')
-rw-r--r--spec/services/projects/create_service_spec.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/spec/services/projects/create_service_spec.rb b/spec/services/projects/create_service_spec.rb
index b0b74407812..d4fa62fa85d 100644
--- a/spec/services/projects/create_service_spec.rb
+++ b/spec/services/projects/create_service_spec.rb
@@ -78,6 +78,7 @@ describe Projects::CreateService, '#execute' do
expect(project).to be_valid
expect(project.owner).to eq(group)
expect(project.namespace).to eq(group)
+ expect(project.team.owners).to include(user)
expect(user.authorized_projects).to include(project)
end
end