Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
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
Binh
erp5
Commits
3a625816
Commit
3a625816
authored
Mar 17, 2015
by
wenjie.zheng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp5_workflow_test_data: Add action_url in user action.
parent
62f23b36
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
98 additions
and
7 deletions
+98
-7
bt5/erp5_workflow_test_data/PathTemplateItem/workflow_module/testing_workflow/delete_action.xml
...teItem/workflow_module/testing_workflow/delete_action.xml
+25
-0
bt5/erp5_workflow_test_data/PathTemplateItem/workflow_module/testing_workflow/invalidate_action.xml
...em/workflow_module/testing_workflow/invalidate_action.xml
+26
-3
bt5/erp5_workflow_test_data/PathTemplateItem/workflow_module/testing_workflow/validate_action.xml
...Item/workflow_module/testing_workflow/validate_action.xml
+26
-3
bt5/erp5_workflow_test_data/PortalTypeTemplateItem/portal_types/ERP5Workflow%20Test%20Document.xml
...plateItem/portal_types/ERP5Workflow%20Test%20Document.xml
+3
-1
bt5/erp5_workflow_test_data/TestTemplateItem/portal_components/test.erp5.testWorkflowAndDCWorkflow.py
.../portal_components/test.erp5.testWorkflowAndDCWorkflow.py
+18
-0
No files found.
bt5/erp5_workflow_test_data/PathTemplateItem/workflow_module/testing_workflow/delete_action.xml
View file @
3a625816
...
@@ -48,6 +48,12 @@
...
@@ -48,6 +48,12 @@
<none/>
<none/>
</value>
</value>
</item>
</item>
<item>
<key>
<string>
guard
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<item>
<key>
<string>
guard_expression
</string>
</key>
<key>
<string>
guard_expression
</string>
</key>
<value>
<string>
python: True
</string>
</value>
<value>
<string>
python: True
</string>
</value>
...
@@ -81,4 +87,23 @@
...
@@ -81,4 +87,23 @@
</dictionary>
</dictionary>
</pickle>
</pickle>
</record>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"Guard"
module=
"Products.DCWorkflow.Guard"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
roles
</string>
</key>
<value>
<list>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
</ZopeData>
bt5/erp5_workflow_test_data/PathTemplateItem/workflow_module/testing_workflow/invalidate_action.xml
View file @
3a625816
...
@@ -18,9 +18,7 @@
...
@@ -18,9 +18,7 @@
</item>
</item>
<item>
<item>
<key>
<string>
actbox_url
</string>
</key>
<key>
<string>
actbox_url
</string>
</key>
<value>
<value>
<string>
python:${object_url}/Base_viewWorkflowActionDialog?workflow_action=invalidate_action
</string>
</value>
<none/>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
after_script_id
</string>
</key>
<key>
<string>
after_script_id
</string>
</key>
...
@@ -42,6 +40,12 @@
...
@@ -42,6 +40,12 @@
<none/>
<none/>
</value>
</value>
</item>
</item>
<item>
<key>
<string>
guard
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<item>
<key>
<string>
guard_expression
</string>
</key>
<key>
<string>
guard_expression
</string>
</key>
<value>
<string>
python: True
</string>
</value>
<value>
<string>
python: True
</string>
</value>
...
@@ -75,4 +79,23 @@
...
@@ -75,4 +79,23 @@
</dictionary>
</dictionary>
</pickle>
</pickle>
</record>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"Guard"
module=
"Products.DCWorkflow.Guard"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
roles
</string>
</key>
<value>
<list>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
</ZopeData>
bt5/erp5_workflow_test_data/PathTemplateItem/workflow_module/testing_workflow/validate_action.xml
View file @
3a625816
...
@@ -18,9 +18,7 @@
...
@@ -18,9 +18,7 @@
</item>
</item>
<item>
<item>
<key>
<string>
actbox_url
</string>
</key>
<key>
<string>
actbox_url
</string>
</key>
<value>
<value>
<string>
%(content_url)s/Base_viewWorkflowActionDialog?workflow_action=validate_action
</string>
</value>
<none/>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
after_script_id
</string>
</key>
<key>
<string>
after_script_id
</string>
</key>
...
@@ -52,6 +50,12 @@
...
@@ -52,6 +50,12 @@
<key>
<string>
groups
</string>
</key>
<key>
<string>
groups
</string>
</key>
<value>
<string>
()
</string>
</value>
<value>
<string>
()
</string>
</value>
</item>
</item>
<item>
<key>
<string>
guard
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<item>
<key>
<string>
guard_expression
</string>
</key>
<key>
<string>
guard_expression
</string>
</key>
<value>
<string>
python: True
</string>
</value>
<value>
<string>
python: True
</string>
</value>
...
@@ -98,4 +102,23 @@
...
@@ -98,4 +102,23 @@
</dictionary>
</dictionary>
</pickle>
</pickle>
</record>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"Guard"
module=
"Products.DCWorkflow.Guard"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
roles
</string>
</key>
<value>
<list>
<string>
Assignor
</string>
<string>
Assignee
</string>
<string>
Manager
</string>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
</ZopeData>
bt5/erp5_workflow_test_data/PortalTypeTemplateItem/portal_types/ERP5Workflow%20Test%20Document.xml
View file @
3a625816
...
@@ -21,7 +21,9 @@
...
@@ -21,7 +21,9 @@
<item>
<item>
<key>
<string>
erp5workflow_list
</string>
</key>
<key>
<string>
erp5workflow_list
</string>
</key>
<value>
<value>
<tuple/>
<tuple>
<string>
testing_workflow
</string>
</tuple>
</value>
</value>
</item>
</item>
<item>
<item>
...
...
bt5/erp5_workflow_test_data/TestTemplateItem/portal_components/test.erp5.testWorkflowAndDCWorkflow.py
View file @
3a625816
...
@@ -81,12 +81,30 @@ class TestERP5WorkflowMixin(ERP5TypeTestCase):
...
@@ -81,12 +81,30 @@ class TestERP5WorkflowMixin(ERP5TypeTestCase):
last_history
=
history_list
[
-
1
]
last_history
=
history_list
[
-
1
]
self
.
assertEqual
(
last_history
.
get
(
"error_message"
,
None
),
"foo error"
)
self
.
assertEqual
(
last_history
.
get
(
"error_message"
,
None
),
"foo error"
)
def
test_08_testUserActionDisplay
(
self
):
new_object
=
self
.
getTestObject
()
object_pt
=
new_object
.
getTypeInfo
()
self
.
assertTrue
(
hasattr
(
object_pt
,
'validate'
))
self
.
doActionFor
(
new_object
,
"validate"
)
self
.
assertTrue
(
hasattr
(
object_pt
,
'invalidate'
))
### Doesn't exist yet
### Doesn't exist yet
def
_testSimpleWorklist
(
self
):
def
_testSimpleWorklist
(
self
):
pass
pass
def
_testWorklistWithAnAssignee
(
self
):
def
_testWorklistWithAnAssignee
(
self
):
pass
pass
def
beforeTearDown
(
self
):
self
.
portal
=
self
.
getPortal
()
self
.
getWorkflowTool
().
setChainForPortalTypes
([
'ERP5Workflow Test Document'
],
())
self
.
workflow_module
=
self
.
portal
.
workflow_module
self
.
wf
=
self
.
workflow_module
.
_getOb
(
'testing_workflow'
)
type_test_object
=
self
.
portal
.
portal_types
.
_getOb
(
'ERP5Workflow Test Document'
)
type_test_object
.
edit
(
type_base_category_list
=
(
'validation_state'
,))
type_test_object
.
edit
(
type_erp5workflow_list
=
(
'testing_workflow'
,))
self
.
getWorkflowTool
().
setChainForPortalTypes
([
'ERP5Workflow Test Document'
],
())
class
TestERP5Workflow
(
TestERP5WorkflowMixin
):
class
TestERP5Workflow
(
TestERP5WorkflowMixin
):
"""
"""
Tests ERP5 Workflow.
Tests ERP5 Workflow.
...
...
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