From 910ce80bcc64c0bfd84e32004913840dd196bb5a Mon Sep 17 00:00:00 2001 From: Fabien Morin <fabien@nexedi.com> Date: Wed, 1 Oct 2008 17:18:10 +0000 Subject: [PATCH] 2008-10-01 fabien * initial version git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@23954 20353a03-c40f-0410-a6d1-a30d3c3de9de --- .../portal_skins/erp5_ui_test_core.xml | 29 +++ .../BTZuite_setPreference.xml | 139 ++++++++++++++ .../erp5_ui_test_core/TestTool_getResults.xml | 131 +++++++++++++ .../TestTool_reportResult.xml | 181 ++++++++++++++++++ .../erp5_ui_test_core/Zuite_setBaseUrl.xml | 130 +++++++++++++ .../Zuite_waitForActivities.xml | 141 ++++++++++++++ .../erp5_ui_test_core/user-extensions.js.xml | 103 ++++++++++ bt5/erp5_ui_test_core/bt/categories_list | 0 bt5/erp5_ui_test_core/bt/change_log | 2 + bt5/erp5_ui_test_core/bt/comment | 0 bt5/erp5_ui_test_core/bt/copyright_list | 1 + bt5/erp5_ui_test_core/bt/dependency_list | 2 + bt5/erp5_ui_test_core/bt/description | 1 + bt5/erp5_ui_test_core/bt/license | 1 + bt5/erp5_ui_test_core/bt/maintainer_list | 1 + bt5/erp5_ui_test_core/bt/provision_list | 0 bt5/erp5_ui_test_core/bt/publication_url | 1 + bt5/erp5_ui_test_core/bt/revision | 1 + bt5/erp5_ui_test_core/bt/short_title | 1 + .../bt/template_action_path_list | 0 .../bt/template_base_category_list | 0 .../bt/template_catalog_datetime_key_list | 0 .../bt/template_catalog_full_text_key_list | 0 .../bt/template_catalog_keyword_key_list | 0 .../bt/template_catalog_local_role_key_list | 0 .../bt/template_catalog_method_id_list | 0 .../bt/template_catalog_multivalue_key_list | 0 .../bt/template_catalog_related_key_list | 0 .../bt/template_catalog_request_key_list | 0 .../bt/template_catalog_result_key_list | 0 .../bt/template_catalog_result_table_list | 0 .../bt/template_catalog_role_key_list | 0 .../bt/template_catalog_scriptable_key_list | 0 .../bt/template_catalog_topic_key_list | 0 .../bt/template_constraint_id_list | 0 .../bt/template_document_id_list | 0 .../bt/template_extension_id_list | 0 .../bt/template_format_version | 1 + .../bt/template_local_roles_list | 0 .../bt/template_message_translation_list | 0 .../bt/template_module_id_list | 0 bt5/erp5_ui_test_core/bt/template_path_list | 0 ...late_portal_type_allowed_content_type_list | 0 .../template_portal_type_base_category_list | 0 ...plate_portal_type_hidden_content_type_list | 0 .../bt/template_portal_type_id_list | 0 .../template_portal_type_property_sheet_list | 0 .../bt/template_portal_type_roles_list | 0 .../template_portal_type_workflow_chain_list | 0 .../bt/template_preference_list | 0 .../bt/template_product_id_list | 0 .../bt/template_property_sheet_id_list | 0 bt5/erp5_ui_test_core/bt/template_role_list | 0 .../bt/template_site_property_id_list | 0 .../bt/template_skin_id_list | 1 + .../bt/template_test_id_list | 0 .../bt/template_tool_id_list | 0 ...template_update_business_template_workflow | 1 + bt5/erp5_ui_test_core/bt/template_update_tool | 1 + .../bt/template_workflow_id_list | 0 bt5/erp5_ui_test_core/bt/title | 1 + bt5/erp5_ui_test_core/bt/version | 1 + 62 files changed, 871 insertions(+) create mode 100644 bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core.xml create mode 100644 bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/BTZuite_setPreference.xml create mode 100644 bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/TestTool_getResults.xml create mode 100644 bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/TestTool_reportResult.xml create mode 100644 bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/Zuite_setBaseUrl.xml create mode 100644 bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/Zuite_waitForActivities.xml create mode 100644 bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/user-extensions.js.xml create mode 100644 bt5/erp5_ui_test_core/bt/categories_list create mode 100644 bt5/erp5_ui_test_core/bt/change_log create mode 100644 bt5/erp5_ui_test_core/bt/comment create mode 100644 bt5/erp5_ui_test_core/bt/copyright_list create mode 100644 bt5/erp5_ui_test_core/bt/dependency_list create mode 100644 bt5/erp5_ui_test_core/bt/description create mode 100644 bt5/erp5_ui_test_core/bt/license create mode 100644 bt5/erp5_ui_test_core/bt/maintainer_list create mode 100644 bt5/erp5_ui_test_core/bt/provision_list create mode 100644 bt5/erp5_ui_test_core/bt/publication_url create mode 100644 bt5/erp5_ui_test_core/bt/revision create mode 100644 bt5/erp5_ui_test_core/bt/short_title create mode 100644 bt5/erp5_ui_test_core/bt/template_action_path_list create mode 100644 bt5/erp5_ui_test_core/bt/template_base_category_list create mode 100644 bt5/erp5_ui_test_core/bt/template_catalog_datetime_key_list create mode 100644 bt5/erp5_ui_test_core/bt/template_catalog_full_text_key_list create mode 100644 bt5/erp5_ui_test_core/bt/template_catalog_keyword_key_list create mode 100644 bt5/erp5_ui_test_core/bt/template_catalog_local_role_key_list create mode 100644 bt5/erp5_ui_test_core/bt/template_catalog_method_id_list create mode 100644 bt5/erp5_ui_test_core/bt/template_catalog_multivalue_key_list create mode 100644 bt5/erp5_ui_test_core/bt/template_catalog_related_key_list create mode 100644 bt5/erp5_ui_test_core/bt/template_catalog_request_key_list create mode 100644 bt5/erp5_ui_test_core/bt/template_catalog_result_key_list create mode 100644 bt5/erp5_ui_test_core/bt/template_catalog_result_table_list create mode 100644 bt5/erp5_ui_test_core/bt/template_catalog_role_key_list create mode 100644 bt5/erp5_ui_test_core/bt/template_catalog_scriptable_key_list create mode 100644 bt5/erp5_ui_test_core/bt/template_catalog_topic_key_list create mode 100644 bt5/erp5_ui_test_core/bt/template_constraint_id_list create mode 100644 bt5/erp5_ui_test_core/bt/template_document_id_list create mode 100644 bt5/erp5_ui_test_core/bt/template_extension_id_list create mode 100644 bt5/erp5_ui_test_core/bt/template_format_version create mode 100644 bt5/erp5_ui_test_core/bt/template_local_roles_list create mode 100644 bt5/erp5_ui_test_core/bt/template_message_translation_list create mode 100644 bt5/erp5_ui_test_core/bt/template_module_id_list create mode 100644 bt5/erp5_ui_test_core/bt/template_path_list create mode 100644 bt5/erp5_ui_test_core/bt/template_portal_type_allowed_content_type_list create mode 100644 bt5/erp5_ui_test_core/bt/template_portal_type_base_category_list create mode 100644 bt5/erp5_ui_test_core/bt/template_portal_type_hidden_content_type_list create mode 100644 bt5/erp5_ui_test_core/bt/template_portal_type_id_list create mode 100644 bt5/erp5_ui_test_core/bt/template_portal_type_property_sheet_list create mode 100644 bt5/erp5_ui_test_core/bt/template_portal_type_roles_list create mode 100644 bt5/erp5_ui_test_core/bt/template_portal_type_workflow_chain_list create mode 100644 bt5/erp5_ui_test_core/bt/template_preference_list create mode 100644 bt5/erp5_ui_test_core/bt/template_product_id_list create mode 100644 bt5/erp5_ui_test_core/bt/template_property_sheet_id_list create mode 100644 bt5/erp5_ui_test_core/bt/template_role_list create mode 100644 bt5/erp5_ui_test_core/bt/template_site_property_id_list create mode 100644 bt5/erp5_ui_test_core/bt/template_skin_id_list create mode 100644 bt5/erp5_ui_test_core/bt/template_test_id_list create mode 100644 bt5/erp5_ui_test_core/bt/template_tool_id_list create mode 100644 bt5/erp5_ui_test_core/bt/template_update_business_template_workflow create mode 100644 bt5/erp5_ui_test_core/bt/template_update_tool create mode 100644 bt5/erp5_ui_test_core/bt/template_workflow_id_list create mode 100644 bt5/erp5_ui_test_core/bt/title create mode 100644 bt5/erp5_ui_test_core/bt/version diff --git a/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core.xml b/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core.xml new file mode 100644 index 0000000000..c8692e9145 --- /dev/null +++ b/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core.xml @@ -0,0 +1,29 @@ +<?xml version="1.0"?> +<ZopeData> + <record id="1" aka="AAAAAAAAAAE="> + <pickle> + <tuple> + <global name="Folder" module="OFS.Folder"/> + <tuple/> + </tuple> + </pickle> + <pickle> + <dictionary> + <item> + <key> <string>_objects</string> </key> + <value> + <tuple/> + </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>erp5_ui_test_core</string> </value> + </item> + <item> + <key> <string>title</string> </key> + <value> <string></string> </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/BTZuite_setPreference.xml b/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/BTZuite_setPreference.xml new file mode 100644 index 0000000000..b6948ab186 --- /dev/null +++ b/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/BTZuite_setPreference.xml @@ -0,0 +1,139 @@ +<?xml version="1.0"?> +<ZopeData> + <record id="1" aka="AAAAAAAAAAE="> + <pickle> + <tuple> + <global name="PythonScript" module="Products.PythonScripts.PythonScript"/> + <tuple/> + </tuple> + </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>_body</string> </key> + <value> <string>"""Set subversion working copy list and enable preference.\n +\n +This script is called by Products.ERP5Type.tests.runFunctionalTest to set\n +subversion working copy paths. It\'s not meant to be called by zelenium tests.\n +"""\n +\n +pref = getattr(context.portal_preferences, "erp5_ui_test_preference", None)\n +if pref is None:\n + pref = context.portal_preferences.newContent(id="erp5_ui_test_preference", portal_type="Preference")\n +pref.setPreferredSubversionWorkingCopyList(tuple(working_copy_list.split(\',\')))\n +pref.enable()\n +\n +return \'Set Preference Successfully.\'\n +</string> </value> + </item> + <item> + <key> <string>_code</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_params</string> </key> + <value> <string>working_copy_list</string> </value> + </item> + <item> + <key> <string>errors</string> </key> + <value> + <tuple/> + </value> + </item> + <item> + <key> <string>func_code</string> </key> + <value> + <object> + <klass> + <global name="FuncCode" module="Shared.DC.Scripts.Signature"/> + </klass> + <tuple/> + <state> + <dictionary> + <item> + <key> <string>co_argcount</string> </key> + <value> <int>1</int> </value> + </item> + <item> + <key> <string>co_varnames</string> </key> + <value> + <tuple> + <string>working_copy_list</string> + <string>getattr</string> + <string>_getattr_</string> + <string>context</string> + <string>None</string> + <string>pref</string> + <string>tuple</string> + </tuple> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>func_defaults</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>BTZuite_setPreference</string> </value> + </item> + <item> + <key> <string>warnings</string> </key> + <value> + <tuple/> + </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/TestTool_getResults.xml b/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/TestTool_getResults.xml new file mode 100644 index 0000000000..5053f0b66f --- /dev/null +++ b/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/TestTool_getResults.xml @@ -0,0 +1,131 @@ +<?xml version="1.0"?> +<ZopeData> + <record id="1" aka="AAAAAAAAAAE="> + <pickle> + <tuple> + <global name="PythonScript" module="Products.PythonScripts.PythonScript"/> + <tuple/> + </tuple> + </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>_body</string> </key> + <value> <string>portal_tests = container.portal_tests\n +results = [portal_tests.absolute_url() + \'/\' + e for e in portal_tests.objectIds(\'Zuite Results\')]\n +results.reverse()\n +return \'\\n\'.join(results) + \'\\n\'\n +</string> </value> + </item> + <item> + <key> <string>_code</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_params</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>errors</string> </key> + <value> + <tuple/> + </value> + </item> + <item> + <key> <string>func_code</string> </key> + <value> + <object> + <klass> + <global name="FuncCode" module="Shared.DC.Scripts.Signature"/> + </klass> + <tuple/> + <state> + <dictionary> + <item> + <key> <string>co_argcount</string> </key> + <value> <int>0</int> </value> + </item> + <item> + <key> <string>co_varnames</string> </key> + <value> + <tuple> + <string>_getattr_</string> + <string>container</string> + <string>portal_tests</string> + <string>append</string> + <string>$append0</string> + <string>_getiter_</string> + <string>e</string> + <string>results</string> + </tuple> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>func_defaults</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>TestTool_getResults</string> </value> + </item> + <item> + <key> <string>warnings</string> </key> + <value> + <tuple/> + </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/TestTool_reportResult.xml b/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/TestTool_reportResult.xml new file mode 100644 index 0000000000..2b2d14caab --- /dev/null +++ b/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/TestTool_reportResult.xml @@ -0,0 +1,181 @@ +<?xml version="1.0"?> +<ZopeData> + <record id="1" aka="AAAAAAAAAAE="> + <pickle> + <tuple> + <global name="PythonScript" module="Products.PythonScripts.PythonScript"/> + <tuple/> + </tuple> + </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>_body</string> </key> + <value> <string encoding="cdata"><![CDATA[ + +# This script is called when you invoke a browser with "?auto=true" to portal_tests.\n +# FIXME: this script should send the result by email.\n +\n +get = request.form.get\n +\n +# Summary.\n +result = [\'Report on Functional Tests\', \'\']\n +result.append(\'Passed: %s\' % (get(\'result\').lower() == \'passed\' and \'Yes\' or \'No\'))\n +result.append(\'Total Time: %s\' % get(\'totalTime\'))\n +result.append(\'Passed Tests: %s\' % get(\'numTestPasses\'))\n +result.append(\'Failed Tests: %s\' % get(\'numTestFailures\'))\n +result.append(\'Passed Commands: %s\' % get(\'numCommandPasses\'))\n +result.append(\'Failed Commands: %s\' % get(\'numCommandFailures\'))\n +result.append(\'Commands with Errors: %s\' % get(\'numCommandErrors\'))\n +result.append(\'\')\n +\n +# Details.\n +table_list = []\n +for key in request.form.keys():\n + if key.startswith(\'testTable\'):\n + prefix, num = key.split(\'.\')\n + table_list.append((prefix, int(num)))\n +table_list.sort()\n +for table in table_list:\n + key = \'%s.%d\' % table\n + html = get(key)\n +\n + # Ugly, but get the title somehow.\n + i = html.index(\'<td\')\n + start = html.index(\'>\', i) + 1\n + end = html.index(\'<\', start)\n + title = html[start:end]\n +\n + # Count passes and failures.\n + num_passed_commands = html.count(\'bgcolor="#cfffcf"\', end)\n + num_failed_commands = html.count(\'bgcolor="#ffcfcf"\', end)\n + result.append(\'%s: %d passed, %d failed\' % (title, num_passed_commands, num_failed_commands))\n +\n +return \'\\n\'.join(result)\n + + +]]></string> </value> + </item> + <item> + <key> <string>_code</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_params</string> </key> + <value> <string>request</string> </value> + </item> + <item> + <key> <string>errors</string> </key> + <value> + <tuple/> + </value> + </item> + <item> + <key> <string>func_code</string> </key> + <value> + <object> + <klass> + <global name="FuncCode" module="Shared.DC.Scripts.Signature"/> + </klass> + <tuple/> + <state> + <dictionary> + <item> + <key> <string>co_argcount</string> </key> + <value> <int>1</int> </value> + </item> + <item> + <key> <string>co_varnames</string> </key> + <value> + <tuple> + <string>request</string> + <string>_getattr_</string> + <string>get</string> + <string>result</string> + <string>table_list</string> + <string>_getiter_</string> + <string>key</string> + <string>prefix</string> + <string>num</string> + <string>int</string> + <string>table</string> + <string>html</string> + <string>i</string> + <string>start</string> + <string>end</string> + <string>_getitem_</string> + <string>title</string> + <string>num_passed_commands</string> + <string>num_failed_commands</string> + </tuple> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>func_defaults</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>TestTool_reportResult</string> </value> + </item> + <item> + <key> <string>warnings</string> </key> + <value> + <tuple/> + </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/Zuite_setBaseUrl.xml b/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/Zuite_setBaseUrl.xml new file mode 100644 index 0000000000..8890e5bdf5 --- /dev/null +++ b/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/Zuite_setBaseUrl.xml @@ -0,0 +1,130 @@ +<?xml version="1.0"?> +<ZopeData> + <record id="1" aka="AAAAAAAAAAE="> + <pickle> + <tuple> + <global name="PythonScript" module="Products.PythonScripts.PythonScript"/> + <tuple/> + </tuple> + </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>_body</string> </key> + <value> <string>portal = context.getPortalObject()\n +if portal.hasProperty(\'erp5_ui_test_base_url\'):\n + portal.manage_changeProperties(erp5_ui_test_base_url=base_url)\n +else:\n + portal.manage_addProperty(\'erp5_ui_test_base_url\', base_url, type=\'string\')\n +\n +return \'Ok\'\n +</string> </value> + </item> + <item> + <key> <string>_code</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_params</string> </key> + <value> <string>base_url</string> </value> + </item> + <item> + <key> <string>errors</string> </key> + <value> + <tuple/> + </value> + </item> + <item> + <key> <string>func_code</string> </key> + <value> + <object> + <klass> + <global name="FuncCode" module="Shared.DC.Scripts.Signature"/> + </klass> + <tuple/> + <state> + <dictionary> + <item> + <key> <string>co_argcount</string> </key> + <value> <int>1</int> </value> + </item> + <item> + <key> <string>co_varnames</string> </key> + <value> + <tuple> + <string>base_url</string> + <string>_getattr_</string> + <string>context</string> + <string>portal</string> + </tuple> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>func_defaults</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>Zuite_setBaseUrl</string> </value> + </item> + <item> + <key> <string>warnings</string> </key> + <value> + <tuple/> + </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/Zuite_waitForActivities.xml b/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/Zuite_waitForActivities.xml new file mode 100644 index 0000000000..c736ce0fc6 --- /dev/null +++ b/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/Zuite_waitForActivities.xml @@ -0,0 +1,141 @@ +<?xml version="1.0"?> +<ZopeData> + <record id="1" aka="AAAAAAAAAAE="> + <pickle> + <tuple> + <global name="PythonScript" module="Products.PythonScripts.PythonScript"/> + <tuple/> + </tuple> + </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>_body</string> </key> + <value> <string encoding="cdata"><![CDATA[ + +from Products.ERP5Type.Utils import sleep\n +count = 1000\n +while len(context.portal_activities.getMessageList()) > 0:\n + context.portal_activities.process_timer(0, 0)\n + count -= 1\n + sleep()\n + if count < 0:\n + raise RuntimeError, \'tic is endless\'\n +\n +return \'Done.\'\n + + +]]></string> </value> + </item> + <item> + <key> <string>_code</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_params</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>errors</string> </key> + <value> + <tuple/> + </value> + </item> + <item> + <key> <string>func_code</string> </key> + <value> + <object> + <klass> + <global name="FuncCode" module="Shared.DC.Scripts.Signature"/> + </klass> + <tuple/> + <state> + <dictionary> + <item> + <key> <string>co_argcount</string> </key> + <value> <int>0</int> </value> + </item> + <item> + <key> <string>co_varnames</string> </key> + <value> + <tuple> + <string>Products.ERP5Type.Utils</string> + <string>sleep</string> + <string>count</string> + <string>len</string> + <string>_getattr_</string> + <string>context</string> + <string>_inplacevar_</string> + <string>RuntimeError</string> + </tuple> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>func_defaults</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>Zuite_waitForActivities</string> </value> + </item> + <item> + <key> <string>warnings</string> </key> + <value> + <tuple/> + </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/user-extensions.js.xml b/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/user-extensions.js.xml new file mode 100644 index 0000000000..503c54408a --- /dev/null +++ b/bt5/erp5_ui_test_core/SkinTemplateItem/portal_skins/erp5_ui_test_core/user-extensions.js.xml @@ -0,0 +1,103 @@ +<?xml version="1.0"?> +<ZopeData> + <record id="1" aka="AAAAAAAAAAE="> + <pickle> + <tuple> + <global name="File" module="OFS.Image"/> + <tuple/> + </tuple> + </pickle> + <pickle> + <dictionary> + <item> + <key> <string>_EtagSupport__etag</string> </key> + <value> <string>ts22862605.97</string> </value> + </item> + <item> + <key> <string>__name__</string> </key> + <value> <string>user-extensions.js</string> </value> + </item> + <item> + <key> <string>content_type</string> </key> + <value> <string>application/x-javascript</string> </value> + </item> + <item> + <key> <string>data</string> </key> + <value> <string encoding="cdata"><![CDATA[ + +/**\n + * Selenium extensions for the ERP5 project\n + */\n +\n +\n +/**\n + * Checks the element referenced by `locator` is a float equals to `text`.\n + * Values are converted to float, to be format-independant (ie. 1 000 = 1000.0)\n + */\n +Selenium.prototype.assertFloat = function(locator, text) {\n + var actualValueText = getText(this.page().findElement(locator));\n + var actualValue = parseFloat(actualValueText\n + .replace(/ /g, "").replace(/ /g, ""));\n + var expectedValue = parseFloat(text.replace(/ /g, "").replace(/ /g, ""));\n +\n + if (isNaN(actualValue)) {\n + Assert.fail("Actual value "+ actualValueText +\n + " cannot be parsed as float");\n + }\n + Assert.matches(expectedValue.toString(), actualValue.toString());\n +};\n +\n +\n +/**\n + * like assertFloat, but for the value of <input elements.\n + */\n +Selenium.prototype.assertFloatValue = function(locator, text) {\n + var actualValueText = getInputValue(this.page().findElement(locator));\n + var actualValue = parseFloat(actualValueText\n + .replace(/ /g, "").replace(/ /g, ""));\n + var expectedValue = parseFloat(text.replace(/ /g, "").replace(/ /g, ""));\n +\n + if (isNaN(actualValue)) {\n + Assert.fail("Actual value "+ actualValueText +\n + " cannot be parsed as float");\n + }\n + Assert.matches(expectedValue.toString(), actualValue.toString());\n +};\n +\n +\n +/**\n + * Checks the portal status message.\n + */\n +Selenium.prototype.assertPortalStatusMessage = function(text) {\n + var psm_locator = "//div[@id=\'transition_message\']";\n + var actualValue = getText(this.page().findElement(psm_locator));\n + Assert.matches(text, actualValue);\n +};\n +\n +\n +Selenium.prototype.doType = function(locator, newText) {\n + netscape.security.PrivilegeManager.enablePrivilege("UniversalFileRead");\n + var element = this.page().findElement(locator);\n + this.page().replaceText(element, newText);\n +};\n +\n + + +]]></string> </value> + </item> + <item> + <key> <string>precondition</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>size</string> </key> + <value> <int>1917</int> </value> + </item> + <item> + <key> <string>title</string> </key> + <value> <string></string> </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/bt5/erp5_ui_test_core/bt/categories_list b/bt5/erp5_ui_test_core/bt/categories_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/change_log b/bt5/erp5_ui_test_core/bt/change_log new file mode 100644 index 0000000000..61a5fa6957 --- /dev/null +++ b/bt5/erp5_ui_test_core/bt/change_log @@ -0,0 +1,2 @@ +2008-10-01 fabien +* initial version \ No newline at end of file diff --git a/bt5/erp5_ui_test_core/bt/comment b/bt5/erp5_ui_test_core/bt/comment new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/copyright_list b/bt5/erp5_ui_test_core/bt/copyright_list new file mode 100644 index 0000000000..f7f420b9be --- /dev/null +++ b/bt5/erp5_ui_test_core/bt/copyright_list @@ -0,0 +1 @@ +Copyright (C) 2008 Nexedi SA \ No newline at end of file diff --git a/bt5/erp5_ui_test_core/bt/dependency_list b/bt5/erp5_ui_test_core/bt/dependency_list new file mode 100644 index 0000000000..a5cbd25b47 --- /dev/null +++ b/bt5/erp5_ui_test_core/bt/dependency_list @@ -0,0 +1,2 @@ +erp5_core +erp5_xhtml_style \ No newline at end of file diff --git a/bt5/erp5_ui_test_core/bt/description b/bt5/erp5_ui_test_core/bt/description new file mode 100644 index 0000000000..ce39fbd257 --- /dev/null +++ b/bt5/erp5_ui_test_core/bt/description @@ -0,0 +1 @@ +Framework for user interface tests. \ No newline at end of file diff --git a/bt5/erp5_ui_test_core/bt/license b/bt5/erp5_ui_test_core/bt/license new file mode 100644 index 0000000000..3a3e12bcad --- /dev/null +++ b/bt5/erp5_ui_test_core/bt/license @@ -0,0 +1 @@ +GPL \ No newline at end of file diff --git a/bt5/erp5_ui_test_core/bt/maintainer_list b/bt5/erp5_ui_test_core/bt/maintainer_list new file mode 100644 index 0000000000..5fa27abd25 --- /dev/null +++ b/bt5/erp5_ui_test_core/bt/maintainer_list @@ -0,0 +1 @@ +fabien \ No newline at end of file diff --git a/bt5/erp5_ui_test_core/bt/provision_list b/bt5/erp5_ui_test_core/bt/provision_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/publication_url b/bt5/erp5_ui_test_core/bt/publication_url new file mode 100644 index 0000000000..4af18322e3 --- /dev/null +++ b/bt5/erp5_ui_test_core/bt/publication_url @@ -0,0 +1 @@ +None \ No newline at end of file diff --git a/bt5/erp5_ui_test_core/bt/revision b/bt5/erp5_ui_test_core/bt/revision new file mode 100644 index 0000000000..d8263ee986 --- /dev/null +++ b/bt5/erp5_ui_test_core/bt/revision @@ -0,0 +1 @@ +2 \ No newline at end of file diff --git a/bt5/erp5_ui_test_core/bt/short_title b/bt5/erp5_ui_test_core/bt/short_title new file mode 100644 index 0000000000..4af18322e3 --- /dev/null +++ b/bt5/erp5_ui_test_core/bt/short_title @@ -0,0 +1 @@ +None \ No newline at end of file diff --git a/bt5/erp5_ui_test_core/bt/template_action_path_list b/bt5/erp5_ui_test_core/bt/template_action_path_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_base_category_list b/bt5/erp5_ui_test_core/bt/template_base_category_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_catalog_datetime_key_list b/bt5/erp5_ui_test_core/bt/template_catalog_datetime_key_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_catalog_full_text_key_list b/bt5/erp5_ui_test_core/bt/template_catalog_full_text_key_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_catalog_keyword_key_list b/bt5/erp5_ui_test_core/bt/template_catalog_keyword_key_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_catalog_local_role_key_list b/bt5/erp5_ui_test_core/bt/template_catalog_local_role_key_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_catalog_method_id_list b/bt5/erp5_ui_test_core/bt/template_catalog_method_id_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_catalog_multivalue_key_list b/bt5/erp5_ui_test_core/bt/template_catalog_multivalue_key_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_catalog_related_key_list b/bt5/erp5_ui_test_core/bt/template_catalog_related_key_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_catalog_request_key_list b/bt5/erp5_ui_test_core/bt/template_catalog_request_key_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_catalog_result_key_list b/bt5/erp5_ui_test_core/bt/template_catalog_result_key_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_catalog_result_table_list b/bt5/erp5_ui_test_core/bt/template_catalog_result_table_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_catalog_role_key_list b/bt5/erp5_ui_test_core/bt/template_catalog_role_key_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_catalog_scriptable_key_list b/bt5/erp5_ui_test_core/bt/template_catalog_scriptable_key_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_catalog_topic_key_list b/bt5/erp5_ui_test_core/bt/template_catalog_topic_key_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_constraint_id_list b/bt5/erp5_ui_test_core/bt/template_constraint_id_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_document_id_list b/bt5/erp5_ui_test_core/bt/template_document_id_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_extension_id_list b/bt5/erp5_ui_test_core/bt/template_extension_id_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_format_version b/bt5/erp5_ui_test_core/bt/template_format_version new file mode 100644 index 0000000000..56a6051ca2 --- /dev/null +++ b/bt5/erp5_ui_test_core/bt/template_format_version @@ -0,0 +1 @@ +1 \ No newline at end of file diff --git a/bt5/erp5_ui_test_core/bt/template_local_roles_list b/bt5/erp5_ui_test_core/bt/template_local_roles_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_message_translation_list b/bt5/erp5_ui_test_core/bt/template_message_translation_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_module_id_list b/bt5/erp5_ui_test_core/bt/template_module_id_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_path_list b/bt5/erp5_ui_test_core/bt/template_path_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_portal_type_allowed_content_type_list b/bt5/erp5_ui_test_core/bt/template_portal_type_allowed_content_type_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_portal_type_base_category_list b/bt5/erp5_ui_test_core/bt/template_portal_type_base_category_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_portal_type_hidden_content_type_list b/bt5/erp5_ui_test_core/bt/template_portal_type_hidden_content_type_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_portal_type_id_list b/bt5/erp5_ui_test_core/bt/template_portal_type_id_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_portal_type_property_sheet_list b/bt5/erp5_ui_test_core/bt/template_portal_type_property_sheet_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_portal_type_roles_list b/bt5/erp5_ui_test_core/bt/template_portal_type_roles_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_portal_type_workflow_chain_list b/bt5/erp5_ui_test_core/bt/template_portal_type_workflow_chain_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_preference_list b/bt5/erp5_ui_test_core/bt/template_preference_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_product_id_list b/bt5/erp5_ui_test_core/bt/template_product_id_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_property_sheet_id_list b/bt5/erp5_ui_test_core/bt/template_property_sheet_id_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_role_list b/bt5/erp5_ui_test_core/bt/template_role_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_site_property_id_list b/bt5/erp5_ui_test_core/bt/template_site_property_id_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_skin_id_list b/bt5/erp5_ui_test_core/bt/template_skin_id_list new file mode 100644 index 0000000000..1cfe5060d7 --- /dev/null +++ b/bt5/erp5_ui_test_core/bt/template_skin_id_list @@ -0,0 +1 @@ +erp5_ui_test_core \ No newline at end of file diff --git a/bt5/erp5_ui_test_core/bt/template_test_id_list b/bt5/erp5_ui_test_core/bt/template_test_id_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_tool_id_list b/bt5/erp5_ui_test_core/bt/template_tool_id_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/template_update_business_template_workflow b/bt5/erp5_ui_test_core/bt/template_update_business_template_workflow new file mode 100644 index 0000000000..c227083464 --- /dev/null +++ b/bt5/erp5_ui_test_core/bt/template_update_business_template_workflow @@ -0,0 +1 @@ +0 \ No newline at end of file diff --git a/bt5/erp5_ui_test_core/bt/template_update_tool b/bt5/erp5_ui_test_core/bt/template_update_tool new file mode 100644 index 0000000000..c227083464 --- /dev/null +++ b/bt5/erp5_ui_test_core/bt/template_update_tool @@ -0,0 +1 @@ +0 \ No newline at end of file diff --git a/bt5/erp5_ui_test_core/bt/template_workflow_id_list b/bt5/erp5_ui_test_core/bt/template_workflow_id_list new file mode 100644 index 0000000000..e69de29bb2 diff --git a/bt5/erp5_ui_test_core/bt/title b/bt5/erp5_ui_test_core/bt/title new file mode 100644 index 0000000000..1cfe5060d7 --- /dev/null +++ b/bt5/erp5_ui_test_core/bt/title @@ -0,0 +1 @@ +erp5_ui_test_core \ No newline at end of file diff --git a/bt5/erp5_ui_test_core/bt/version b/bt5/erp5_ui_test_core/bt/version new file mode 100644 index 0000000000..ceab6e11ec --- /dev/null +++ b/bt5/erp5_ui_test_core/bt/version @@ -0,0 +1 @@ +0.1 \ No newline at end of file -- 2.30.9