Author: mvanco(a)redhat.com
Date: 2010-05-03 02:28:05 -0400 (Mon, 03 May 2010)
New Revision: 2926
Modified:
portal/branches/EPP_5_0_Branch/testsuite/selenium-snifftests/pom.xml
portal/branches/EPP_5_0_Branch/testsuite/selenium-snifftests/src/main/java/org/exoplatform/portal/selenium/SeleniumTestCaseGenerator.java
portal/branches/EPP_5_0_Branch/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_SNF_PRL_13_AddRemoteAndCreateNewGadget.html
Log:
EPP5 UI Tests: improvement of generator - added function for if condition, improved test
13 (delete gadget if already exist), changed version of selenium-maven-plugin to 1.0.1
Modified: portal/branches/EPP_5_0_Branch/testsuite/selenium-snifftests/pom.xml
===================================================================
--- portal/branches/EPP_5_0_Branch/testsuite/selenium-snifftests/pom.xml 2010-05-01
21:11:26 UTC (rev 2925)
+++ portal/branches/EPP_5_0_Branch/testsuite/selenium-snifftests/pom.xml 2010-05-03
06:28:05 UTC (rev 2926)
@@ -18,7 +18,7 @@
<selenium.timeout>10000</selenium.timeout>
<selenium.speed>300</selenium.speed>
<selenium.host>localhost</selenium.host>
- <org.selenium.maven-plugin.version>1.0</org.selenium.maven-plugin.version>
+ <org.selenium.maven-plugin.version>1.0.1</org.selenium.maven-plugin.version>
</properties>
<dependencies>
Modified:
portal/branches/EPP_5_0_Branch/testsuite/selenium-snifftests/src/main/java/org/exoplatform/portal/selenium/SeleniumTestCaseGenerator.java
===================================================================
---
portal/branches/EPP_5_0_Branch/testsuite/selenium-snifftests/src/main/java/org/exoplatform/portal/selenium/SeleniumTestCaseGenerator.java 2010-05-01
21:11:26 UTC (rev 2925)
+++
portal/branches/EPP_5_0_Branch/testsuite/selenium-snifftests/src/main/java/org/exoplatform/portal/selenium/SeleniumTestCaseGenerator.java 2010-05-03
06:28:05 UTC (rev 2926)
@@ -418,6 +418,10 @@
sb.append("selenium.waitForPageToLoad(timeout);\n");
} else if (param1.equals("echo")) {
sb.append("System.out.println(\"" + param2 +
"\");\n");
+ } else if (param1.equals("startIfTextPresentCondition")) {
+ sb.append("if (selenium.isTextPresent(\"" + param2 + "\"))
{\n");
+ } else if (param1.equals("endIfTextPresentCondition")) {
+ sb.append("}\n");
} else if (param1.length() > 0) {
String message = param1 + " was not translated \"" + param2 +
"\"";
System.err.println("[ERROR] " + message);
Modified:
portal/branches/EPP_5_0_Branch/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_SNF_PRL_13_AddRemoteAndCreateNewGadget.html
===================================================================
---
portal/branches/EPP_5_0_Branch/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_SNF_PRL_13_AddRemoteAndCreateNewGadget.html 2010-05-01
21:11:26 UTC (rev 2925)
+++
portal/branches/EPP_5_0_Branch/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_SNF_PRL_13_AddRemoteAndCreateNewGadget.html 2010-05-03
06:28:05 UTC (rev 2926)
@@ -78,6 +78,61 @@
</tr>
<tr>
<td>echo</td>
+ <td>--Verify gadget present--</td>
+ <td></td>
+</tr>
+<tr>
+ <td>waitForElementPresent</td>
+ <td>xpath=//div[@class='IconControl AddNewIcon']</td>
+ <td></td>
+</tr>
+<tr>
+ <td>startIfTextPresentCondition</td>
+ <td>Date & Time</td>
+ <td></td>
+</tr>
+<tr>
+ <td>echo</td>
+ <td>--Delete already existing gadget--</td>
+ <td></td>
+</tr>
+<tr>
+ <td>waitForElementPresent</td>
+ <td>link=Date & Time</td>
+ <td></td>
+</tr>
+<tr>
+ <td>clickAt</td>
+ <td>link=Date & Time</td>
+ <td></td>
+</tr>
+<tr>
+ <td>waitForElementPresent</td>
+ <td>//div[@class='SelectedItem ItemContent']/a[@class='ControlIcon
DeletePortalIcon']</td>
+ <td></td>
+</tr>
+<tr>
+ <td>clickAt</td>
+ <td>//div[@class='SelectedItem ItemContent']/a[@class='ControlIcon
DeletePortalIcon']</td>
+ <td></td>
+</tr>
+<tr>
+ <td>waitForConfirmation</td>
+ <td>Are you sure to delete this gadget?</td>
+ <td></td>
+</tr>
+<tr>
+ <td>waitForElementNotPresent</td>
+ <td>link=Date & Time</td>
+ <td></td>
+</tr>
+<tr>
+ <td>endIfTextPresentCondition</td>
+ <td></td>
+ <td></td>
+</tr>
+<tr>
+ <td>echo</td>
<td>--Add a remote gadget--</td>
<td></td>
</tr>
Show replies by date