Commit e6e672f0 authored by Fabio Papa's avatar Fabio Papa

Modify API spec to expect a maintainer to be able to create subgroup

parent 11f998d9
......@@ -803,10 +803,10 @@ describe API::Groups do
group2.add_maintainer(user1)
end
it 'cannot create subgroups' do
it 'can create subgroups' do
post api("/groups", user1), params: { parent_id: group2.id, name: 'foo', path: 'foo' }
expect(response).to have_gitlab_http_status(403)
expect(response).to have_gitlab_http_status(201)
end
end
end
......
......@@ -19,10 +19,6 @@ RSpec.shared_context 'GroupPolicy context' do
let(:reporter_permissions) { [:admin_label] }
let(:developer_permissions) { [:admin_milestone] }
let(:maintainer_permissions) do
%i[
create_projects
read_cluster create_cluster update_cluster admin_cluster add_cluster
]
[
:create_projects,
:read_cluster,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment