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
1
Merge Requests
1
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
Romain Courteaud
slapos.core
Commits
db831385
Commit
db831385
authored
Sep 08, 2022
by
Rafael Monnerat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
slapos_jio_ui_test: Include Manager user
This is generally useful to debug as Manager
parent
0468138d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
39 additions
and
0 deletions
+39
-0
master/bt5/slapos_jio_ui_test/SkinTemplateItem/portal_skins/slapos_ui_test/ERP5Site_initSlapOSUITest.py
.../portal_skins/slapos_ui_test/ERP5Site_initSlapOSUITest.py
+38
-0
master/bt5/slapos_jio_ui_test/SkinTemplateItem/portal_skins/slapos_ui_test/ERP5Site_initSlapOSUITest.xml
...portal_skins/slapos_ui_test/ERP5Site_initSlapOSUITest.xml
+1
-0
No files found.
master/bt5/slapos_jio_ui_test/SkinTemplateItem/portal_skins/slapos_ui_test/ERP5Site_initSlapOSUITest.py
View file @
db831385
...
...
@@ -101,4 +101,42 @@ for reference in notification_message_to_enable:
portal
.
portal_catalog
.
getResultValue
(
validation_state
=
'draft'
,
**
search_kw
).
validate
()
# Create an manager user
try
:
demo_manager_user
=
context
.
person_module
[
"demo_manager_user"
]
except
KeyError
:
demo_manager_user
=
context
.
person_module
.
newContent
(
id
=
"demo_manager_user"
,
title
=
"Demo Manager Functional User"
,
portal_type
=
"Person"
,
email
=
"x@example.com"
)
try
:
demo_manager_assignment
=
demo_manager_user
[
"manager_assignment"
]
except
KeyError
:
demo_manager_assignment
=
demo_manager_user
.
newContent
(
id
=
"manager_assignment"
,
title
=
"Demo Manager Functional User Assignment"
,
portal_type
=
"Assignment"
,
)
demo_manager_assignment
.
setGroup
(
'company'
)
if
demo_manager_assignment
.
getValidationState
()
!=
"open"
:
demo_manager_assignment
.
open
()
try
:
demo_manager_login
=
demo_manager_user
[
"demo_manager_login"
]
except
KeyError
:
demo_manager_login
=
demo_manager_user
.
newContent
(
id
=
"demo_manager_login"
,
portal_type
=
"ERP5 Login"
,
reference
=
"demo_manager_functional_user"
)
demo_manager_login
.
setPassword
(
"czz4yt36mshT*"
)
if
demo_manager_login
.
getValidationState
()
!=
"validated"
:
demo_manager_login
.
validate
()
return
"Done."
master/bt5/slapos_jio_ui_test/SkinTemplateItem/portal_skins/slapos_ui_test/ERP5Site_initSlapOSUITest.xml
View file @
db831385
...
...
@@ -57,6 +57,7 @@
<value>
<tuple>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
...
...
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