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

[pdm_test] Add RenderJS UI test for Stock View

parent 6879453c
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>test_renderjs_inventory_listbox_render</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html>
<head><title>Test quantity steps for price on internal supply line</title></head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr><td rowspan="1" colspan="4">
Test quantity steps for price on internal supply line
</td></tr>
</thead>
<tbody tal:define="init_method string:PdmZuite_createDelivery?state=ordered">
<tal:block metal:use-macro="here/PdmZuite_CommonTemplate/macros/init_rjs" />
<tr><td>waitForElementPresent</td>
<td>//a[@data-i18n="Views"]</td><td></td></tr>
<tr><td>click</td>
<td>//a[@data-i18n="Views"]</td><td></td></tr>
<tr><td>waitForElementPresent</td>
<td>//a[@data-i18n="Stock"]</td><td></td></tr>
<tr><td>click</td>
<td>//a[@data-i18n="Stock"]</td><td></td></tr>
<tr><td>store</td>
<td>//div[@data-gadget-url="${renderjs_url}/gadget_erp5_field_listbox.html"]//div[@class="document_table"]</td>
<td>container</td></tr>
<tr><td>waitForElementPresent</td>
<td>${container}/nav//span[@data-i18n="2 Records"]</td><td></td></tr>
<tr><td>assertText</td>
<td>${container}/table/tbody/tr[1]/td[1]//a</td>
<td>erp5_pdm_ui_test_destination_node_title</td></tr>
<!-- variation is not important -->
<tr><td>assertFloat</td>
<td>${container}/table/tbody/tr[1]/td[3]//p</td>
<td>0.0</td></tr>
<tr><td>assertFloat</td>
<td>${container}/table/tbody/tr[1]/td[4]//p</td>
<td>0.0</td></tr>
<tr><td>assertFloat</td>
<td>${container}/table/tbody/tr[1]/td[5]//p</td>
<td>1.0</td></tr>
<!-- ListBox shows "wrong" item link thus following it does not make sense
<!-- select explanation for the first stock inventory item ->
<tr><td>click</td>
<td>${container}/table/tbody/tr[1]/td[1]//a</td><td></td></tr>
<tr><td>waitForElementPresent</td>
<td>${container}/nav//span[@data-i18n="1 Records"]</td><td></td></tr>
<!-- ensure one movement explaining the item ->
<tr><td>assertText</td>
<td>${container}/table/tbody/tr[1]/td[1]//a</td>
<td>${year}/${month}/${day}</td></tr>
<tr><td>assertText</td>
<td>${container}/table/tbody/tr[1]/td[2]//a</td>
<td>Sale Order</td></tr>
<tr><td>assertText</td>
<td>${container}/table/tbody/tr[1]/td[3]//a</td>
<td>erp5_pdm_ui_test_delivery_title</td></tr>
<tr><td>assertText</td>
<td>${container}/table/tbody/tr[1]/td[4]//a</td>
<td>erp5_pdm_ui_test_destination_node_title</td></tr>
<tr><td>assertFloat</td>
<td>${container}/table/tbody/tr[1]/td[6]//a</td>
<td>1.0</td></tr>
<tr><td>assertText</td>
<td>${container}/table/tbody/tr[1]/td[7]//a</td>
<td>planned</td></tr>
-->
</tbody>
</table>
</body>
</html>
\ No newline at end of file
<tal:block xmlns:tal="http://xml.zope.org/namespaces/tal"
xmlns:metal="http://xml.zope.org/namespaces/metal">
<tal:block metal:define-macro="init">
<tal:block metal:use-macro="here/Zuite_CommonTemplate/macros/init" />
<tal:block metal:define-macro="prepare_data">
<tr>
<td>setTimeout</td>
<td>600000</td>
......@@ -60,6 +59,11 @@
<td>Done.</td>
<td></td>
</tr>
</tal:block>
<tal:block metal:define-macro="init">
<tal:block metal:use-macro="here/Zuite_CommonTemplate/macros/init" />
<tal:block metal:use-macro="here/PdmZuite_CommonTemplate/macros/prepare_data" />
<tr>
<td>open</td>
<td>${base_url}/product_module/erp5_pdm_ui_test_product/Resource_viewInventory</td>
......@@ -71,4 +75,20 @@
<td></td>
</tr>
</tal:block>
<tal:block metal:define-macro="init_rjs">
<tal:block metal:use-macro="here/Zuite_CommonTemplate/macros/init" />
<tal:block metal:use-macro="here/PdmZuite_CommonTemplate/macros/prepare_data" />
<tr>
<td>store</td>
<td>${base_url}/web_site_module/renderjs_runner</td>
<td>renderjs_url</td>
</tr>
<tr>
<td>open</td>
<td>${renderjs_url}/#/product_module/erp5_pdm_ui_test_product</td>
<td></td>
</tr>
</tal:block>
</tal:block>
\ No newline at end of file
Functional test suites for erp5_pdm
Functional test suites for erp5_pdm
Contains sample data as path items that may overwrite your existing data. Use at your own risks.
\ No newline at end of file
erp5_full_text_mroonga_catalog
\ No newline at end of file
erp5_full_text_mroonga_catalog
erp5_configurator_standard_trade_template
\ No newline at end of file
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