Commit 8e017b3d authored by Romain Courteaud's avatar Romain Courteaud

erp5_officejs_support_request_ui: switch to service worker

parent b59527b7
...@@ -110,104 +110,9 @@ ...@@ -110,104 +110,9 @@
<item> <item>
<key> <string>text_content</string> </key> <key> <string>text_content</string> </key>
<value> <string>CACHE MANIFEST\n <value> <string>CACHE MANIFEST\n
# Last modified by WebSite_checkCacheModificationDateConsistency on 2020/02/17 16:16:51.566799 UTC\n
# Last modified by WebSite_checkCacheModificationDateConsistency on 2020/02/13 13:51:46.356107 UTC\n
# Last modified by WebSite_checkCacheModificationDateConsistency on 2020/02/11 16:57:3.037725 UTC\n
# Last modified by WebSite_checkCacheModificationDateConsistency on 2020/02/04 16:03:51.837109 UTC\n
# Last modified by WebSite_checkCacheModificationDateConsistency on 2020/01/31 13:14:58.259778 UTC\n
# Last modified by WebSite_checkCacheModificationDateConsistency on 2020/01/30 16:25:52.091689 UTC\n
# v1.0.6\n
CACHE:\n CACHE:\n
font-awesome/font-awesome-webfont.woff2\n
echarts-all.js\n
erp5_launcher_nojqm.js\n
erp5_officejs_support_request_ui/\n
favicon.ico\n
gadget_erp5_editor_panel.html\n
gadget_erp5_editor_panel.js\n
gadget_erp5_field_datetime.html\n
gadget_erp5_field_datetime.js\n
gadget_erp5_field_file.html\n
gadget_erp5_field_file.js\n
gadget_erp5_field_gadget.html\n
gadget_erp5_field_gadget.js\n
gadget_erp5_field_list.html\n
gadget_erp5_field_list.js\n
gadget_erp5_field_listbox.html\n
gadget_erp5_field_listbox.js\n
gadget_erp5_field_relationstring.html\n
gadget_erp5_field_relationstring.js\n
gadget_erp5_field_string.html\n
gadget_erp5_field_string.js\n
gadget_erp5_form.html\n
gadget_erp5_form.js\n
gadget_erp5_global.js\n
gadget_erp5_header.html\n
gadget_erp5_header.js\n
gadget_erp5_jio.html\n
gadget_erp5_jio.js\n
gadget_erp5_label_field.html\n
gadget_erp5_label_field.js\n
gadget_erp5_nojqm.css\n
gadget_erp5_notification.html\n
gadget_erp5_notification.js\n
gadget_erp5_page_form.html\n
gadget_erp5_page_form.js\n
gadget_erp5_page_homepage.css\n
gadget_erp5_page_homepage.html\n
gadget_erp5_page_homepage.js\n
gadget_supportrequest_header.html\n
gadget_supportrequest_header.js\n
gadget_erp5_page_supportrequest_preference.html\n
gadget_erp5_page_supportrequest_preference.js\n
gadget_erp5_page_support_request_fast_view_dialog.html\n
gadget_erp5_page_support_request_fast_view_dialog.js\n
gadget_erp5_panel.png?format=png\n
gadget_erp5_pt_form_dialog.html\n
gadget_erp5_pt_form_dialog.js\n
gadget_erp5_pt_form_list.html\n
gadget_erp5_pt_form_list.js\n
gadget_erp5_pt_form_list_sr.html\n
gadget_erp5_pt_form_list_sr.js\n
gadget_erp5_pt_form_view_discussable.css\n
gadget_erp5_pt_form_view_discussable.html\n
gadget_erp5_pt_form_view_discussable.js\n
gadget_erp5_relation_input.html\n
gadget_erp5_relation_input.js\n
gadget_erp5_router.html\n
gadget_erp5_router.js\n
gadget_erp5_searchfield.html\n
gadget_erp5_searchfield.js\n
gadget_field_graph_echarts.html\n
gadget_field_graph_echarts.js\n
gadget_global.js\n
gadget_html5_element.html\n
gadget_html5_element.js\n
gadget_html5_input.html\n
gadget_html5_input.js\n
gadget_html5_select.html\n
gadget_html5_select.js\n
gadget_jio.html\n
gadget_jio.js\n
gadget_supportrequest_page_worklist.html\n
gadget_supportrequest_page_worklist.js\n
gadget_supportrequest_panel.html\n
gadget_supportrequest_panel.js\n
gadget_translation.html\n
gadget_translation.js\n
gadget_translation_data.js\n
handlebars.js\n
domsugar.js\n
jiodev.js\n
renderjs.js\n
rsvp.js\n
\n
GADGET:\n
officejs_ckeditor_gadget/\n
\n
NETWORK:\n NETWORK:\n
*\n *</string> </value>
</string> </value>
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
...@@ -354,7 +259,7 @@ NETWORK:\n ...@@ -354,7 +259,7 @@ NETWORK:\n
</item> </item>
<item> <item>
<key> <string>serial</string> </key> <key> <string>serial</string> </key>
<value> <string>981.59441.37027.22988</string> </value> <value> <string>982.26881.14545.28757</string> </value>
</item> </item>
<item> <item>
<key> <string>state</string> </key> <key> <string>state</string> </key>
...@@ -372,7 +277,7 @@ NETWORK:\n ...@@ -372,7 +277,7 @@ NETWORK:\n
</tuple> </tuple>
<state> <state>
<tuple> <tuple>
<float>1582043197.58</float> <float>1583931913.54</float>
<string>UTC</string> <string>UTC</string>
</tuple> </tuple>
</state> </state>
......
url_list = [
'handlebars.js',
'gadget_supportrequest_header.html',
'gadget_supportrequest_header.js',
'gadget_erp5_page_homepage.css',
'gadget_erp5_page_homepage.html',
'gadget_erp5_page_homepage.js',
'gadget_erp5_page_supportrequest_preference.html',
'gadget_erp5_page_supportrequest_preference.js',
'gadget_erp5_page_support_request_fast_view_dialog.html',
'gadget_erp5_page_support_request_fast_view_dialog.js',
'gadget_erp5_pt_form_list_sr.html',
'gadget_erp5_pt_form_list_sr.js',
'gadget_erp5_pt_form_view_discussable.css',
'gadget_erp5_pt_form_view_discussable.html',
'gadget_erp5_pt_form_view_discussable.js',
'gadget_field_graph_echarts.html',
'gadget_field_graph_echarts.js',
'gadget_supportrequest_page_worklist.html',
'gadget_supportrequest_page_worklist.js',
'gadget_supportrequest_panel.html',
'gadget_supportrequest_panel.js',
# Echarts. Should probably be a separated script
'unsafe/gadget_field_graph_echarts.html/',
'unsafe/gadget_field_graph_echarts.html/rsvp.js',
'unsafe/gadget_field_graph_echarts.html/renderjs.js',
'unsafe/gadget_field_graph_echarts.html/echarts-all.js',
'unsafe/gadget_field_graph_echarts.html/gadget_global.js',
'unsafe/gadget_field_graph_echarts.html/unsafe/gadget_field_graph_echarts.js',
]
return url_list
<?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>REQUEST=None</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>WebSection_getOfficeJSSupportRequestPrecacheManifestList</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html>
<head>
<title tal:content="template/title"></title>
<meta http-equiv="content-type" content="text/html;charset=utf-8">
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr><td rowspan="1" colspan="3">Cache Manifest can be fully loaded</td></tr>
</thead><tbody>
<tal:block metal:use-macro="here/Zuite_CommonTemplate/macros/init" />
<tr>
<td>open</td>
<td>${base_url}/web_site_module/erp5_officejs_support_request_ui/</td>
<td></td>
</tr>
<!-- Make sure the application cache can load all the manifest -->
<tr>
<td>waitForCondition</td>
<td>selenium.browserbot.currentWindow.applicationCache.status !== window.applicationCache.DOWNLOADING</td>
<td>600000</td>
</tr>
<tr>
<td>assertEval</td>
<td>selenium.browserbot.currentWindow.applicationCache.status !== window.applicationCache.UNCACHED</td>
<td>true</td>
</tr>
</tbody></table>
</body>
</html>
\ No newline at end of file
...@@ -42,7 +42,7 @@ ...@@ -42,7 +42,7 @@
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>testCacheManifest</string> </value> <value> <string>testServiceWorker</string> </value>
</item> </item>
<item> <item>
<key> <string>output_encoding</string> </key> <key> <string>output_encoding</string> </key>
...@@ -50,7 +50,7 @@ ...@@ -50,7 +50,7 @@
</item> </item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <unicode>Cache Manifest can be fully loaded</unicode> </value> <value> <unicode>Service Worker can be fully loaded</unicode> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
<html xmlns:tal="http://xml.zope.org/namespaces/tal"
xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test RenderJS UI</title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr><td rowspan="1" colspan="3">Test RenderJS UI</td></tr>
</thead><tbody>
<tal:block metal:use-macro="here/Zuite_CommonTemplate/macros/init" />
<tr>
<td colspan="3"><b tal:content="python: 'Clone web site'"></b></td>
</tr>
<tr>
<td>open</td>
<td tal:content="python: '${base_url}/web_site_module/erp5_officejs_support_request_ui?ignore_layout:int=1&editable_mode:int=1'"></td>
<td></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>name=Base_createCloneDocument:method</td>
<td></td>
</tr>
<tr>
<td>clickAndWait</td>
<td>name=Base_createCloneDocument:method</td>
<td></td>
</tr>
<tr>
<td>verifyTextPresent</td>
<td>Created Clone Web Site</td>
<td></td>
</tr>
<tr>
<td>storeValue</td>
<td>name=field_my_id</td>
<td>install_url</td>
</tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplate/macros/wait_for_activities" />
<tr>
<td>open</td>
<td>${base_url}/web_site_module/${install_url}/#/?page=test_service_worker</td>
<td></td>
</tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_app_loaded" />
<tr>
<td>assertTextPresent</td>
<td>Has SW: false</td>
<td></td>
</tr>
<tr>
<td>waitForTextPresent</td>
<td>Has SW: true</td>
<td></td>
</tr>
<tr>
<td>assertTextPresent</td>
<td>Has SW: true</td>
<td></td>
</tr>
</tbody></table>
</body>
</html>
\ No newline at end of file
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