[Erp5-report] r35681 ivan - in /erp5/trunk/bt5/erp5_km_ui_test: PathTemplateItem/portal_tes...

nobody at svn.erp5.org nobody at svn.erp5.org
Thu May 27 15:47:58 CEST 2010


Author: ivan
Date: Thu May 27 15:47:57 2010
New Revision: 35681

URL: http://svn.erp5.org?rev=35681&view=rev
Log:
Try to reuse once created test KM site.
Add "My Documents" gadget test.

Added:
    erp5/trunk/bt5/erp5_km_ui_test/PathTemplateItem/portal_tests/erp5_km_zuite/testMyDocumentsGadget.xml
Modified:
    erp5/trunk/bt5/erp5_km_ui_test/PathTemplateItem/portal_tests/erp5_km_zuite/testAdvancedSearch.xml
    erp5/trunk/bt5/erp5_km_ui_test/PathTemplateItem/portal_tests/erp5_km_zuite/testCreateNewFile.xml
    erp5/trunk/bt5/erp5_km_ui_test/SkinTemplateItem/portal_skins/erp5_km_ui_test/KMZuite_CommonTemplate.xml
    erp5/trunk/bt5/erp5_km_ui_test/SkinTemplateItem/portal_skins/erp5_km_ui_test/WebSiteModule_createKMSite.xml
    erp5/trunk/bt5/erp5_km_ui_test/bt/revision

Modified: erp5/trunk/bt5/erp5_km_ui_test/PathTemplateItem/portal_tests/erp5_km_zuite/testAdvancedSearch.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_km_ui_test/PathTemplateItem/portal_tests/erp5_km_zuite/testAdvancedSearch.xml?rev=35681&r1=35680&r2=35681&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_km_ui_test/PathTemplateItem/portal_tests/erp5_km_zuite/testAdvancedSearch.xml [utf8] (original)
+++ erp5/trunk/bt5/erp5_km_ui_test/PathTemplateItem/portal_tests/erp5_km_zuite/testAdvancedSearch.xml [utf8] Thu May 27 15:47:57 2010
@@ -57,22 +57,12 @@
 <tal:block metal:use-macro="here/KMZuite_CommonTemplate/macros/createKMWebSite" />\n
 \n
 <tr>\n
-  <td>open</td>\n
+  <td>openAndWait</td>\n
   <td>${base_url}/web_site_module/km_test_web_site/view</td>\n
   <td></td>\n
 </tr>\n
-<tr>\n
-  <td>open</td>\n
-  <td>${base_url}/web_site_module/Zuite_waitForActivities</td>\n
-  <td></td>\n
-  <td></td>\n
-</tr>\n
-<tr>\n
-  <td>assertTextPresent</td>\n
-  <td>Done.</td>\n
-  <td></td>\n
-  <td></td>\n
-</tr>\n
+<span metal:use-macro="container/ExpressZuite_viewTestMacroLibrary/macros/wait_for_activities">\n
+Wait for activities</span>\n
 <tr>\n
   <td>open</td>\n
   <td>${base_url}/web_site_module/km_test_web_site/en</td>\n
@@ -93,13 +83,6 @@
   <td>hidden_button</td>\n
   <td></td>\n
 </tr>\n
-<!--\n
-<tr>\n
-  <td>verifyText</td>\n
-  <td>//div[@class=\'searchResultHeader\']/span[@class=\'right\']/em[2]</td>\n
-  <td>1</td>\n
-</tr>\n
--->\n
 <tr>\n
   <td>verifyText</td>\n
   <td>//tr[@id=\'listbox_data_line_0\']//span[@class=\'search_result_title\']</td>\n

Modified: erp5/trunk/bt5/erp5_km_ui_test/PathTemplateItem/portal_tests/erp5_km_zuite/testCreateNewFile.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_km_ui_test/PathTemplateItem/portal_tests/erp5_km_zuite/testCreateNewFile.xml?rev=35681&r1=35680&r2=35681&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_km_ui_test/PathTemplateItem/portal_tests/erp5_km_zuite/testCreateNewFile.xml [utf8] (original)
+++ erp5/trunk/bt5/erp5_km_ui_test/PathTemplateItem/portal_tests/erp5_km_zuite/testCreateNewFile.xml [utf8] Thu May 27 15:47:57 2010
@@ -78,50 +78,53 @@
 </tr>\n
 <tr>\n
   <td>verifyTextPresent</td>\n
-  <td>Presentation created successfully</td>\n
+  <td>Presentation</td>\n
   <td></td>\n
 </tr>\n
-<!-- -->\n
 <tr>\n
-\t<td>verifyValue</td>\n
-\t<td>field_my_title</td>\n
-\t<td>TioLive, ERP5, Freedom</td>\n
+  <td>verifyTextPresent</td>\n
+  <td>successfully</td>\n
+  <td></td>\n
 </tr>\n
 <tr>\n
-\t<td>verifyValue</td>\n
-\t<td>field_my_reference</td>\n
-\t<td>tiolive-ERP5.DMS.TioLive</td>\n
+  <td>verifyValue</td>\n
+  <td>field_my_title</td>\n
+  <td>TioLive, ERP5, Freedom</td>\n
 </tr>\n
 <tr>\n
-\t<td>verifyValue</td>\n
-\t<td>field_my_version</td>\n
-\t<td>001</td>\n
+  <td>verifyValue</td>\n
+  <td>field_my_reference</td>\n
+  <td>tiolive-ERP5.DMS.TioLive</td>\n
 </tr>\n
 <tr>\n
-\t<td>verifyValue</td>\n
-\t<td>field_my_language</td>\n
-\t<td>en</td>\n
+  <td>verifyValue</td>\n
+  <td>field_my_version</td>\n
+  <td>001</td>\n
 </tr>\n
 <tr>\n
-\t<td>verifyTextPresent</td>\n
-\t<td>tiolive-ERP5.DMS.TioLive-001-en.odp</td>\n
-\t<td></td>\n
+  <td>verifyValue</td>\n
+  <td>field_my_language</td>\n
+  <td>en</td>\n
 </tr>\n
 <tr>\n
-\t<td>verifyTextPresent</td>\n
-\t<td>Presentation</td>\n
-\t<td></td>\n
+  <td>verifyTextPresent</td>\n
+  <td>tiolive-ERP5.DMS.TioLive-001-en.odp</td>\n
+  <td></td>\n
 </tr>\n
 <tr>\n
-\t<td>verifyTextPresent</td>\n
-\t<td>Converted</td>\n
-\t<td></td>\n
+  <td>verifyTextPresent</td>\n
+  <td>Presentation</td>\n
+  <td></td>\n
+</tr>\n
+<tr>\n
+  <td>verifyTextPresent</td>\n
+  <td>Converted</td>\n
+  <td></td>\n
 </tr>\n
 \n
-\n
-<!-- -->\n
 <span metal:use-macro="container/ExpressZuite_viewTestMacroLibrary/macros/wait_for_activities">\n
 Wait for activities</span>\n
+\n
 <tr>\n
   <td>openAndWait</td>\n
   <td>${base_url}/web_site_module/km_test_web_site/en</td>\n

Added: erp5/trunk/bt5/erp5_km_ui_test/PathTemplateItem/portal_tests/erp5_km_zuite/testMyDocumentsGadget.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_km_ui_test/PathTemplateItem/portal_tests/erp5_km_zuite/testMyDocumentsGadget.xml?rev=35681&view=auto
==============================================================================
--- erp5/trunk/bt5/erp5_km_ui_test/PathTemplateItem/portal_tests/erp5_km_zuite/testMyDocumentsGadget.xml (added)
+++ erp5/trunk/bt5/erp5_km_ui_test/PathTemplateItem/portal_tests/erp5_km_zuite/testMyDocumentsGadget.xml [utf8] Thu May 27 15:47:57 2010
@@ -1,0 +1,169 @@
+<?xml version="1.0"?>
+<ZopeData>
+  <record id="1" aka="AAAAAAAAAAE=">
+    <pickle>
+      <tuple>
+        <global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
+        <tuple/>
+      </tuple>
+    </pickle>
+    <pickle>
+      <dictionary>
+        <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_subpath</string> </key>
+                                <value> <string>traverse_subpath</string> </value>
+                            </item>
+                          </dictionary>
+                        </value>
+                    </item>
+                  </dictionary>
+                </state>
+              </object>
+            </value>
+        </item>
+        <item>
+            <key> <string>_text</string> </key>
+            <value> <string encoding="cdata"><![CDATA[
+
+<html xmlns:tal="http://xml.zope.org/namespaces/tal"\n
+      xmlns:metal="http://xml.zope.org/namespaces/metal">\n
+<head>\n
+<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">\n
+<title>Search Top Box Clicking</title>\n
+</head>\n
+<body tal:define="file_name string:tiolive-ERP5.Freedom.TioLive.Spreadsheet-001-en.ods;\n
+                  full_filename_location python: here.ExpressZuite_getFilenameLocation(file_name)">\n
+<table cellpadding="1" cellspacing="1" border="1">\n
+<thead>\n
+<tr><td rowspan="1" colspan="3">Test My Documents gadget</td></tr>\n
+</thead><tbody>\n
+\n
+<tal:block metal:use-macro="here/Zuite_CommonTemplate/macros/init" />\n
+\n
+<tal:block metal:use-macro="here/KMZuite_CommonTemplate/macros/createKMWebSite" />\n
+\n
+<tr>\n
+  <td>openAndWait</td>\n
+  <td>${base_url}/web_site_module/km_test_web_site</td>\n
+  <td></td>\n
+</tr>\n
+<tr>\n
+  <td>clickAndWait</td>\n
+  <td>link=New Document</td>\n
+  <td></td>\n
+</tr>\n
+<tr>\n
+  <td>type</td>\n
+  <td>field_your_file</td>\n
+  <td tal:content="full_filename_location"></td>\n
+</tr>\n
+<tr>\n
+  <td>clickAndWait</td>\n
+  <td>dialog_submit_button</td>\n
+  <td></td>\n
+</tr>\n
+<tr>\n
+  <td>verifyTextPresent</td>\n
+  <td>Spreadsheet</td>\n
+  <td></td>\n
+</tr>\n
+<tr>\n
+  <td>verifyTextPresent</td>\n
+  <td>successfully</td>\n
+  <td></td>\n
+</tr>\n
+<tr>\n
+  <td>verifyValue</td>\n
+  <td>field_my_title</td>\n
+  <td>TioLive Spreadsheet</td>\n
+</tr>\n
+<tr>\n
+  <td>verifyValue</td>\n
+  <td>field_my_reference</td>\n
+  <td>tiolive-ERP5.Freedom.TioLive.Spreadsheet</td>\n
+</tr>\n
+<tr>\n
+  <td>verifyValue</td>\n
+  <td>field_my_version</td>\n
+  <td>001</td>\n
+</tr>\n
+<tr>\n
+  <td>verifyValue</td>\n
+  <td>field_my_language</td>\n
+  <td>en</td>\n
+</tr>\n
+<tr>\n
+  <td>verifyTextPresent</td>\n
+  <td tal:content="file_name"></td>\n
+  <td></td>\n
+</tr>\n
+<tr>\n
+  <td>verifyTextPresent</td>\n
+  <td>Spreadsheet</td>\n
+  <td></td>\n
+</tr>\n
+<tr>\n
+  <td>verifyTextPresent</td>\n
+  <td>Converted</td>\n
+  <td></td>\n
+</tr>\n
+<!--  add "My Documents" gadget -->\n
+<tr>\n
+  <td>openAndWait</td>\n
+  <td>${base_url}/web_site_module/km_test_web_site/Zuite_AddGadgetToActivePad?gadget_relative_url=portal_gadgets/km_my_documents&amp;mode=web_front</td>\n
+  <td></td>\n
+</tr>\n
+<tr>\n
+  <td>openAndWait</td>\n
+  <td>${base_url}/web_site_module/km_test_web_site</td>\n
+  <td></td>\n
+</tr>\n
+<tr>\n
+  <td>waitForCondition</td>\n
+  <td>selenium.isTextPresent("TioLive Spreadsheet")</td>\n
+  <td>10000</td> \n
+</tr>\n
+\n
+<tal:block metal:use-macro="here/KMZuite_CommonTemplate/macros/deleteKMWebSite" />\n
+\n
+</tbody></table>\n
+</body>\n
+</html>\n
+
+
+]]></string> </value>
+        </item>
+        <item>
+            <key> <string>content_type</string> </key>
+            <value> <string>text/html</string> </value>
+        </item>
+        <item>
+            <key> <string>expand</string> </key>
+            <value> <int>0</int> </value>
+        </item>
+        <item>
+            <key> <string>id</string> </key>
+            <value> <string>testMyDocumentsGadget</string> </value>
+        </item>
+        <item>
+            <key> <string>title</string> </key>
+            <value> <string></string> </value>
+        </item>
+      </dictionary>
+    </pickle>
+  </record>
+</ZopeData>

Modified: erp5/trunk/bt5/erp5_km_ui_test/SkinTemplateItem/portal_skins/erp5_km_ui_test/KMZuite_CommonTemplate.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_km_ui_test/SkinTemplateItem/portal_skins/erp5_km_ui_test/KMZuite_CommonTemplate.xml?rev=35681&r1=35680&r2=35681&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_km_ui_test/SkinTemplateItem/portal_skins/erp5_km_ui_test/KMZuite_CommonTemplate.xml [utf8] (original)
+++ erp5/trunk/bt5/erp5_km_ui_test/SkinTemplateItem/portal_skins/erp5_km_ui_test/KMZuite_CommonTemplate.xml [utf8] Thu May 27 15:47:57 2010
@@ -73,7 +73,8 @@
 \n
 \n
 <tal:block metal:define-macro="deleteKMWebSite">\n
-    <!-- delete the web_site -->\n
+    <!-- delete the web_site XXX: not used anymore as no need to delete site -->\n
+    <!--\n
     <tr>\n
       <td>open</td>\n
       <td>${base_url}/web_site_module/WebSiteModule_deleteKMSite?site_id=km_test_web_site</td>\n
@@ -85,6 +86,7 @@
       <td>Deleted Successfully.</td>\n
       <td></td>\n
     </tr>\n
+    -->\n
 </tal:block>\n
 \n
 \n

Modified: erp5/trunk/bt5/erp5_km_ui_test/SkinTemplateItem/portal_skins/erp5_km_ui_test/WebSiteModule_createKMSite.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_km_ui_test/SkinTemplateItem/portal_skins/erp5_km_ui_test/WebSiteModule_createKMSite.xml?rev=35681&r1=35680&r2=35681&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_km_ui_test/SkinTemplateItem/portal_skins/erp5_km_ui_test/WebSiteModule_createKMSite.xml [utf8] (original)
+++ erp5/trunk/bt5/erp5_km_ui_test/SkinTemplateItem/portal_skins/erp5_km_ui_test/WebSiteModule_createKMSite.xml [utf8] Thu May 27 15:47:57 2010
@@ -58,36 +58,34 @@
 """\n
   Initialize a KM site.\n
 """\n
-if site_id in context.objectIds():\n
-  context.manage_delObjects([site_id])\n
-km_website = context.newContent(id = site_id, \\\n
-                                title = title, \n
-                                portal_type = \'Web Site\')\n
-km_website.edit(skin_selection_name = \'KM\',\n
-                container_layout = \'erp5_km_minimal_layout\',\n
-                content_layout = \'erp5_km_minimal_content_layout\',\n
-                custom_render_method_id = \'WebSite_viewKnowledgePad\',\n
-                layout_configuration_form_id = \'WebSection_viewKMMinimalThemeConfiguration\',\n
-                static_language_selection = True,\n
-                visible = True,\n
-                site_map_section_parent = True,\n
-                default_available_language = \'en\')\n
+if site_id not in context.objectIds():\n
+  km_website = context.newContent(id = site_id, \\\n
+                                  title = title, \n
+                                  portal_type = \'Web Site\')\n
+  km_website.edit(skin_selection_name = \'KM\',\n
+                  container_layout = \'erp5_km_minimal_layout\',\n
+                  content_layout = \'erp5_km_minimal_content_layout\',\n
+                  custom_render_method_id = \'WebSite_viewKnowledgePad\',\n
+                  layout_configuration_form_id = \'WebSection_viewKMMinimalThemeConfiguration\',\n
+                  static_language_selection = True,\n
+                  visible = True,\n
+                  site_map_section_parent = True,\n
+                  default_available_language = \'en\')\n
 \n
 km_preference_id = \'km_site_test\'\n
 portal_preferences = context.portal_preferences\n
-if km_preference_id in portal_preferences.objectIds():\n
-  portal_preferences.manage_delObjects([km_preference_id])\n
-km_preference = portal_preferences.newContent(\n
-                  id = km_preference_id,\n
-                  portal_type = \'System Preference\',\n
-                  priority = 1,\n
-                  preferred_document_reference_regular_expression = \'(?P<reference>[a-zA-Z0-9-_.]+-[a-zA-Z0-9-_.]+)(|-(?P<version>[0-9a-zA-Z.]+))(|-(?P<language>[a-z]{2})[^-]*)?\',\n
-                  preferred_document_file_name_regular_expression = \'(?P<node_reference>[a-zA-Z0-9_-]+)-(?P<local_reference>[a-zA-Z0-9_.]+)-(?P<version>[0-9a-zA-Z.]+)-(?P<language>[a-z]{2})[^-]*?\',\n
-                  preferred_synchronous_metadata_discovery = True,\n
-                  preferred_redirect_to_document = True,\n
-                  preferred_ooodoc_server_address = context.Zuite_getConversionServerDict()["oood_hostname"],\n
-                  preferred_ooodoc_server_port_number = context.Zuite_getConversionServerDict()["oood_port"])\n
-km_preference.enable()\n
+if km_preference_id not in portal_preferences.objectIds():\n
+  km_preference = portal_preferences.newContent(\n
+                    id = km_preference_id,\n
+                    portal_type = \'System Preference\',\n
+                    priority = 1,\n
+                    preferred_document_reference_regular_expression = \'(?P<reference>[a-zA-Z0-9-_.]+-[a-zA-Z0-9-_.]+)(|-(?P<version>[0-9a-zA-Z.]+))(|-(?P<language>[a-z]{2})[^-]*)?\',\n
+                    preferred_document_file_name_regular_expression = \'(?P<node_reference>[a-zA-Z0-9_-]+)-(?P<local_reference>[a-zA-Z0-9_.]+)-(?P<version>[0-9a-zA-Z.]+)-(?P<language>[a-z]{2})[^-]*?\',\n
+                    preferred_synchronous_metadata_discovery = True,\n
+                    preferred_redirect_to_document = True,\n
+                    preferred_ooodoc_server_address = context.Zuite_getConversionServerDict()["oood_hostname"],\n
+                    preferred_ooodoc_server_port_number = context.Zuite_getConversionServerDict()["oood_port"])\n
+  km_preference.enable()\n
 \n
 return "Created Successfully."\n
 

Modified: erp5/trunk/bt5/erp5_km_ui_test/bt/revision
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_km_ui_test/bt/revision?rev=35681&r1=35680&r2=35681&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_km_ui_test/bt/revision [utf8] (original)
+++ erp5/trunk/bt5/erp5_km_ui_test/bt/revision [utf8] Thu May 27 15:47:57 2010
@@ -1,1 +1,1 @@
-48
+49




More information about the Erp5-report mailing list