Commit 84503b42 authored by Sven Franck's avatar Sven Franck

erp5_corporate_identity_test: make sure a conversion server url is set

parent 4d569562
......@@ -27,7 +27,8 @@ Note:
<tal:block metal:use-macro="here/Zuite_CommonTemplate/macros/init" />
<tal:block tal:define="portal here/portal_url/getPortalObject;
caller python: getattr(context, 'Zuite_setSkipSave', None);
no_file_update python: caller() if caller is not None else True">
no_file_update python: caller() if caller is not None else True;
no_file_update python: True;">
<tr>
<td>open</td>
<td>${base_url}/bar_module/ListBoxZuite_reset</td>
......@@ -40,12 +41,12 @@ Note:
</tr>
<tr>
<td>open</td>
<td>${base_url}/Zuite_setupTemplateTest</td>
<td>${base_url}/Zuite_setPreferredTextEditor</td>
<td></td>
</tr>
<tr>
<td>assertTextPresent</td>
<td>Ok</td>
<td>Editor set to Textarea.</td>
<td></td>
</tr>
<tr>
......@@ -53,6 +54,18 @@ Note:
<td tal:content="python: ''.join(['skipping save: ', str(no_file_update)])"></td>
<td></td>
</tr>
<tal:block tal:condition="python: no_file_update == True">
<tr>
<td>open</td>
<td>${base_url}/Zuite_setConversionServerUrl</td>
<td></td>
</tr>
<tr>
<td>assertTextPresent</td>
<td>Conversion Server Url set.</td>
<td></td>
</tr>
</tal:block>
<tr>
<td>echo</td>
<td>ACTION => EXPORT</td>
......@@ -767,28 +780,23 @@ Note:
<td>name=field_format</td>
<td>index=1</td>
</tr>
<tr>
<td>waitForCouscous0</td>
<td></td>
<td></td>
</tr>
<tr>
<td>clickAndWait</td>
<td>name=Base_callDialogMethod:method</td>
<td></td>
</tr>
<tr>
<td>waitForCouscous</td>
<td>waitForPageToLoad</td>
<td></td>
<td></td>
</tr>
<tr>
<td>waitForPageToLoad</td>
<td>waitForTitle</td>
<td></td>
<td></td>
</tr>
<tr>
<td>waitForCouscousToo</td>
<td>assertTitle</td>
<td></td>
<td></td>
</tr>
......
"""
================================================================================
Set preference for template test to textarea
================================================================================
"""
# parameters (* default)
# ------------------------------------------------------------------------------
# make sure cloudooo is set for pdf conversions on system_preference
conversion_server_url_list = context.portal_preferences.getPreferredDocumentConversionServerUrlList() or ["https://cloudooo.erp5.net"]
system_preference = context.portal_preferences.default_system_preference
system_preference.setPreferredDocumentConversionServerUrlList(conversion_server_url_list)
return "Conversion Server Url set."
......@@ -54,7 +54,7 @@
</item>
<item>
<key> <string>id</string> </key>
<value> <string>Zuite_setupTemplateTest</string> </value>
<value> <string>Zuite_setConversionServerUrl</string> </value>
</item>
</dictionary>
</pickle>
......
......@@ -6,27 +6,8 @@ Set preference for template test to textarea
# parameters (* default)
# ------------------------------------------------------------------------------
# inspired by erp5_user_tutorial_ui_test
# force text_area editor
context.Zuite_setPreference('')
pref = context.portal_preferences.erp5_ui_test_preference
pref.setPreferredTextEditor('text_area')
#portal = context.getPortalObject()
#zuite_preference_id = "zuite_erp5_ui_test_preference"
#isTransitionPossible = portal.portal_workflow.isTransitionPossible
#
#preference = getattr(portal.portal_preferences, zuite_preference_id, None)
#if preference is None:
# preference = context.portal_preferences.newContent(
# portal_type="Preference",
# id=zuite_preference_id
# )
# if isTransitionPossible(preference, "enable"):
# preference.enable()
#
#preference.setPreferredTextEditor("text_area")
#preference.setPreferredSourceCodeEditor("text_area")
#portal.portal_caches.clearAllCache()
return "Ok"
preference = context.portal_preferences.erp5_ui_test_preference
preference.setPreferredTextEditor('text_area')
return "Editor set to Textarea."
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </value>
</item>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_container</string> </key>
<value> <string>container</string> </value>
</item>
<item>
<key> <string>name_context</string> </key>
<value> <string>context</string> </value>
</item>
<item>
<key> <string>name_m_self</string> </key>
<value> <string>script</string> </value>
</item>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>Zuite_setPreferredTextEditor</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment