Commit 82328d7f authored by Rafael Monnerat's avatar Rafael Monnerat

slapos_jio_[zh_]ui_test: Refactor and clean up test code entirely

 * Remove duplication of unmodified scripts from Chinese translation
 * Use slapos_jio_ui_test as dependency of slapos_jio_zh_ui_test as we can reuse scripts
 * slapos_ui_zh_tests: Massively Remove unecessary duplication
 * Fixup! default_address_region was replaced by a selection
 * Correctly ident the entire html from the tests and templates (using
monaco autoformat)
parent a4c03494
<html xmlns:tal="http://xml.zope.org/namespaces/tal" <html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
xmlns:metal="http://xml.zope.org/namespaces/metal">
<head> <head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test SlapJS UI</title> <title>Test SlapOSJS Account</title>
</head> </head>
<body> <body>
<table cellpadding="1" cellspacing="1" border="1"> <table cellpadding="1" cellspacing="1" border="1">
<thead> <thead>
<tr><td rowspan="1" colspan="3">Test RenderJS UI</td></tr> <tr>
</thead><tbody> <td rowspan="1" colspan="3">Test SlapOS Account</td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_init" /> </thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_login" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_init" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_login" />
<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 define="person_name python: 'Demo User Functional'">
<tal:block define="person_name python: 'Demo User Functional'"> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item_account" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item_account" /> </tal:block>
</tal:block>
<tal:block tal:define="pagination_configuration python: {'header': '(1)', 'footer': '1 Records'}">
<tal:block tal:define="pagination_configuration python: {'header': '(1)', 'footer': '1 Records'}"> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" /> </tal:block>
</tal:block>
<tr>
<tr> <td>assertElementPresent</td>
<td>assertElementPresent</td> <td>//label[text()="First Name"]</td>
<td>//label[text()="First Name"]</td> <td></td>
<td></td> </tr>
</tr>
<tr>
<tr> <td>assertElementPresent</td>
<td>assertElementPresent</td> <td>//label[text()="Last Name"]</td>
<td>//label[text()="Last Name"]</td> <td></td>
<td></td> </tr>
</tr>
<tr>
<tr> <td>assertElementPresent</td>
<td>assertElementPresent</td> <td>//label[text()="Email"]</td>
<td>//label[text()="Email"]</td> <td></td>
<td></td> </tr>
</tr>
<tr>
<tr> <td>assertElementPresent</td>
<td>assertElementPresent</td> <td>//label[text()="Telephone"]</td>
<td>//label[text()="Telephone"]</td> <td></td>
<td></td> </tr>
</tr>
<tr>
<tr> <td>assertElementPresent</td>
<td>assertElementPresent</td> <td>//label[text()="Address"]</td>
<td>//label[text()="Address"]</td> <td></td>
<td></td> </tr>
</tr>
<tr>
<tr> <td>assertElementPresent</td>
<td>assertElementPresent</td> <td>//label[text()="Postal Code"]</td>
<td>//label[text()="Postal Code"]</td> <td></td>
<td></td> </tr>
</tr>
<tr>
<tr> <td>assertElementPresent</td>
<td>assertElementPresent</td> <td>//label[text()="City"]</td>
<td>//label[text()="City"]</td> <td></td>
<td></td> </tr>
</tr>
<tr>
<tr> <td>assertElementPresent</td>
<td>assertElementPresent</td> <td>//label[text()="Country"]</td>
<td>//label[text()="Country"]</td> <td></td>
<td></td> </tr>
</tr>
<tr>
<tr> <td colspan="3"><b> Rename user to DEMO A </b></td>
<td colspan="3"><b> Rename user to DEMO A </b></td> </tr>
</tr>
<tr>
<tr> <td>type</td>
<td>type</td> <td>//input[@id="first_name"]</td>
<td>//input[@id="first_name"]</td> <td>DEMO A</td>
<td>DEMO A</td> </tr>
</tr>
<tr>
<tr> <td>type</td>
<td>type</td> <td>//input[@id="last_name"]</td>
<td>//input[@id="last_name"]</td> <td>DEMO B</td>
<td>DEMO B</td> </tr>
</tr>
<tr>
<tr> <td>type</td>
<td>type</td> <td>//input[@id="default_email_text"]</td>
<td>//input[@id="default_email_text"]</td> <td>demoA@nexedi.com</td>
<td>demoA@nexedi.com</td> </tr>
</tr>
<!-- Perform an intermediate save to ensure we can edit partial values -->
<!-- Perform an intermediate save to ensure we can edit partial values --> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/save" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/save" />
<tr>
<tr> <td>type</td>
<td>type</td> <td>//textarea[@id="default_address_street_address"]</td>
<td>//textarea[@id="default_address_street_address"]</td> <td>My New Address</td>
<td>My New Address</td> </tr>
</tr>
<tr>
<tr> <td>type</td>
<td>type</td> <td>//input[@id="default_address_city"]</td>
<td>//input[@id="default_address_city"]</td> <td>My New City</td>
<td>My New City</td> </tr>
</tr>
<tr>
<tr> <td>type</td>
<td>type</td> <td>//input[@id="default_address_zip_code"]</td>
<td>//input[@id="default_address_zip_code"]</td> <td>99999</td>
<td>99999</td> </tr>
</tr>
<tr>
<tr> <td>type</td>
<td>type</td> <td>//input[@id="default_telephone_coordinate_text"]</td>
<td>//input[@id="default_telephone_coordinate_text"]</td> <td>+55 0192182812</td>
<td>+55 0192182812</td> </tr>
</tr>
<tr>
<tr> <td>select</td>
<td>select</td> <td>//select[@id="default_address_region"]</td>
<td>//select[@id="default_address_region"]</td> <td>Brazil</td>
<td>Brazil</td> </tr>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/save" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/save" />
<!-- access somewhere else -->
<!-- access somewhere else --> <tal:block define="menu_item python: 'Sites'; header menu_item">
<tal:block define="menu_item python: 'Sites'; header menu_item"> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item" /> </tal:block>
</tal:block>
<tal:block define="person_name python: 'DEMO A DEMO B'">
<tal:block define="person_name python: 'DEMO A DEMO B'"> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item_account" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item_account" /> </tal:block>
</tal:block>
<tr>
<tr> <td>waitForElementPresent</td>
<td>waitForElementPresent</td> <td>//input[@id="default_address_city" and @value="My New City"]</td>
<td>//input[@id="default_address_city" and @value="My New City"]</td> <td></td>
<td></td> </tr>
</tr>
<tr>
<tr> <td>verifyValue</td>
<td>verifyValue</td> <td>//textarea[@id="default_address_street_address"]</td>
<td>//textarea[@id="default_address_street_address"]</td> <td>My New Address</td>
<td>My New Address</td> </tr>
</tr>
<tr>
<tr> <td>assertElementPresent</td>
<td>assertElementPresent</td> <td>//input[@id="default_address_city" and @value="My New City"]</td>
<td>//input[@id="default_address_city" and @value="My New City"]</td> <td></td>
<td></td> </tr>
</tr>
<tr>
<tr> <td>assertElementPresent</td>
<td>assertElementPresent</td> <td>//input[@id="default_address_zip_code" and @value="99999"]</td>
<td>//input[@id="default_address_zip_code" and @value="99999"]</td> <td></td>
<td></td> </tr>
</tr>
<tr>
<tr> <td>assertElementPresent</td>
<td>assertElementPresent</td> <td>//input[@id="default_telephone_coordinate_text" and @value="+55 0192182812"]</td>
<td>//input[@id="default_telephone_coordinate_text" and @value="+55 0192182812"]</td> <td></td>
<td></td> </tr>
</tr>
<tr>
<tr> <td>assertElementPresent</td>
<td>assertElementPresent</td> <td>//select[@id="default_address_region"]/option[text()="Brazil" and @selected="selected"]</td>
<td>//select[@id="default_address_region"]/option[text()="Brazil" and @selected="selected"]</td> <td></td>
<td></td> </tr>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_logout" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_logout" />
</tbody>
</tbody></table> </table>
</body> </body>
</html> </html>
\ No newline at end of file
<html xmlns:tal="http://xml.zope.org/namespaces/tal" <html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
xmlns:metal="http://xml.zope.org/namespaces/metal">
<head> <head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test RapidSpace Console Account Page Check</title> <title>Test RapidSpace Console Account Page Check</title>
</head> </head>
<body> <body>
<table cellpadding="1" cellspacing="1" border="1"> <table cellpadding="1" cellspacing="1" border="1">
<thead> <thead>
<tr><td rowspan="1" colspan="3">Test RapidSpace Console Account Page Check</td></tr> <tr>
</thead><tbody> <td rowspan="1" colspan="3">Test RapidSpace Console Account Page Check</td>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_init" /> </tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_init" />
<tr> <tr>
<td>open</td> <td>open</td>
<td>${base_url}/web_site_module/hostingjs/</td> <td>${base_url}/web_site_module/hostingjs/</td>
<td></td> <td></td>
</tr> </tr>
<!-- <!--
In testSlapOSJSAccountLogin, after visit hostingjs website, In testSlapOSJSAccountLogin, after visit hostingjs website,
the default user is "zope", so in that test we need to call the default user is "zope", so in that test we need to call
hostingjs/WebSite_logout to logout first. hostingjs/WebSite_logout to logout first.
...@@ -25,163 +28,165 @@ hostingjs/WebSite_logout to logout first. ...@@ -25,163 +28,165 @@ hostingjs/WebSite_logout to logout first.
Here we don't call it manually, due to the zope user doesn't Here we don't call it manually, due to the zope user doesn't
have the correct "me" setting, so we just let the getSettingMe have the correct "me" setting, so we just let the getSettingMe
function redirect us to the login page --> function redirect us to the login page -->
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//label[contains(text(), "Login")]</td> <td>//label[contains(text(), "Login")]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//input[@name="__ac_name"]</td> <td>//input[@name="__ac_name"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//input[@name="__ac_password"]</td> <td>//input[@name="__ac_password"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>type</td> <td>type</td>
<td>__ac_name</td> <td>__ac_name</td>
<td>demo_functional_user</td> <td>demo_functional_user</td>
</tr> </tr>
<tr> <tr>
<td>type</td> <td>type</td>
<td>__ac_password</td> <td>__ac_password</td>
<td>demo_functional_user</td> <td>demo_functional_user</td>
</tr> </tr>
<tr> <tr>
<td>clickAndWait</td> <td>clickAndWait</td>
<td>WebSite_login:method</td> <td>WebSite_login:method</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//a[@data-i18n="Login Account"]</td> <td>//a[@data-i18n="Login Account"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//a[@data-i18n="Tickets"]</td> <td>//a[@data-i18n="Tickets"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//a[@data-i18n="Invoices"]</td> <td>//a[@data-i18n="Invoices"]</td>
<td></td> <td></td>
</tr> </tr>
<!-- Account Tab --> <!-- Account Tab -->
<tr> <tr>
<td>click</td> <td>click</td>
<td>//a[@data-i18n="Login Account"]</td> <td>//a[@data-i18n="Login Account"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//button[@data-i18n="Save"]</td> <td>//button[@data-i18n="Save"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//a[@data-i18n="Add Login"]</td> <td>//a[@data-i18n="Add Login"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//a[@data-i18n="Add Organisation"]</td> <td>//a[@data-i18n="Add Organisation"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//a[@data-i18n="Token"]</td> <td>//a[@data-i18n="Token"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//a[@data-i18n="Request Certificate"]</td> <td>//a[@data-i18n="Request Certificate"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//a[@data-i18n="Revoke Certificate"]</td> <td>//a[@data-i18n="Revoke Certificate"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//label[contains(text(), "First Name")]</td> <td>//label[contains(text(), "First Name")]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//label[contains(text(), "Last Name")]</td> <td>//label[contains(text(), "Last Name")]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//label[contains(text(), "Email")]</td> <td>//label[contains(text(), "Email")]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//input[@value="Demo User"]</td> <td>//input[@value="Demo User"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//input[@value="Functional"]</td> <td>//input[@value="Functional"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//input[@value="demo@nexedi.com"]</td> <td>//input[@value="demo@nexedi.com"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//h1[contains(text(), "Logins")]</td> <td>//h1[contains(text(), "Logins")]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//a[contains(text(), "Reference")]</td> <td>//a[contains(text(), "Reference")]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//a[contains(text(), "Type")]</td> <td>//a[contains(text(), "Type")]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//h1[contains(text(), "Organisation")]</td> <td>//h1[contains(text(), "Organisation")]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//th[contains(text(), "Title")]</td> <td>//th[contains(text(), "Title")]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//a[contains(text(), "Reference")]</td> <td>//a[contains(text(), "Reference")]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//th[contains(text(), "Region")]</td> <td>//th[contains(text(), "Region")]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//th[contains(text(), "Status")]</td> <td>//th[contains(text(), "Status")]</td>
<td></td> <td></td>
</tr> </tr>
</tbody></table> </tbody>
</table>
</body> </body>
</html> </html>
\ No newline at end of file
<html xmlns:tal="http://xml.zope.org/namespaces/tal" <html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
xmlns:metal="http://xml.zope.org/namespaces/metal">
<head> <head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test SlapJS UI</title> <title>Test SlapOS UI Account Certificate</title>
</head> </head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr><td rowspan="1" colspan="3">Test SlapOS UI Account Certificate</td></tr>
</thead><tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_init" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_login" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_front_page" />
<tal:block define="person_name python: 'Demo User Functional'">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item_account" />
</tal:block>
<tal:block tal:define="pagination_configuration python: {'header': '(1)', 'footer': '1 Records'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" />
</tal:block>
<tr> <body>
<td colspan="3"><b> Create another Login</b> </td> <table cellpadding="1" cellspacing="1" border="1">
</tr> <thead>
<tr>
<tal:block define="menu_action python: 'Add Login'"> <td rowspan="1" colspan="3">Test SlapOS UI Account Certificate</td>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_submenu_action" /> </tr>
</tal:block> </thead>
<tbody>
<tal:block define="header python: 'Add New User Login'; "> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_init" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_login" />
</tal:block> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_front_page" />
<tr> <tal:block define="person_name python: 'Demo User Functional'">
<td colspan="3"><b> Fill the form</b> </td> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item_account" />
</tr> </tal:block>
<tr> <tal:block tal:define="pagination_configuration python: {'header': '(1)', 'footer': '1 Records'}">
<td>type</td> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" />
<td>//input[@name='reference']</td> </tal:block>
<td>demo_test_login_from_testSlapOSJSAccountLogin</td>
</tr>
<tr> <tr>
<td>type</td> <td colspan="3"><b> Create another Login</b> </td>
<td>//input[@name='password']</td> </tr>
<td>demo_test_password_from_testSlapOSJSAccountLogin</td>
</tr> <tal:block define="menu_action python: 'Add Login'">
<tr> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_submenu_action" />
<td>type</td> </tal:block>
<td>//input[@name='password_confirmation']</td>
<td>demo_test_password_from_testSlapOSJSAccountLogin</td> <tal:block define="header python: 'Add New User Login'; ">
</tr> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" />
</tal:block>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" />
<tr>
<tal:block tal:define="notification_configuration python: {'class': 'success', <td colspan="3"><b> Fill the form</b> </td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='reference']</td>
<td>demo_test_login_from_testSlapOSJSAccountLogin</td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='password']</td>
<td>demo_test_password_from_testSlapOSJSAccountLogin</td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='password_confirmation']</td>
<td>demo_test_password_from_testSlapOSJSAccountLogin</td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" />
<tal:block tal:define="notification_configuration python: {'class': 'success',
'text': 'New User Login created.'}"> 'text': 'New User Login created.'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_notification" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_notification" />
</tal:block> </tal:block>
<tal:block define="header python: 'Your Account : Demo User Functional'; "> <tal:block define="header python: 'Your Account : Demo User Functional'; ">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" />
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_activities_and_front_page" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_activities_and_front_page" />
<tal:block define="person_name python: 'Demo User Functional'"> <tal:block define="person_name python: 'Demo User Functional'">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item_account" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item_account" />
</tal:block> </tal:block>
<tal:block tal:define="pagination_configuration python: {'header': '(2)', 'footer': '2 Records'}"> <tal:block tal:define="pagination_configuration python: {'header': '(2)', 'footer': '2 Records'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" />
</tal:block> </tal:block>
<tr> <tr>
<td>verifyTextPresent</td> <td>verifyTextPresent</td>
<td>demo_test_login_from_testSlapOSJSAccountLogin</td> <td>demo_test_login_from_testSlapOSJSAccountLogin</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>click</td> <td>click</td>
<td>//a[text()="demo_test_login_from_testSlapOSJSAccountLogin"]</td> <td>//a[text()="demo_test_login_from_testSlapOSJSAccountLogin"]</td>
<td></td> <td></td>
</tr> </tr>
<tal:block define="header python: 'Login : demo_test_login_from_testSlapOSJSAccountLogin'; "> <tal:block define="header python: 'Login : demo_test_login_from_testSlapOSJSAccountLogin'; ">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" />
</tal:block> </tal:block>
<tal:block define="menu_action python: 'Delete'"> <tal:block define="menu_action python: 'Delete'">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_submenu_action" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_submenu_action" />
</tal:block> </tal:block>
<tal:block define="header python: 'Disable Login: demo_test_login_from_testSlapOSJSAccountLogin'; "> <tal:block define="header python: 'Disable Login: demo_test_login_from_testSlapOSJSAccountLogin'; ">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" />
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" />
<tal:block define="header python: 'Your Account : Demo User Functional'; "> <tal:block define="header python: 'Your Account : Demo User Functional'; ">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" />
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_activities_and_front_page" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_activities_and_front_page" />
<tal:block define="person_name python: 'Demo User Functional'"> <tal:block define="person_name python: 'Demo User Functional'">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item_account" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item_account" />
</tal:block> </tal:block>
<tal:block tal:define="pagination_configuration python: {'header': '(1)', 'footer': '1 Records'}"> <tal:block tal:define="pagination_configuration python: {'header': '(1)', 'footer': '1 Records'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" />
</tal:block> </tal:block>
<tr> <tr>
<td>verifyTextNotPresent</td> <td>verifyTextNotPresent</td>
<td>demo_test_login_from_testSlapOSJSAccountLogin</td> <td>demo_test_login_from_testSlapOSJSAccountLogin</td>
<td></td> <td></td>
</tr> </tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_logout" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_logout" />
</tbody></table> </tbody>
</table>
</body> </body>
</html> </html>
\ No newline at end of file
<html xmlns:tal="http://xml.zope.org/namespaces/tal" <html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
xmlns:metal="http://xml.zope.org/namespaces/metal">
<head> <head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test SlapJS UI</title> <title>Test SlapOS JS Account Token</title>
</head> </head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr><td rowspan="1" colspan="3">Test SlapOS JS Account Token</td></tr>
</thead><tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_init" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_login" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_front_page" />
<tal:block define="person_name python: 'Demo User Functional'">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item_account" />
</tal:block>
<tal:block tal:define="pagination_configuration python: {'header': '(1)', 'footer': '1 Records'}"> <body>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" /> <table cellpadding="1" cellspacing="1" border="1">
</tal:block> <thead>
<tr>
<tr> <td rowspan="1" colspan="3">Test SlapOS JS Account Token</td>
<td colspan="3"><b tal:content="python: 'Click on Token'"> Menu Item </b></td> </tr>
</tr> </thead>
<tbody>
<tal:block define="menu_action python: 'Token'"> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_init" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_submenu_action" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_login" />
</tal:block> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_front_page" />
<tal:block define="header python: 'Request New Token'; "> <tal:block define="person_name python: 'Demo User Functional'">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item_account" />
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" /> <tal:block tal:define="pagination_configuration python: {'header': '(1)', 'footer': '1 Records'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" />
<tal:block tal:define="notification_configuration python: {'class': 'success', </tal:block>
<tr>
<td colspan="3"><b tal:content="python: 'Click on Token'"> Menu Item </b></td>
</tr>
<tal:block define="menu_action python: 'Token'">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_submenu_action" />
</tal:block>
<tal:block define="header python: 'Request New Token'; ">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" />
</tal:block>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" />
<tal:block tal:define="notification_configuration python: {'class': 'success',
'text': 'Token is Requested.'}"> 'text': 'Token is Requested.'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_notification" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_notification" />
</tal:block> </tal:block>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//label[text()="Your Token"]</td> <td>//label[text()="Your Token"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>assertElementPresent</td> <td>assertElementPresent</td>
<td>//label[text()="Your Token"]</td> <td>//label[text()="Your Token"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td tal:content="python: '//div[contains(@data-gadget-url, \'gadget_erp5_field_string.html\')]//p[contains(text(), \'%s%02d%02d-\')]' % (DateTime().year(),DateTime().month(),DateTime().day())"></td> <td
<td></td> tal:content="python: '//div[contains(@data-gadget-url, \'gadget_erp5_field_string.html\')]//p[contains(text(), \'%s%02d%02d-\')]' % (DateTime().year(),DateTime().month(),DateTime().day())">
</tr> </td>
<tr> <td></td>
<td>assertElementPresent</td> </tr>
<td tal:content="python: '//div[contains(@data-gadget-url, \'gadget_erp5_field_string.html\')]//p[contains(text(), \'%s%02d%02d-\')]' % (DateTime().year(),DateTime().month(),DateTime().day())"></td> <tr>
<td></td> <td>assertElementPresent</td>
</tr> <td
tal:content="python: '//div[contains(@data-gadget-url, \'gadget_erp5_field_string.html\')]//p[contains(text(), \'%s%02d%02d-\')]' % (DateTime().year(),DateTime().month(),DateTime().day())">
<tal:block define="header python: 'Request New Token'; "> </td>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" /> <td></td>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_page_header" /> </tr>
</tal:block>
<tal:block define="header python: 'Request New Token'; ">
<tal:block define="header python: 'Your Account : Demo User Functional'; "> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_page_header" />
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_logout" /> <tal:block define="header python: 'Your Account : Demo User Functional'; ">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" />
</tbody></table> </tal:block>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_logout" />
</tbody>
</table>
</body> </body>
</html> </html>
\ No newline at end of file
<html xmlns:tal="http://xml.zope.org/namespaces/tal" <html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
xmlns:metal="http://xml.zope.org/namespaces/metal">
<head> <head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test SlapJS UI</title> <title>Test SlapOS UI Network</title>
</head> </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_SlapOSCommonTemplate/macros/slapos_init" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_login" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_front_page" />
<tal:block define="menu_item python: 'Networks'; header menu_item">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item" />
</tal:block>
<tal:block tal:define="pagination_configuration python: {'header': '(0)', 'footer': 'No records'}"> <body>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" /> <table cellpadding="1" cellspacing="1" border="1">
</tal:block> <thead>
<tr>
<tal:block define="title python: 'TEST-SLAPOSJS-NETWORK 0'; "> <td rowspan="1" colspan="3">Test SlapOS UI Network</td>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/add_simple_with_title" /> </tr>
</tal:block> </thead>
<tbody>
<tal:block tal:define="notification_configuration python: {'class': 'success', <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_init" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_login" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_front_page" />
<tal:block define="menu_item python: 'Networks'; header menu_item">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item" />
</tal:block>
<tal:block tal:define="pagination_configuration python: {'header': '(0)', 'footer': 'No records'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" />
</tal:block>
<tal:block define="title python: 'TEST-SLAPOSJS-NETWORK 0'; ">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/add_simple_with_title" />
</tal:block>
<tal:block tal:define="notification_configuration python: {'class': 'success',
'text': 'New Network created.'}"> 'text': 'New Network created.'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_notification" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_notification" />
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_content_loaded" />
<tal:block define="header python: 'Computer Network :TEST-SLAPOSJS-NETWORK 0'; "> <tal:block define="header python: 'Computer Network :TEST-SLAPOSJS-NETWORK 0'; ">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" />
</tal:block> </tal:block>
<tr> <tr>
<td>type</td> <td>type</td>
<td>//input[@id="title"]</td> <td>//input[@id="title"]</td>
<td>TEST-SLAPOSJS-NETWORK 1</td> <td>TEST-SLAPOSJS-NETWORK 1</td>
</tr> </tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/save" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/save" />
<!-- check site --> <!-- check site -->
<!-- Broken history to return <!-- Broken history to return
<tr> <tr>
<td>click</td> <td>click</td>
<td>//a[@data-i18n="Site : TEST-SLAPOSJS-SET 0"]</td> <td>//a[@data-i18n="Site : TEST-SLAPOSJS-SET 0"]</td>
<td></td> <td></td>
</tr> </tr>
--> -->
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_activities_and_front_page" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_activities_and_front_page" />
<tal:block define="menu_item python: 'Networks'; header menu_item">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item" />
</tal:block>
<tal:block tal:define="pagination_configuration python: {'header': '(1)', 'footer': '1 Records'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" />
</tal:block>
<tr> <tal:block define="menu_item python: 'Networks'; header menu_item">
<td>waitForElementPresent</td> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item" />
<td>//a[text()="TEST-SLAPOSJS-NETWORK 1"]</td> </tal:block>
<td></td>
</tr> <tal:block tal:define="pagination_configuration python: {'header': '(1)', 'footer': '1 Records'}">
<tr> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" />
<td>click</td> </tal:block>
<td>//a[text()="TEST-SLAPOSJS-NETWORK 1"]</td>
<td></td>
</tr>
<tal:block define="header python: 'Computer Network :TEST-SLAPOSJS-NETWORK 1'; "> <tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" /> <td>waitForElementPresent</td>
</tal:block> <td>//a[text()="TEST-SLAPOSJS-NETWORK 1"]</td>
<td></td>
</tr>
<tr>
<td>click</td>
<td>//a[text()="TEST-SLAPOSJS-NETWORK 1"]</td>
<td></td>
</tr>
<tal:block define="header python: 'Computer Network :TEST-SLAPOSJS-NETWORK 1'; ">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" />
</tal:block>
<tal:block tal:define="delete_configuration python: {'header_title': 'Delete Network: TEST-SLAPOSJS-NETWORK 1',
<tal:block tal:define="delete_configuration python: {'header_title': 'Delete Network: TEST-SLAPOSJS-NETWORK 1',
'notification_text': 'Network is Deleted.'}"> 'notification_text': 'Network is Deleted.'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/delete_simple" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/delete_simple" />
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_activities_and_front_page" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_activities_and_front_page" />
<tal:block define="menu_item python: 'Networks'; header menu_item"> <tal:block define="menu_item python: 'Networks'; header menu_item">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item" />
</tal:block> </tal:block>
<tal:block tal:define="pagination_configuration python: {'header': '(0)', 'footer': 'No records'}"> <tal:block tal:define="pagination_configuration python: {'header': '(0)', 'footer': 'No records'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" />
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_logout" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_logout" />
</tbody></table> </tbody>
</table>
</body> </body>
</html> </html>
\ No newline at end of file
<html xmlns:tal="http://xml.zope.org/namespaces/tal" <html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
xmlns:metal="http://xml.zope.org/namespaces/metal">
<head> <head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test SlapJS UI</title> <title>Test SlapOS JS Organisation</title>
</head> </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_SlapOSCommonTemplate/macros/slapos_init" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_login" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_front_page" />
<tal:block define="person_name python: 'Demo User Functional'">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item_account" />
</tal:block>
<tal:block tal:define="pagination_configuration python: {'header': '(1)', 'footer': '1 Records'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" />
</tal:block>
<tal:block tal:define="pagination_configuration python: {'header': '(0)', 'footer': 'No records'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" />
</tal:block>
<tr> <body>
<td colspan="3"><b> Create an Organisation</b> </td> <table cellpadding="1" cellspacing="1" border="1">
</tr> <thead>
<tr>
<tal:block define="menu_action python: 'Add Organisation'"> <td rowspan="1" colspan="3">Test SlapOS JS Organisation</td>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_submenu_action" /> </tr>
</tal:block> </thead>
<tbody>
<tal:block define="header python: 'New Organisation'; "> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_init" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_login" />
</tal:block> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_front_page" />
<tr>
<td colspan="3"><b> Fill the form</b> </td> <tal:block define="person_name python: 'Demo User Functional'">
</tr> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item_account" />
</tal:block>
<tr>
<td>type</td> <tal:block tal:define="pagination_configuration python: {'header': '(1)', 'footer': '1 Records'}">
<td>//input[@name='title']</td> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" />
<td>demo_test_organisation_from_testSlapOSJSOrganisation</td> </tal:block>
</tr>
<tal:block tal:define="pagination_configuration python: {'header': '(0)', 'footer': 'No records'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" />
</tal:block>
<tal:block tal:define="notification_configuration python: {'class': 'success',
<tr>
<td colspan="3"><b> Create an Organisation</b> </td>
</tr>
<tal:block define="menu_action python: 'Add Organisation'">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_submenu_action" />
</tal:block>
<tal:block define="header python: 'New Organisation'; ">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" />
</tal:block>
<tr>
<td colspan="3"><b> Fill the form</b> </td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='title']</td>
<td>demo_test_organisation_from_testSlapOSJSOrganisation</td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" />
<tal:block tal:define="notification_configuration python: {'class': 'success',
'text': 'New Organisation created.'}"> 'text': 'New Organisation created.'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_notification" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_notification" />
</tal:block> </tal:block>
<tal:block define="header python: 'Organisation : demo_test_organisation_from_testSlapOSJSOrganisation'; "> <tal:block define="header python: 'Organisation : demo_test_organisation_from_testSlapOSJSOrganisation'; ">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" />
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_logout" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_logout" />
</tbody></table> </tbody>
</table>
</body> </body>
</html> </html>
\ No newline at end of file
<html xmlns:tal="http://xml.zope.org/namespaces/tal" <html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
xmlns:metal="http://xml.zope.org/namespaces/metal">
<head> <head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test SlapJS UI</title> <title>Test SlapOS JS Project</title>
</head> </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_SlapOSCommonTemplate/macros/slapos_init" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_login" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_front_page" />
<tal:block define="document_title python: 'TEST-SLAPOSJS-PROJECT 0';">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/create_simple_project" />
</tal:block>
<tr>
<td>type</td>
<td>//textarea[@id="description"]</td>
<td>TEST-SLAPOSJS-PROJECT DESCRIPTION</td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/save" />
<!-- check site --> <body>
<table cellpadding="1" cellspacing="1" border="1">
<!-- Broken history to return <thead>
<tr>
<td rowspan="1" colspan="3">Test SlapOS JS Project</td>
</tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_init" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_login" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_front_page" />
<tal:block define="document_title python: 'TEST-SLAPOSJS-PROJECT 0';">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/create_simple_project" />
</tal:block>
<tr>
<td>type</td>
<td>//textarea[@id="description"]</td>
<td>TEST-SLAPOSJS-PROJECT DESCRIPTION</td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/save" />
<!-- check site -->
<!-- Broken history to return
<tr> <tr>
<td>click</td> <td>click</td>
<td>//a[@data-i18n="Project : TEST-SLAPOSJS-PROJECT 0"]</td> <td>//a[@data-i18n="Project : TEST-SLAPOSJS-PROJECT 0"]</td>
...@@ -38,50 +39,52 @@ ...@@ -38,50 +39,52 @@
</tr> </tr>
--> -->
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_activities_and_front_page" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_activities_and_front_page" />
<tal:block define="menu_item python: 'Projects'; header menu_item"> <tal:block define="menu_item python: 'Projects'; header menu_item">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item" />
</tal:block> </tal:block>
<tal:block tal:define="pagination_configuration python: {'header': '(1)', 'footer': '1 Records'}"> <tal:block tal:define="pagination_configuration python: {'header': '(1)', 'footer': '1 Records'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" />
</tal:block> </tal:block>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//a[text()="TEST-SLAPOSJS-PROJECT 0"]</td> <td>//a[text()="TEST-SLAPOSJS-PROJECT 0"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>click</td> <td>click</td>
<td>//a[text()="TEST-SLAPOSJS-PROJECT 0"]</td> <td>//a[text()="TEST-SLAPOSJS-PROJECT 0"]</td>
<td></td> <td></td>
</tr> </tr>
<tal:block define="header python: 'Project : TEST-SLAPOSJS-PROJECT 0'; "> <tal:block define="header python: 'Project : TEST-SLAPOSJS-PROJECT 0'; ">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" />
</tal:block> </tal:block>
<tal:block tal:define="delete_configuration python: {'header_title': 'Delete Project: TEST-SLAPOSJS-PROJECT 0', <tal:block tal:define="delete_configuration python: {'header_title': 'Delete Project: TEST-SLAPOSJS-PROJECT 0',
'notification_text': 'Project is Deleted.'}"> 'notification_text': 'Project is Deleted.'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/delete_simple" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/delete_simple" />
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_activities_and_front_page" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_activities_and_front_page" />
<tal:block define="menu_item python: 'Projects'; header menu_item"> <tal:block define="menu_item python: 'Projects'; header menu_item">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item" />
</tal:block> </tal:block>
<tal:block tal:define="pagination_configuration python: {'header': '(0)', 'footer': 'No records'}"> <tal:block tal:define="pagination_configuration python: {'header': '(0)', 'footer': 'No records'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" />
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_logout" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_logout" />
</tbody></table> </tbody>
</table>
</body> </body>
</html> </html>
\ No newline at end of file
<html xmlns:tal="http://xml.zope.org/namespaces/tal" <html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
xmlns:metal="http://xml.zope.org/namespaces/metal">
<head> <head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test SlapJS UI</title> <title>Test SlapOS JS Server Token</title>
</head> </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_SlapOSCommonTemplate/macros/slapos_init" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_login" /> <body>
<table cellpadding="1" cellspacing="1" border="1">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_front_page" /> <thead>
<tr>
<td rowspan="1" colspan="3">Test SlapOS JS Server Token</td>
</tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_init" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_login" />
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_wait_for_front_page" />
<tal:block define="menu_item python: 'Servers'; header menu_item"> <tal:block define="menu_item python: 'Servers'; header menu_item">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/access_menu_item" />
</tal:block> </tal:block>
<tal:block tal:define="pagination_configuration python: {'header': '(0)', 'footer': 'No records'}"> <tal:block tal:define="pagination_configuration python: {'header': '(0)', 'footer': 'No records'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" />
</tal:block> </tal:block>
<tr> <tr>
<td colspan="3"><b tal:content="python: 'Click on Token'"> Menu Item </b></td> <td colspan="3"><b tal:content="python: 'Click on Token'"> Menu Item </b></td>
</tr> </tr>
<tal:block define="menu_action python: 'Token'"> <tal:block define="menu_action python: 'Token'">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_submenu_action" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_submenu_action" />
</tal:block> </tal:block>
<tal:block define="header python: 'Request New Token'; "> <tal:block define="header python: 'Request New Token'; ">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" />
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" />
<tal:block tal:define="notification_configuration python: {'class': 'success', <tal:block tal:define="notification_configuration python: {'class': 'success',
'text': 'Token is Requested.'}"> 'text': 'Token is Requested.'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_notification" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_notification" />
</tal:block> </tal:block>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//label[text()="Your Token"]</td> <td>//label[text()="Your Token"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>assertElementPresent</td> <td>assertElementPresent</td>
<td>//label[text()="Your Token"]</td> <td>//label[text()="Your Token"]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td tal:content="python: '//div[contains(@data-gadget-url, \'gadget_erp5_field_string.html\')]//p[contains(text(), \'%s%02d%02d-\')]' % (DateTime().year(),DateTime().month(),DateTime().day())"></td> <td
<td></td> tal:content="python: '//div[contains(@data-gadget-url, \'gadget_erp5_field_string.html\')]//p[contains(text(), \'%s%02d%02d-\')]' % (DateTime().year(),DateTime().month(),DateTime().day())">
</tr> </td>
<tr> <td></td>
<td>assertElementPresent</td> </tr>
<td tal:content="python: '//div[contains(@data-gadget-url, \'gadget_erp5_field_string.html\')]//p[contains(text(), \'%s%02d%02d-\')]' % (DateTime().year(),DateTime().month(),DateTime().day())"></td> <tr>
<td></td> <td>assertElementPresent</td>
</tr> <td
tal:content="python: '//div[contains(@data-gadget-url, \'gadget_erp5_field_string.html\')]//p[contains(text(), \'%s%02d%02d-\')]' % (DateTime().year(),DateTime().month(),DateTime().day())">
</td>
<tal:block define="header python: 'Request New Token'; "> <td></td>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" /> </tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_page_header" />
</tal:block>
<tal:block define="header python: 'Request New Token'; ">
<tr> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/assert_page_header" />
<td>waitForElementPresent</td> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_page_header" />
<td tal:content="python: '//div[contains(@data-gadget-url, \'gadget_erp5_field_listbox.html\')]//h1[contains(text(), \'Servers\')]'"></td> </tal:block>
<td></td>
</tr> <tr>
<tr> <td>waitForElementPresent</td>
<td>assertElementPresent</td> <td
<td tal:content="python: '//div[contains(@data-gadget-url, \'gadget_erp5_field_listbox.html\')]//h1[contains(text(), \'Servers\')]'"></td> tal:content="python: '//div[contains(@data-gadget-url, \'gadget_erp5_field_listbox.html\')]//h1[contains(text(), \'Servers\')]'">
<td></td> </td>
</tr> <td></td>
</tr>
<tal:block tal:define="pagination_configuration python: {'header': '(0)', 'footer': 'No records'}"> <tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" /> <td>assertElementPresent</td>
</tal:block> <td
tal:content="python: '//div[contains(@data-gadget-url, \'gadget_erp5_field_listbox.html\')]//h1[contains(text(), \'Servers\')]'">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_logout" /> </td>
<td></td>
</tbody></table> </tr>
<tal:block tal:define="pagination_configuration python: {'header': '(0)', 'footer': 'No records'}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/check_listbox_pagination_text" />
</tal:block>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/slapos_logout" />
</tbody>
</table>
</body> </body>
</html> </html>
\ No newline at end of file
...@@ -364,7 +364,7 @@ ...@@ -364,7 +364,7 @@
</tr> </tr>
<tr> <tr>
<td>click</td> <td>click</td>
<td tal:content="python: '//div[contains(@data-gadget-url, \'%s\')]//a[contains(text(), \'Account\')]' % panel_gadget_id"></td> <td tal:content="python: '//div[contains(@data-gadget-url, \'%s\')]//a[contains(text(), \'Login Account\')]' % panel_gadget_id"></td>
<td></td> <td></td>
</tr> </tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_content_loaded" />
......
portal = context.getPortalObject()
for cr in portal.portal_catalog(reference=["testSlapOSJSSubscribeUser", "demo_functional_user", "another_demo_functional_user"],
portal_type="Credential Request"):
related_person = cr.getDestinationDecisionValue()
if related_person is not None:
portal.person_module.manage_delObjects(ids=[related_person.getId()])
event_list = cr.getFollowUpRelatedValueList()
if len(event_list):
portal.event_module.manage_delObjects(ids=[e.getId() for e in event_list])
portal.credential_request_module.manage_delObjects(ids=[cr.getId()])
return "Done."
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