Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
W
wendelin-telecom
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
Paul Graydon
wendelin-telecom
Commits
546a7e2e
Commit
546a7e2e
authored
Jan 14, 2025
by
Paul Graydon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wendelin_telecom_test: Add Data Supply Line security check in tests
parent
ed813d35
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
0 deletions
+10
-0
bt5/wendelin_telecom_test/TestTemplateItem/portal_components/test.erp5.testWendelinTelecom.py
...teItem/portal_components/test.erp5.testWendelinTelecom.py
+10
-0
No files found.
bt5/wendelin_telecom_test/TestTemplateItem/portal_components/test.erp5.testWendelinTelecom.py
View file @
546a7e2e
...
@@ -372,6 +372,7 @@ class WendelinTelecomTest(SecurityTestCase):
...
@@ -372,6 +372,7 @@ class WendelinTelecomTest(SecurityTestCase):
)
)
# Same as above for a Data Supply (required for computing security roles on users)
# Same as above for a Data Supply (required for computing security roles on users)
# Also the same for Data Supply Lines
self
.
checkDocumentPermissions
(
self
.
checkDocumentPermissions
(
user
,
user
,
ingestion_item_dict
[
'data_supply'
],
ingestion_item_dict
[
'data_supply'
],
...
@@ -379,6 +380,15 @@ class WendelinTelecomTest(SecurityTestCase):
...
@@ -379,6 +380,15 @@ class WendelinTelecomTest(SecurityTestCase):
user_is_admin
,
user_is_admin
,
user_is_admin
user_is_admin
)
)
for
data_supply_line
in
ingestion_item_dict
[
'data_supply'
]
\
.
contentValues
(
portal_type
=
'Data Supply Line'
):
self
.
checkDocumentPermissions
(
user
,
data_supply_line
,
same_project
or
user_is_admin
or
user_is_ingestor
,
user_is_admin
,
user_is_admin
)
# An administrator has all rights to a Data Ingestion (for management actions)
# An administrator has all rights to a Data Ingestion (for management actions)
# An ingestor also has all rights to a Data Ingestion (for managing ingestions)
# An ingestor also has all rights to a Data Ingestion (for managing ingestions)
...
...
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