Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
Lu Xu
erp5
Commits
fa3cbf88
Commit
fa3cbf88
authored
Aug 29, 2019
by
Lu Xu
👀
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp5_officejs_ui_test: implement entire test especially for query
parent
ad4473a2
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
454 additions
and
5 deletions
+454
-5
bt5/erp5_officejs_ui_test/PathTemplateItem/portal_tests/officejs_ui_smartassistant_zuite/testOfficeJSSmartAssistant.zpt
...js_ui_smartassistant_zuite/testOfficeJSSmartAssistant.zpt
+3
-5
bt5/erp5_officejs_ui_test/PathTemplateItem/portal_tests/officejs_ui_smartassistant_zuite/testOfficeJSSmartAssistantAll.xml
...ui_smartassistant_zuite/testOfficeJSSmartAssistantAll.xml
+58
-0
bt5/erp5_officejs_ui_test/PathTemplateItem/portal_tests/officejs_ui_smartassistant_zuite/testOfficeJSSmartAssistantAll.zpt
...ui_smartassistant_zuite/testOfficeJSSmartAssistantAll.zpt
+393
-0
No files found.
bt5/erp5_officejs_ui_test/PathTemplateItem/portal_tests/officejs_ui_smartassistant_zuite/testOfficeJSSmartAssistant.zpt
View file @
fa3cbf88
...
...
@@ -129,8 +129,6 @@
<td>
link=${title}
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//pre[contains(text(), "This is a test too simple")]
</td>
<td></td>
</tr>
\ No newline at end of file
<tal:block
tal:define=
"text_content python: '<p>This is a test too simple</p>'"
>
<tal:block
metal:use-macro=
"container/Zuite_CommonTemplateForRenderjsUi/macros/verify_ckeditor_text_content"
/>
</tal:block>
\ No newline at end of file
bt5/erp5_officejs_ui_test/PathTemplateItem/portal_tests/officejs_ui_smartassistant_zuite/testOfficeJSSmartAssistantAll.xml
0 → 100644
View file @
fa3cbf88
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"ZopePageTemplate"
module=
"Products.PageTemplates.ZopePageTemplate"
/>
</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>
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>
testOfficeJSSmartAssistantAll
</string>
</value>
</item>
<item>
<key>
<string>
output_encoding
</string>
</key>
<value>
<string>
utf-8
</string>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
<value>
<unicode></unicode>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_officejs_ui_test/PathTemplateItem/portal_tests/officejs_ui_smartassistant_zuite/testOfficeJSSmartAssistantAll.zpt
0 → 100644
View file @
fa3cbf88
<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 OfficeJS UI
</title>
<script
src=
"../../web_site_module/officejs_smart_assistant/app/rsvp.js"
></script>
<script
src=
"../../web_site_module/officejs_smart_assistant/app/jiodev.js"
></script>
</head>
<body>
<table
cellpadding=
"1"
cellspacing=
"1"
border=
"1"
>
<thead>
<tr><td
rowspan=
"1"
colspan=
"3"
>
Test OfficeJS UI
</td></tr>
</thead><tbody>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplate/macros/init"
/>
<!-- Clean Up -->
<tr>
<td>
open
</td>
<td>
${base_url}/smart_assistant_text_module/ListBoxZuite_reset
</td>
<td></td>
</tr>
<tr>
<td>
assertTextPresent
</td>
<td>
Reset Successfully.
</td>
<td></td>
</tr>
<tal:block
tal:define=
"web_site_name python: 'officejs_smart_assistant'"
>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForOfficejsUi/macros/install_offline_and_redirect"
/>
</tal:block>
<tr>
<td>
waitForElementPresent
</td>
<td>
//a[@data-i18n='Storages']
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//a[@data-i18n='Storages']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
link=Local is Enough
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
link=Local is Enough
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//label[@for='upload']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//label[@for='image']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//a[contains(@href,'smart_assistant_audio')]
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//a[@id='audio']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//button[text()="We can't access to your microphone"]
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//a[contains(@href,'smart_assistant_text')]
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//a[@id='text']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//button[@data-i18n='Save']
</td>
<td></td>
</tr>
<tal:block
tal:define=
"text_content python: 'This is a test too simple'"
>
<tal:block
metal:use-macro=
"container/Zuite_CommonTemplateForRenderjsUi/macros/type_ckeditor_text_content"
/>
</tal:block>
<tr>
<td>
click
</td>
<td>
//button[@data-i18n='Save']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//button[text()='Data created']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//a[contains(@href,'smart_assistant_audio')]
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//a[@data-i18n='Document']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//button[@data-i18n='Filter']
</td>
<td></td>
</tr>
<tr>
<td>
store
</td>
<td
tal:content=
"python: 'This_is_a_test'"
>
Title
</td>
<td>
title
</td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
link=${title}
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
link=${title}
</td>
<td></td>
</tr>
<tal:block
tal:define=
"text_content python: '<p>This is a test too simple</p>'"
>
<tal:block
metal:use-macro=
"container/Zuite_CommonTemplateForRenderjsUi/macros/verify_ckeditor_text_content"
/>
</tal:block>
<!-- Syc -->
<tr>
<td>
open
</td>
<td>
${base_url}/web_site_module/officejs_smart_assistant/
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
link=Storages
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
link=Storages
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
link=Erp5
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
link=Erp5
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
name=erp5_url
</td>
<td></td>
</tr>
<tr>
<td>
type
</td>
<td>
name=erp5_url
</td>
<td>
${base_url}/web_site_module/
</td>
</tr>
<tr>
<td>
click
</td>
<td>
//button[@data-i18n='Proceed']
</td>
<td></td>
</tr>
<!-- Create two documents : audio, text -->
<tr>
<td>
waitForElementPresent
</td>
<td>
//a[contains(@href,'smart_assistant_audio')]
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//a[@id='audio']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//button[text()="We can't access to your microphone"]
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//a[contains(@href,'smart_assistant_text')]
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//a[@id='text']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//button[@data-i18n='Save']
</td>
<td></td>
</tr>
<tal:block
tal:define=
"text_content python: 'This is a test too simple'"
>
<tal:block
metal:use-macro=
"container/Zuite_CommonTemplateForRenderjsUi/macros/type_ckeditor_text_content"
/>
</tal:block>
<tr>
<td>
click
</td>
<td>
//button[@data-i18n='Save']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//button[text()='Data created']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//a[@id='audio']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//a[@data-i18n='Document']
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//a[@data-i18n='Document']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//button[@data-i18n='Filter']
</td>
<td></td>
</tr>
<!-- Check in ERP5 -->
<tr>
<td>
click
</td>
<td>
//button[@data-i18n='Menu']
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//a[@data-i18n='Synchronize']
</td>
<td></td>
</tr>
<tr>
<td>
store
</td>
<td
tal:content=
"python: 'This_is_a_test'"
>
Title
</td>
<td>
title
</td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//a[contains(@href,'smart_assistant_audio')]
</td>
<td></td>
</tr>
<tr>
<td>
open
</td>
<td>
${base_url}/Zuite_waitForActivities
</td>
<td></td>
</tr>
<tr>
<td>
assertTextPresent
</td>
<td>
Done.
</td>
<td></td>
</tr>
<tr>
<td>
open
</td>
<td>
${base_url}/web_site_module/renderjs_runner/#/smart_assistant_text_module/
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//button[@data-i18n='Filter']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
link=${title}
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
link=${title}
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//pre[contains(text(), "This is a test too simple")]
</td>
<td></td>
</tr>
<tal:block
tal:define=
"click_configuration python: {'text': 'Actions'}"
>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/click_on_header_link"
/>
</tal:block>
<tr>
<td>
waitForElementPresent
</td>
<td>
//a[text() = 'Post a Query']
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//a[text() = 'Post a Query']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//label[@for='field_your_description']
</td>
<td></td>
</tr>
<tr>
<td>
type
</td>
<td>
//textarea[@title='Description']
</td>
<td>
This is a reply test
</td>
</tr>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/submit_dialog"
/>
<tr>
<td>
waitForElementPresent
</td>
<td>
//label[@for='field_my_title']
</td>
<td></td>
</tr>
<tr>
<td>
open
</td>
<td>
${base_url}/Zuite_waitForActivities
</td>
<td></td>
</tr>
<tr>
<td>
assertTextPresent
</td>
<td>
Done.
</td>
<td></td>
</tr>
<tr>
<td>
open
</td>
<td>
${base_url}/web_site_module/officejs_smart_assistant/
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//a[@data-i18n='Storages']
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//a[@data-i18n='Storages']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
link=Erp5
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
link=Erp5
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
name=erp5_url
</td>
<td></td>
</tr>
<tr>
<td>
type
</td>
<td>
name=erp5_url
</td>
<td>
${base_url}/web_site_module/
</td>
</tr>
<tr>
<td>
click
</td>
<td>
//button[@data-i18n='Proceed']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
link=${title}
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
link=${title}
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//pre[contains(text(), "This is a reply test")]
</td>
<td></td>
</tr>
</tbody></table>
</body>
</html>
\ No newline at end of file
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