Commit 5021516a authored by Romain Courteaud's avatar Romain Courteaud Committed by Xiaowu Zhang

erp5_web_renderjs_ui_test: stop relying on data-i18n attributes

parent 56859822
...@@ -55,7 +55,16 @@ ...@@ -55,7 +55,16 @@
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/submit_dialog" /> <tr>
<td>waitForElementPresent</td>
<td>//input[@value='Confirm']</td>
<td></td>
</tr>
<tr>
<td>click</td>
<td>//input[@value='Confirm']</td>
<td></td>
</tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
...@@ -89,14 +98,25 @@ ...@@ -89,14 +98,25 @@
<td>//input[@value='Login']</td> <td>//input[@value='Login']</td>
<td></td> <td></td>
</tr> </tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_app_loaded" />
<!-- come_from field in url is not empty --> <!-- come_from field in url is not empty -->
<tal:block tal:define="click_configuration python: {'text': 'Logout'}"> <tal:block tal:define="click_configuration python: {'text': 'Logout'}">
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/click_on_panel_link" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/click_on_panel_link" />
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/submit_dialog" /> <tr>
<td>waitForElementPresent</td>
<td>//input[@value='Confirm']</td>
<td></td>
</tr>
<tr>
<td>click</td>
<td>//input[@value='Confirm']</td>
<td></td>
</tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//input[@value='Login']</td> <td>//input[@value='Login']</td>
......
...@@ -35,7 +35,7 @@ ...@@ -35,7 +35,7 @@
<td></td> <td></td>
</tr> </tr>
<tal:block tal:define="click_configuration python: {'text': 'Actions'}"> <tal:block tal:define="click_configuration python: {'text': 'caozhuo'}">
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/click_on_header_link" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/click_on_header_link" />
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
......
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
<tal:block tal:define="click_configuration python: {'text': 'Editable'}"> <tal:block tal:define="click_configuration python: {'text': 'bianxue'}">
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/click_on_header_link" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/click_on_header_link" />
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
......
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
<tal:block tal:define="click_configuration python: {'text': 'Views'}"> <tal:block tal:define="click_configuration python: {'text': 'shitu'}">
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/click_on_header_link" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/click_on_header_link" />
</tal:block> </tal:block>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
......
...@@ -6,32 +6,32 @@ ...@@ -6,32 +6,32 @@
</tr> </tr>
<tr> <tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//div[@data-gadget-scope='header']//button[text()='Save']</td> <td>//div[@data-gadget-scope='header']//button[@data-i18n='Save']</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>assertElementPresent</td> <td>assertElementPresent</td>
<td>//div[@data-gadget-scope='header']//button[text()='Save']</td> <td>//div[@data-gadget-scope='header']//button[@data-i18n='Save']</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>waitForElementNotPresent</td> <td>waitForElementNotPresent</td>
<td>//div[@data-gadget-scope='header']//button[text()='Save'][contains(@class, "ui-disabled")]</td> <td>//div[@data-gadget-scope='header']//button[@data-i18n='Save'][contains(@class, "ui-disabled")]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>assertElementNotPresent</td> <td>assertElementNotPresent</td>
<td>//div[@data-gadget-scope='header']//button[text()='Save'][contains(@class, "ui-disabled")]</td> <td>//div[@data-gadget-scope='header']//button[@data-i18n='Save'][contains(@class, "ui-disabled")]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>assertElementPresent</td> <td>assertElementPresent</td>
<td>//div[@data-gadget-scope='header']//button[text()='Save']</td> <td>//div[@data-gadget-scope='header']//button[@data-i18n='Save']</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>click</td> <td>click</td>
<td>//div[@data-gadget-scope='header']//button[text()='Save']</td> <td>//div[@data-gadget-scope='header']//button[@data-i18n='Save']</td>
<td></td> <td></td>
</tr> </tr>
</tal:block> </tal:block>
...@@ -43,7 +43,7 @@ ...@@ -43,7 +43,7 @@
<!-- Save Button is disabled --> <!-- Save Button is disabled -->
<tr> <tr>
<td>verifyElementPresent</td> <td>verifyElementPresent</td>
<td>//button[text()="Save"][contains(@class, "ui-disabled")]</td> <td>//button[@data-i18n="Save"][contains(@class, "ui-disabled")]</td>
<td></td> <td></td>
</tr> </tr>
<!-- First loader while calling Base_edit --> <!-- First loader while calling Base_edit -->
...@@ -54,7 +54,7 @@ ...@@ -54,7 +54,7 @@
</tal:block> </tal:block>
<tr> <tr>
<td>verifyElementPresent</td> <td>verifyElementPresent</td>
<td>//button[text()="Save"][contains(@class, "ui-icon-check")]</td> <td>//button[@data-i18n="Save"][contains(@class, "ui-icon-check")]</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
......
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