stable

Clone or download

Read-only

Import patterns permissions

This is part of story #9534: import fine grained permissions How to test this: In a project.xml file with a git repository export, update the permissions tag as follow: <permissions> ... <fine_grained enabled="1" use_regexp="1"> <pattern value="*"type="branch"> <write> <ugroup>project_members</ugroup> </write> <wplus> <ugroup>project_admins</ugroup> </wplus> </pattern> <pattern value="branch[0-9]" type="branch" /> <pattern value="*" type="tag /> </fine_grained> </permissions> After importing the project in the Settings > Access control, the Git repository should use fine-grained permissions with regexp, and the three patterns must be imported with there permissions for the first one. If you disable regexp usage, the second pattern must not be import. Change-Id: I8f41304728ecb85b9a2bca25ff7aa9f8890b9b6d

Modified Files

Name
M plugins/git/include/Git/Permissions/FineGrainedPermissionFactory.php +24 −16 Go to diff View file
M plugins/git/include/XmlUgroupRetriever.php +47 −9 Go to diff View file
M plugins/git/include/gitPlugin.class.php +26 −2 Go to diff View file
M plugins/git/tests/Git/Permissions/FineGrainedPermissionFactoryTest.php +2 −1 Go to diff View file
A plugins/git/tests/XmlUgroupRetrieverTest.php +146 −0 Go to diff View file
M plugins/git/tests/rest/GitDataBuilder.php +3 −1 Go to diff View file
M src/common/xml/resources/git-definition.rnc +3 −1 Go to diff View file
M src/common/xml/resources/project/git-definition.rng +18 −0 Go to diff View file