Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.core
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
Carlos Ramos Carreño
slapos.core
Commits
c464b07a
Commit
c464b07a
authored
Sep 29, 2020
by
Lu Xu
👀
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
slapos_jio_ui_test: add test part for language navigation
parent
262d93a7
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
56 additions
and
2 deletions
+56
-2
master/bt5/slapos_jio_ui_test/PathTemplateItem/portal_tests/slaposjs_zuite/testSlapOSJSBasicNavigation.zpt
...rtal_tests/slaposjs_zuite/testSlapOSJSBasicNavigation.zpt
+11
-0
master/bt5/slapos_jio_ui_test/SkinTemplateItem/portal_skins/slapos_ui_test/Zuite_SlapOSCommonTemplate.zpt
...ortal_skins/slapos_ui_test/Zuite_SlapOSCommonTemplate.zpt
+45
-2
No files found.
master/bt5/slapos_jio_ui_test/PathTemplateItem/portal_tests/slaposjs_zuite/testSlapOSJSBasicNavigation.zpt
View file @
c464b07a
...
@@ -75,6 +75,11 @@
...
@@ -75,6 +75,11 @@
<td>
//a[@data-i18n='Networks']
</td>
<td>
//a[@data-i18n='Networks']
</td>
<td></td>
<td></td>
</tr>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//a[@data-i18n='Language']
</td>
<td></td>
</tr>
<tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
waitForElementPresent
</td>
<td>
//a[@data-i18n='Logout']
</td>
<td>
//a[@data-i18n='Logout']
</td>
...
@@ -124,6 +129,12 @@
...
@@ -124,6 +129,12 @@
<tal:block
metal:use-macro=
"here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_front_page"
/>
<tal:block
metal:use-macro=
"here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_front_page"
/>
</tal:block>
</tal:block>
<tal:block
define=
"menu_item python: 'Language'; header menu_item"
>
<tal:block
metal:use-macro=
"here/Zuite_SlapOSCommonTemplate/macros/access_menu_item_language"
/>
<tal:block
metal:use-macro=
"here/Zuite_SlapOSCommonTemplate/macros/click_page_header"
/>
<tal:block
metal:use-macro=
"here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_front_page"
/>
</tal:block>
<tr>
<tr>
<td
colspan=
"3"
><b>
Access modules and verify the redirect
</b></td>
<td
colspan=
"3"
><b>
Access modules and verify the redirect
</b></td>
</tr>
</tr>
...
...
master/bt5/slapos_jio_ui_test/SkinTemplateItem/portal_skins/slapos_ui_test/Zuite_SlapOSCommonTemplate.zpt
View file @
c464b07a
...
@@ -42,6 +42,11 @@
...
@@ -42,6 +42,11 @@
</tal:block>
</tal:block>
</tal:block>
</tal:block>
<tal:block metal:define-macro="access_menu_item_language">
<tal:block tal:define="panel_gadget_id python: 'gadget_slapos_panel.html'">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item_language_base" />
</tal:block>
</tal:block>
...
@@ -337,12 +342,12 @@
...
@@ -337,12 +342,12 @@
dummy python:context.REQUEST.set('mapping', {})">
dummy python:context.REQUEST.set('mapping', {})">
<tr>
<tr>
<td>waitForElementPresent</td>
<td>waitForElementPresent</td>
<td tal:content="python: '//div[contains(@data-gadget-url, \'gadget_slapos_header.html\')]//a[
@data-i18n=\'%s\'
]' % header_translation"></td>
<td tal:content="python: '//div[contains(@data-gadget-url, \'gadget_slapos_header.html\')]//a[
contains(text(), \'%s\')
]' % header_translation"></td>
<td></td>
<td></td>
</tr>
</tr>
<tr>
<tr>
<td>click</td>
<td>click</td>
<td tal:content="python: '//div[contains(@data-gadget-url, \'gadget_slapos_header.html\')]//a[
@data-i18n=\'%s\'
]' % header_translation"></td>
<td tal:content="python: '//div[contains(@data-gadget-url, \'gadget_slapos_header.html\')]//a[
contains(text(), \'%s\')
]' % header_translation"></td>
<td></td>
<td></td>
</tr>
</tr>
</tal:block>
</tal:block>
...
@@ -387,6 +392,44 @@
...
@@ -387,6 +392,44 @@
</tr>
</tr>
</tal:block>
</tal:block>
<tal:block metal:define-macro="access_menu_item_language_base">
<tr>
<td colspan="3"><b tal:content="python: 'Access Entry on the Menu for Language'"> Menu Item </b></td>
</tr>
<tr>
<td>click</td>
<td>//button[@data-i18n='Menu']</td>
<td></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//button[@data-i18n='Menu']</td>
<td></td>
</tr>
<tr>
<td>click</td>
<td tal:content="python: '//div[contains(@data-gadget-url, \'%s\')]//a[@data-i18n=\'%s\']' % (panel_gadget_id, menu_item)"></td>
<td></td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_content_loaded" />
<tr>
<td>assertElementPresent</td>
<td tal:content="python: '//div[contains(@data-gadget-url, \'gadget_slapos_header.html\')]//a[contains(text(), \'%s\')]' % here.Base_translateString(menu_item, lang=lang)"></td>
<td></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td tal:content="python: '//div[contains(@data-gadget-url, \'gadget_erp5_label_field.html\')]//label[text()=\'%s\']' % here.Base_translateString(menu_item, lang=lang)"></td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td tal:content="python: '//div[contains(@data-gadget-url, \'gadget_erp5_label_field.html\')]//label[text()=\'%s\']' % here.Base_translateString(menu_item, lang=lang)"></td>
<td></td>
</tr>
</tal:block>
<tal:block metal:define-macro="add_simple_with_title">
<tal:block metal:define-macro="add_simple_with_title">
<tr>
<tr>
<td colspan="3"><b tal:content="python: 'Add an entry with title as %s' % title"> Menu Item </b></td>
<td colspan="3"><b tal:content="python: 'Add an entry with title as %s' % title"> Menu Item </b></td>
...
...
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