Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Guillaume Hervier
slapos.core
Commits
b9120af9
Commit
b9120af9
authored
Nov 07, 2012
by
Łukasz Nowak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Test up to Organisation.
parent
7c712feb
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
4 deletions
+19
-4
master/bt5/slapos_erp5/TestTemplateItem/testSlapOSGroupRoleSecurity.py
...apos_erp5/TestTemplateItem/testSlapOSGroupRoleSecurity.py
+18
-3
master/bt5/slapos_erp5/bt/revision
master/bt5/slapos_erp5/bt/revision
+1
-1
No files found.
master/bt5/slapos_erp5/TestTemplateItem/testSlapOSGroupRoleSecurity.py
View file @
b9120af9
...
...
@@ -357,11 +357,26 @@ class TestImage(TestSlapOSGroupRoleSecurityMixin):
class
TestImageModule
(
TestSlapOSGroupRoleSecurityMixin
):
def
test
(
self
):
raise
NotImplementedError
module
=
self
.
portal
.
image_module
self
.
assertSecurityGroup
(
module
,
[
'R-COMPUTER'
,
'R-INSTANCE'
,
'R-MEMBER'
,
'zope'
,
'G-COMPANY'
],
False
)
self
.
assertRoles
(
module
,
'R-COMPUTER'
,
[
'Author'
])
self
.
assertRoles
(
module
,
'R-INSTANCE'
,
[
'Author'
])
self
.
assertRoles
(
module
,
'R-MEMBER'
,
[
'Author'
])
self
.
assertRoles
(
module
,
'G-COMPANY'
,
[
'Author'
,
'Auditor'
])
self
.
assertRoles
(
module
,
'zope'
,
[
'Owner'
])
class
TestOrganisation
(
TestSlapOSGroupRoleSecurityMixin
):
def
test
(
self
):
raise
NotImplementedError
def
test_GroupCompany
(
self
):
organisation
=
self
.
portal
.
organisation_module
.
newContent
(
portal_type
=
'Organisation'
)
organisation
.
updateLocalRolesOnSecurityGroups
()
self
.
assertSecurityGroup
(
organisation
,
[
'G-COMPANY'
,
self
.
user_id
,
'R-MEMBER'
],
False
)
self
.
assertRoles
(
organisation
,
'G-COMPANY'
,
[
'Assignor'
])
self
.
assertRoles
(
organisation
,
'R-MEMBER'
,
[
'Auditor'
])
test_Member
=
test_GroupCompany
class
TestOrganisationModule
(
TestSlapOSGroupRoleSecurityMixin
):
def
test
(
self
):
...
...
master/bt5/slapos_erp5/bt/revision
View file @
b9120af9
50
\ No newline at end of file
51
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment