Commit c55bacd0 authored by Tomáš Peterka's avatar Tomáš Peterka

[accounting_renderjs_ui_test] Add test for "Update" action

parent 026cf7d4
...@@ -43,17 +43,6 @@ Copy of unittest <a href="https://lab.nexedi.com/nexedi/erp5/blob/master/product ...@@ -43,17 +43,6 @@ Copy of unittest <a href="https://lab.nexedi.com/nexedi/erp5/blob/master/product
<tr><td>click</td> <tr><td>click</td>
<td>//a[@data-i18n="Account Statement"]</td><td></td></tr> <td>//a[@data-i18n="Account Statement"]</td><td></td></tr>
<tr><td>waitForElementPresent</td>
<td>//div[@data-gadget-scope="field_your_node"]/div/div[1]//select</td><td></td></tr>
<tr><td>select</td>
<td>//div[@data-gadget-scope="field_your_node"]/div/div[1]//select</td>
<td>value=account_module/receivable</td></tr>
<tr><td>waitForElementPresent</td>
<td>//select[@name="field_your_section_category"]</td><td></td></tr>
<tr><td>select</td>
<td>//select[@name="field_your_section_category"]</td>
<td>value=group/demo_group/sub1</td></tr>
<tr><td>waitForElementPresent</td> <tr><td>waitForElementPresent</td>
<td>//input[@name="field_your_at_date"]</td><td></td></tr> <td>//input[@name="field_your_at_date"]</td><td></td></tr>
<tr><td>type</td> <tr><td>type</td>
...@@ -77,8 +66,47 @@ Copy of unittest <a href="https://lab.nexedi.com/nexedi/erp5/blob/master/product ...@@ -77,8 +66,47 @@ Copy of unittest <a href="https://lab.nexedi.com/nexedi/erp5/blob/master/product
<tr><td>select</td> <tr><td>select</td>
<td>//div[@data-gadget-scope="field_your_simulation_state"]/div/div[1]//select</td> <td>//div[@data-gadget-scope="field_your_simulation_state"]/div/div[1]//select</td>
<td>value=delivered</td></tr> <td>value=delivered</td></tr>
<tr><td>waitForElementPresent</td>
<td>//div[@data-gadget-scope="field_your_node"]/div/div[1]//select</td><td></td></tr>
<tr><td>select</td>
<td>//div[@data-gadget-scope="field_your_node"]/div/div[1]//select</td>
<td>value=account_module/receivable</td></tr>
<tr><td colspan="3">Test update button on a valid form</td></tr>
<!-- group/client does not have any Bank account assigned so we test on empty "Bank Account" field -->
<tr><td>waitForElementPresent</td>
<td>//select[@name="field_your_section_category"]</td><td></td></tr>
<tr><td>select</td>
<td>//select[@name="field_your_section_category"]</td>
<td>value=group/client</td></tr>
<tr><td>click</td>
<td>//div[@data-gadget-url="${renderjs_url}/gadget_erp5_page_form.html"]//button[@type="submit" and @name="action_update"]</td><td></td></tr>
<tr><td>waitForElementNotPresent</td>
<td>//select[@name="field_your_payment"]/option[2]</td><td></td></tr>
<tr><td>assertElementNotPresent</td>
<td>//select[@name="field_your_payment"]/option[2]</td><td></td></tr>
<tr><td>waitForElementPresent</td>
<td>//select[@name="field_your_section_category"]</td><td></td></tr>
<tr><td>select</td>
<td>//select[@name="field_your_section_category"]</td>
<td>value=group/demo_group/sub1</td></tr>
<tr><td>click</td>
<td>//div[@data-gadget-url="${renderjs_url}/gadget_erp5_page_form.html"]//button[@type="submit" and @name="action_update"]</td><td></td></tr>
<tr><td>waitForElementPresent</td>
<td>//select[@name="field_your_payment"]/option[2]</td><td></td></tr>
<tr><td>assertElementPresent</td>
<td>//select[@name="field_your_payment"]/option[@data-i18n="Bank1"]</td><td></td></tr>
<tr><td>assertElementPresent</td>
<td>//select[@name="field_your_payment"]/option[@data-i18n="Bank2"]</td><td></td></tr>
<tr><td>click</td> <tr><td>click</td>
<td>//div[@data-gadget-url="${renderjs_url}/gadget_erp5_page_form.html"]//input[@type="submit"]</td><td></td></tr> <td>//div[@data-gadget-url="${renderjs_url}/gadget_erp5_page_form.html"]//input[@type="submit" and @name="action_confirm"]</td><td></td></tr>
<tr><td>store</td> <tr><td>store</td>
<td>//div[@data-gadget-url="${renderjs_url}/gadget_erp5_field_listbox.html"]//table</td> <td>//div[@data-gadget-url="${renderjs_url}/gadget_erp5_field_listbox.html"]//table</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