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
Labels
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
Rafael Monnerat
slapos.core
Commits
75667df8
Commit
75667df8
authored
Jun 27, 2011
by
Łukasz Nowak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Validate required notification messages.
parent
02131694
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
0 deletions
+15
-0
master/product/Vifib/tests/VifibMixin.py
master/product/Vifib/tests/VifibMixin.py
+15
-0
No files found.
master/product/Vifib/tests/VifibMixin.py
View file @
75667df8
...
...
@@ -41,6 +41,9 @@ REQUIRED_RULE_REFERENCE_LIST = [
'default_order_rule'
,
]
REQUIRED_NOTIFICATION_MESSAGE_REFERENCE_LIST
=
[
'crendential_request-confirmation-without-password'
,
]
class
testVifibMixin
(
ERP5TypeTestCase
):
"""
...
...
@@ -183,6 +186,17 @@ class testVifibMixin(ERP5TypeTestCase):
if
default_system_preference
.
getPreferenceState
()
==
'disabled'
:
default_system_preference
.
enable
()
def
setupNotificationModule
(
self
):
module
=
self
.
portal
.
notification_message_module
isTransitionPossible
=
self
.
portal
.
portal_workflow
.
isTransitionPossible
for
reference
in
REQUIRED_NOTIFICATION_MESSAGE_REFERENCE_LIST
:
for
message
in
module
.
searchFolder
(
portal_type
=
'Notification Message'
,
reference
=
reference
):
message
=
message
.
getObject
()
if
isTransitionPossible
(
message
,
'validate'
):
message
.
validate
()
def
setupRuleTool
(
self
):
"""Validates newest version of each rule from REQUIRED_RULE_REFERENCE_LIST"""
rule_tool
=
self
.
portal
.
portal_rules
...
...
@@ -252,6 +266,7 @@ class testVifibMixin(ERP5TypeTestCase):
self
.
setPreference
()
self
.
setSystemPreference
()
self
.
setupRuleTool
()
self
.
setupNotificationModule
()
self
.
openAssignments
()
transaction
.
commit
()
self
.
tic
()
...
...
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