Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
officejs-appstore
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
nexedi
officejs-appstore
Commits
332117e4
Commit
332117e4
authored
Mar 31, 2021
by
Roque
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
officejs_test: document module hbtree migration tests
parent
99ab115a
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
41 additions
and
17 deletions
+41
-17
bt5/officejs_test/TestTemplateItem/portal_components/test.erp5.testOfficeJSAppstoreConfigurator.py
..._components/test.erp5.testOfficeJSAppstoreConfigurator.py
+21
-1
bt5/officejs_test/TestTemplateItem/portal_components/test.erp5.testOfficeJSAppstoreConfigurator.xml
...components/test.erp5.testOfficeJSAppstoreConfigurator.xml
+20
-16
No files found.
bt5/officejs_test/TestTemplateItem/portal_components/test.erp5.testOfficeJSAppstoreConfigurator.py
View file @
332117e4
...
@@ -76,6 +76,27 @@ class TestSlapOSConfigurator(testOfficeJSAppstoreMixin):
...
@@ -76,6 +76,27 @@ class TestSlapOSConfigurator(testOfficeJSAppstoreMixin):
conversion_url
=
"https://cloudooo.erp5.net/"
conversion_url
=
"https://cloudooo.erp5.net/"
self
.
assertEqual
(
preference_tool
.
getPreferredDocumentConversionServerUrl
(),
conversion_url
)
self
.
assertEqual
(
preference_tool
.
getPreferredDocumentConversionServerUrl
(),
conversion_url
)
def
testDocumentModuleMigration
(
self
):
"""
check document module folder was migrated to HBTree
"""
document_module
=
self
.
portal
.
document_module
self
.
assertEqual
(
document_module
.
getIdGenerator
(),
'_generatePerDayId'
)
self
.
assertEqual
(
document_module
.
isBTree
(),
False
)
self
.
assertEqual
(
document_module
.
isHBTree
(),
True
)
#check existing documents with custom ids were not migrated
existing_doc
=
self
.
portal
.
portal_catalog
.
getResultValue
(
portal_type
=
'File'
,
reference
=
'data/application_sample.json'
)
self
.
assertEqual
(
existing_doc
.
getId
(),
'store_officejs_data_application_sample_json'
)
#check new documents use new id format
doc
=
document_module
.
newContent
()
self
.
tic
()
date
=
doc
.
getCreationDate
().
Date
().
replace
(
'/'
,
''
)
self
.
assertTrue
(
doc
.
getId
().
startswith
(
'%s-'
%
date
))
def
notestModuleHasIdGeneratorByDay
(
self
):
def
notestModuleHasIdGeneratorByDay
(
self
):
""" Ensure the Constraint sets appropriate id generator on all modules.
""" Ensure the Constraint sets appropriate id generator on all modules.
"""
"""
...
@@ -169,7 +190,6 @@ class TestSlapOSConfigurator(testOfficeJSAppstoreMixin):
...
@@ -169,7 +190,6 @@ class TestSlapOSConfigurator(testOfficeJSAppstoreMixin):
'workflow_module'
,
'workflow_module'
,
])
])
def
testConfiguredBusinessTemplateList
(
self
):
def
testConfiguredBusinessTemplateList
(
self
):
""" Make sure Installed business Templates are
""" Make sure Installed business Templates are
what it is expected. """
what it is expected. """
...
...
bt5/officejs_test/TestTemplateItem/portal_components/test.erp5.testOfficeJSAppstoreConfigurator.xml
View file @
332117e4
...
@@ -100,24 +100,28 @@
...
@@ -100,24 +100,28 @@
</record>
</record>
<record
id=
"4"
aka=
"AAAAAAAAAAQ="
>
<record
id=
"4"
aka=
"AAAAAAAAAAQ="
>
<pickle>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.
patches.WorkflowTool
"
/>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.
Workflow
"
/>
</pickle>
</pickle>
<pickle>
<pickle>
<tuple>
<dictionary>
<none/>
<item>
<list>
<key>
<string>
_log
</string>
</key>
<dictionary>
<value>
<item>
<list>
<key>
<string>
action
</string>
</key>
<dictionary>
<value>
<string>
validate
</string>
</value>
<item>
</item>
<key>
<string>
action
</string>
</key>
<item>
<value>
<string>
validate
</string>
</value>
<key>
<string>
validation_state
</string>
</key>
</item>
<value>
<string>
validated
</string>
</value>
<item>
</item>
<key>
<string>
validation_state
</string>
</key>
</dictionary>
<value>
<string>
validated
</string>
</value>
</list>
</item>
</tuple>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</pickle>
</record>
</record>
</ZopeData>
</ZopeData>
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