Commit 2e760fba authored by Romain Courteaud's avatar Romain Courteaud

[erp5_web_renderjs_ui_test] Update tests after speed improvements

parent 3306eae0
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
<td></td> <td></td>
</tr> </tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_app_loaded" />
<tal:block tal:define="header_configuration python: {'text': 'Title', 'index': 0}"> <tal:block tal:define="header_configuration python: {'text': 'Title', 'index': 0}">
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/check_listbox_header" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/check_listbox_header" />
......
...@@ -42,7 +42,7 @@ ...@@ -42,7 +42,7 @@
<td></td> <td></td>
</tr> </tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_app_loaded" />
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/triggle_configure" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/triggle_configure" />
<tal:block tal:define="configure_section_configuration python: {'index': 0}"> <tal:block tal:define="configure_section_configuration python: {'index': 0}">
......
...@@ -42,7 +42,7 @@ ...@@ -42,7 +42,7 @@
<td></td> <td></td>
</tr> </tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_app_loaded" />
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/triggle_configure" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/triggle_configure" />
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/trash_editor_configuration" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/trash_editor_configuration" />
......
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
<td></td> <td></td>
</tr> </tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_app_loaded" />
<tal:block tal:define="header_configuration python: {'text': 'ID', 'index': 0}"> <tal:block tal:define="header_configuration python: {'text': 'ID', 'index': 0}">
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/check_listbox_header" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/check_listbox_header" />
......
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
<td></td> <td></td>
</tr> </tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_app_loaded" />
<tal:block tal:define="pagination_configuration python: {'header': '(1 - 3 / 10)', 'footer': 'Records 1 - 3 / 10'}"> <tal:block tal:define="pagination_configuration python: {'header': '(1 - 3 / 10)', 'footer': 'Records 1 - 3 / 10'}">
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/check_listbox_pagination_text" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/check_listbox_pagination_text" />
</tal:block> </tal:block>
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
<td>${base_url}/web_site_module/renderjs_runner/#/foo_module</td> <td>${base_url}/web_site_module/renderjs_runner/#/foo_module</td>
<td></td> <td></td>
</tr> </tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_app_loaded" />
<tal:block tal:define="search_query python: 'foo:&#34;bar&#34; AND barfoo'"> <tal:block tal:define="search_query python: 'foo:&#34;bar&#34; AND barfoo'">
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/search_in_form_list" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/search_in_form_list" />
......
...@@ -47,7 +47,7 @@ ...@@ -47,7 +47,7 @@
<td>//div[@data-gadget-url='${runner_url}gadget_erp5_panel.html']//div[@data-gadget-url='${runner_url}gadget_erp5_searchfield.html']//button[@type='submit']</td> <td>//div[@data-gadget-url='${runner_url}gadget_erp5_panel.html']//div[@data-gadget-url='${runner_url}gadget_erp5_searchfield.html']//button[@type='submit']</td>
<td></td> <td></td>
</tr> </tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_listbox_loaded" />
<!-- Verify that panel search query is empty but main search input is not --> <!-- Verify that panel search query is empty but main search input is not -->
<tr> <tr>
......
...@@ -352,12 +352,6 @@ ...@@ -352,12 +352,6 @@
<td></td> <td></td>
</tr> </tr>
<tr>
<td>waitForTextPresent</td>
<td>Foo Module</td>
<td></td>
</tr>
<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/clear_query" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/clear_query" />
......
...@@ -18,12 +18,7 @@ ...@@ -18,12 +18,7 @@
</tr> </tr>
<!-- Wait for gadget to be loaded --> <!-- Wait for gadget to be loaded -->
<tr> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_app_loaded" />
<td>waitForElementPresent</td>
<td>//div[@data-gadget-url='${base_url}/web_site_module/renderjs_runner/gadget_erp5_pt_form_list.html']</td>
<td></td>
</tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
<!-- Enter a search query to store the state --> <!-- Enter a search query to store the state -->
<tal:block tal:define="parsed_query python: ''; <tal:block tal:define="parsed_query python: '';
......
...@@ -51,7 +51,7 @@ ...@@ -51,7 +51,7 @@
<td></td> <td></td>
</tr> </tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_app_loaded" />
<tr> <tr>
<td>waitForTextPresent</td> <td>waitForTextPresent</td>
<td>Title 1</td> <td>Title 1</td>
......
...@@ -40,7 +40,7 @@ ...@@ -40,7 +40,7 @@
<td>//div[contains(@data-gadget-url, 'gadget_erp5_panel.html')]//button[@type='submit']</td> <td>//div[contains(@data-gadget-url, 'gadget_erp5_panel.html')]//button[@type='submit']</td>
<td></td> <td></td>
</tr> </tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_listbox_loaded" />
<!-- Wait for gadget to be loaded --> <!-- Wait for gadget to be loaded -->
...@@ -99,12 +99,12 @@ ...@@ -99,12 +99,12 @@
<td>//div[contains(@data-gadget-url, 'gadget_erp5_panel.html')]//a[@data-i18n='Search' and contains(@href, '#!display_stored_state') and contains(@href, 'n.page=search')]</td> <td>//div[contains(@data-gadget-url, 'gadget_erp5_panel.html')]//a[@data-i18n='Search' and contains(@href, '#!display_stored_state') and contains(@href, 'n.page=search')]</td>
<td></td> <td></td>
</tr> </tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" /> <tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_listbox_loaded" />
<!-- Wait for gadget to be loaded --> <!-- Wait for gadget to be loaded -->
<tr> <tr>
<td>waitForElementPresent</td> <td>verifyElementPresent</td>
<td>//div[@data-gadget-url='${base_url}/web_site_module/renderjs_runner/gadget_erp5_page_search.html']</td> <td>//div[@data-gadget-url='${base_url}/web_site_module/renderjs_runner/gadget_erp5_page_search.html']</td>
<td></td> <td></td>
</tr> </tr>
......
...@@ -211,6 +211,26 @@ ...@@ -211,6 +211,26 @@
</tr> </tr>
</tal:block> </tal:block>
<tal:block metal:define-macro="wait_for_app_loaded">
<tr>
<td colspan="3"><b>Wait for the application to be loaded</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//div[@class="ui-icon-spinner ui-btn-icon-notext first-loader"]</td>
<td></td>
</tr>
<tr>
<td>waitForElementNotPresent</td>
<td>//div[@class="ui-icon-spinner ui-btn-icon-notext first-loader"]</td>
<td></td>
</tr>
<tr>
<td colspan="3"><p></p></td>
</tr>
</tal:block>
<tal:block metal:define-macro="wait_for_content_loaded"> <tal:block metal:define-macro="wait_for_content_loaded">
<tr> <tr>
<td colspan="3"><b>Wait for the content to be loaded</b></td> <td colspan="3"><b>Wait for the content to be loaded</b></td>
......
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