Commit b58995c9 authored by Yusei Tahara's avatar Yusei Tahara

[erp5_dms_ui_test, erp5_km_ui_test] Fix outdated functional tests.

parent 4767c5d8
...@@ -77,7 +77,7 @@ Wait for activities</span> ...@@ -77,7 +77,7 @@ Wait for activities</span>
<td></td> <td></td>
</tr> </tr>
<td>waitForElementPresent</td> <td>waitForElementPresent</td>
<td>//select[@name="select_action"]</td> <td>//option[contains(@value, "publish_action")]</td>
<td></td> <td></td>
<tr> <tr>
<td>selectAndWait</td> <td>selectAndWait</td>
......
...@@ -77,7 +77,7 @@ Wait for activities</span> ...@@ -77,7 +77,7 @@ Wait for activities</span>
</tr> </tr>
<tr> <tr>
<td>verifyTextPresent</td> <td>verifyTextPresent</td>
<td>Converting</td> <td>Converted</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
...@@ -305,7 +305,7 @@ Wait for activities</span> ...@@ -305,7 +305,7 @@ Wait for activities</span>
</tr> </tr>
<tr> <tr>
<td>verifyTextPresent</td> <td>verifyTextPresent</td>
<td>Converting</td> <td>Converted</td>
<td></td> <td></td>
</tr> </tr>
...@@ -362,7 +362,7 @@ Wait for activities</span> ...@@ -362,7 +362,7 @@ Wait for activities</span>
</tr> </tr>
<tr> <tr>
<td>verifyTextPresent</td> <td>verifyTextPresent</td>
<td>Converting</td> <td>Converted</td>
<td></td> <td></td>
</tr> </tr>
......
...@@ -34,5 +34,13 @@ for gadget in context.portal_gadgets.objectValues(): ...@@ -34,5 +34,13 @@ for gadget in context.portal_gadgets.objectValues():
gadget.visible() gadget.visible()
gadget.public() gadget.public()
# Reject the tiolive logo image if it is published. This image
# is used by testContributeAndEmbedImageWithFCKEditor
tiolive_logo_image = context.portal_catalog.getResultValue(
reference='tiolive-ERP5.Freedom.TioLive.Logo',
validation_state='published')
if tiolive_logo_image is not None and tiolive_logo_image.getValidationState() == 'published':
tiolive_logo_image.reject()
print "Done" print "Done"
return printed return printed
...@@ -86,179 +86,27 @@ ...@@ -86,179 +86,27 @@
<td>PDF</td> <td>PDF</td>
<td></td> <td></td>
</tr> </tr>
<!-- Check PDF thumbnail preview works --> <!-- Check PDFJS preview appears -->
<tr> <tr>
<td>clickAndWait</td> <td>clickAndWait</td>
<td>link=Preview</td> <td>link=Preview</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>verifyText</td> <td>waitForElementPresent</td>
<td>//span[@class="listbox-current-page-start-number"]</td> <td>//div[@id='pageContainer1']</td>
<td>1</td>
</tr>
<tr>
<td>verifyText</td>
<td>//span[@class="listbox-current-page-stop-number"]</td>
<td>10</td>
</tr>
<tr>
<td>verifyText</td>
<td>//span[@class="listbox-current-page-total-number"]</td>
<td>16 records</td>
</tr>
<tr>
<td>verifyElementPresent</td>
<td>//img[@title='Thumbnail']</td>
<td></td>
</tr>
<!-- Check PDF thumbnail preview navigation-->
<tr>
<td>clickAndWait</td>
<td>//button[@class="listbox_next_page"]</td>
<td></td>
</tr>
<tr>
<td>verifyText</td>
<td>//span[@class="listbox-current-page-start-number"]</td>
<td>11</td>
</tr>
<tr>
<td>verifyText</td>
<td>//span[@class="listbox-current-page-stop-number"]</td>
<td>16</td>
</tr>
<tr>
<td>verifyText</td>
<td>//span[@class="listbox-current-page-total-number"]</td>
<td>16 records</td>
</tr>
<tr>
<td>verifyElementPresent</td>
<td>//img[@title='Thumbnail']</td>
<td></td>
</tr>
<tr>
<td>clickAndWait</td>
<td>//button[@class="listbox_previous_page"]</td>
<td></td>
</tr>
<tr>
<td>verifyText</td>
<td>//span[@class="listbox-current-page-start-number"]</td>
<td>1</td>
</tr>
<tr>
<td>verifyText</td>
<td>//span[@class="listbox-current-page-stop-number"]</td>
<td>10</td>
</tr>
<tr>
<td>verifyText</td>
<td>//span[@class="listbox-current-page-total-number"]</td>
<td>16 records</td>
</tr>
<tr>
<td>verifyElementPresent</td>
<td>//img[@title='Thumbnail']</td>
<td></td>
</tr>
<!-- Go to PDF default big preview -->
<tr>
<td>clickAndWait</td>
<td>//tr[@class="listbox-data-line-1 DataB"]/td/div/a/img[@title='Thumbnail']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@name="pdf_selection_index"]</td>
<td>2</td>
</tr>
<tr>
<td>verifyElementPresent</td>
<td>//img[@alt='First']</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>verifyElementPresent</td> <td>isElementPresent</td>
<td>//img[@alt='Previous']</td> <td>//button[@id='zoomOut']</td>
<td></td> <td></td>
</tr> </tr>
<tr> <tr>
<td>verifyElementPresent</td> <td>isElementPresent</td>
<td>//img[@alt='Next']</td> <td>//button[@id='zoomIn']</td>
<td></td> <td></td>
</tr> </tr>
<tr>
<td>verifyElementPresent</td>
<td>//img[@alt='Last']</td>
<td></td>
</tr>
<tr>
<td>verifyElementPresent</td>
<td>//div[@class='pdf-preview-content']/img</td>
<td></td>
</tr>
<!-- Check if PDF thumbnail navigation works -->
<tr>
<td>clickAndWait</td>
<td>//img[@alt='Next']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@name="pdf_selection_index"]</td>
<td>3</td>
</tr>
<tr>
<td>clickAndWait</td>
<td>//img[@alt='First']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@name="pdf_selection_index"]</td>
<td>1</td>
</tr>
<tr>
<td>clickAndWait</td>
<td>//img[@alt='Last']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@name="pdf_selection_index"]</td>
<td>16</td>
</tr>
<tr>
<td>clickAndWait</td>
<td>//img[@alt='First']</td>
<td></td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@name="pdf_selection_index"]</td>
<td>1</td>
</tr>
<!-- Type in test -->
<tr>
<td>type</td>
<td>//input[@name="pdf_selection_index"]</td>
<td>5</td>
</tr>
<tr>
<td>keyPressAndWait</td>
<td>//input[@name="pdf_selection_index"]</td>
<td>\13</td>
</tr>
<tr>
<td>verifyValue</td>
<td>//input[@name="pdf_selection_index"]</td>
<td>5</td>
</tr>
<tal:block metal:use-macro="here/KMZuite_CommonTemplate/macros/deleteKMWebSite" /> <tal:block metal:use-macro="here/KMZuite_CommonTemplate/macros/deleteKMWebSite" />
</tbody></table> </tbody></table>
......
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