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
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Yusei Tahara
erp5
Commits
52e51c21
Commit
52e51c21
authored
Jul 03, 2019
by
Lu Xu
👀
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp5_officejs_ui_test: update functional test for Smart Assistant
parent
95a4bcac
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
572 additions
and
12 deletions
+572
-12
bt5/erp5_officejs_ui_test/PathTemplateItem/portal_tests/officejs_ui_smartassistant_zuite/testOfficeJSSmartAssistant.zpt
...js_ui_smartassistant_zuite/testOfficeJSSmartAssistant.zpt
+48
-12
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
+466
-0
No files found.
bt5/erp5_officejs_ui_test/PathTemplateItem/portal_tests/officejs_ui_smartassistant_zuite/testOfficeJSSmartAssistant.zpt
View file @
52e51c21
...
...
@@ -3,8 +3,6 @@
<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"
>
...
...
@@ -13,19 +11,12 @@
</thead><tbody>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplate/macros/init"
/>
<!-- Clean Up -->
<!-- Initialize -->
<tr>
<td>
open
</td>
<td>
${base_url}/
smart_assistant_text_module/ListBoxZuite_reset
</td>
<td>
${base_url}/
web_site_module/officejs_smart_assistant/
</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>
...
...
@@ -131,4 +122,49 @@
</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>
\ No newline at end of file
</tal:block>
<tr>
<td>
click
</td>
<td>
//a[@data-i18n='Home']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//a[contains(text(), 'Smart Assistant Records to Start Processing')]
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//a[contains(text(), 'Smart Assistant Records to Start Processing')]
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//button[text()="draft"]
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//a[@data-i18n='Home']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//a[contains(text(), 'Smart Assistant Records to Finish Processing')]
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//a[contains(text(), 'Smart Assistant Records to Finish Processing')]
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//button[text()="processing"]
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//a[@data-i18n='Home']
</td>
<td></td>
</tr>
\ No newline at end of file
bt5/erp5_officejs_ui_test/PathTemplateItem/portal_tests/officejs_ui_smartassistant_zuite/testOfficeJSSmartAssistantAll.xml
0 → 100644
View file @
52e51c21
<?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 @
52e51c21
<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>
</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 -->
<!-- Initialize -->
<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=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>
<!-- Check in ERP5: Query -->
<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>
<!-- Check in ERP5: New Person -->
<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() = 'New Person']
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//a[text() = 'New Person']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//input[@name='action_confirm' and @value='Create Person']
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//input[@name='action_confirm' and @value='Create Person']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//button[text()="Action succeeded."]
</td>
<td></td>
</tr>
<!-- Check in ERP5: New Expense -->
<tr>
<td>
waitForElementPresent
</td>
<td>
//a[text() = 'New Expense']
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//a[text() = 'New Expense']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//input[@name='action_confirm' and @value='Create Expense']
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//input[@name='action_confirm' and @value='Create Expense']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//button[text()="Action succeeded."]
</td>
<td></td>
</tr>
<!-- Check in ERP5: New Event-->
<tr>
<td>
waitForElementPresent
</td>
<td>
//a[text() = 'New Event']
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//a[text() = 'New Event']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//input[@name='action_confirm' and @value='Create Event']
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
//input[@name='action_confirm' and @value='Create Event']
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//button[text()="Action succeeded."]
</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