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
alecs_myu
erp5
Commits
466ba690
Commit
466ba690
authored
Jan 11, 2017
by
Ayush Tiwari
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bt5_prototype: Add tests to check property item in BP
parent
148ca436
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
34 additions
and
1 deletion
+34
-1
bt5/erp5_business_package/TestTemplateItem/portal_components/test.erp5.testBusinessPackage.py
...teItem/portal_components/test.erp5.testBusinessPackage.py
+31
-0
bt5/erp5_business_package/TestTemplateItem/portal_components/test.erp5.testBusinessPackage.xml
...eItem/portal_components/test.erp5.testBusinessPackage.xml
+3
-1
No files found.
bt5/erp5_business_package/TestTemplateItem/portal_components/test.erp5.testBusinessPackage.py
View file @
466ba690
...
@@ -306,3 +306,34 @@ class TestBusinessPackage(ERP5TypeTestCase):
...
@@ -306,3 +306,34 @@ class TestBusinessPackage(ERP5TypeTestCase):
package_object_count
=
len
(
package_object_id_list
)
package_object_count
=
len
(
package_object_id_list
)
self
.
assertEquals
(
total_object_count
,
package_object_count
)
self
.
assertEquals
(
total_object_count
,
package_object_count
)
self
.
assertEquals
(
object_id_list
,
package_object_id_list
)
self
.
assertEquals
(
object_id_list
,
package_object_id_list
)
def
test_addObjectPropertyTemplateItemInPackage
(
self
):
"""
Add ObjectPropertyTemplateItem to Business Package with the hash
"""
package
=
self
.
_createBusinessPackage
()
relative_url
=
'portal_catalog/erp5_mysql_innodb'
file_path_list
=
[
relative_url
]
catalog_object
=
self
.
portal
.
unrestrictedTraverse
(
relative_url
)
object_property_list
=
[]
for
property_id
in
catalog_object
.
propertyIds
():
object_property_list
.
append
(
'%s | %s'
%
(
relative_url
,
property_id
))
package
.
edit
(
template_path_list
=
file_path_list
)
package
.
edit
(
template_object_property_list
=
object_property_list
)
self
.
tic
()
self
.
_buildAndExportBusinessPackage
(
package
)
self
.
tic
()
# Check for presence of catalog objects from all the catalogs mentioned in
# the folder path list
built_package
=
self
.
portal
.
_getOb
(
package
.
getId
())
def
test_udpateInstallationStateOnlyForBusinessPackage
(
self
):
"""
Updating Business Package with the changed installation state and trying
to show the diff between the two installation state
"""
pass
bt5/erp5_business_package/TestTemplateItem/portal_components/test.erp5.testBusinessPackage.xml
View file @
466ba690
...
@@ -45,7 +45,9 @@
...
@@ -45,7 +45,9 @@
<item>
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<value>
<tuple/>
<tuple>
<string>
W:332, 4: Unused variable \'built_package\' (unused-variable)
</string>
</tuple>
</value>
</value>
</item>
</item>
<item>
<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