syncope-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ilgro...@apache.org
Subject svn commit: r1298457 - /incubator/syncope/trunk/console/src/test/java/org/syncope/console/ReportTestITCase.java
Date Thu, 08 Mar 2012 16:27:44 GMT
Author: ilgrosso
Date: Thu Mar  8 16:27:43 2012
New Revision: 1298457

URL: http://svn.apache.org/viewvc?rev=1298457&view=rev
Log:
[SYNCOPE-6] Test cases added to selenium profile

Added:
    incubator/syncope/trunk/console/src/test/java/org/syncope/console/ReportTestITCase.java
      - copied, changed from r1298416, incubator/syncope/trunk/console/src/test/java/org/syncope/console/SchemaTestITCase.java

Copied: incubator/syncope/trunk/console/src/test/java/org/syncope/console/ReportTestITCase.java
(from r1298416, incubator/syncope/trunk/console/src/test/java/org/syncope/console/SchemaTestITCase.java)
URL: http://svn.apache.org/viewvc/incubator/syncope/trunk/console/src/test/java/org/syncope/console/ReportTestITCase.java?p2=incubator/syncope/trunk/console/src/test/java/org/syncope/console/ReportTestITCase.java&p1=incubator/syncope/trunk/console/src/test/java/org/syncope/console/SchemaTestITCase.java&r1=1298416&r2=1298457&rev=1298457&view=diff
==============================================================================
--- incubator/syncope/trunk/console/src/test/java/org/syncope/console/SchemaTestITCase.java
(original)
+++ incubator/syncope/trunk/console/src/test/java/org/syncope/console/ReportTestITCase.java
Thu Mar  8 16:27:43 2012
@@ -20,47 +20,37 @@ package org.syncope.console;
 
 import org.junit.Test;
 
-public class SchemaTestITCase extends AbstractTest {
+public class ReportTestITCase extends AbstractTest {
 
     @Test
-    public void create() {
-        selenium.click("css=img[alt=\"Schema\"]");
-
-        selenium.waitForCondition(
-                "selenium.isElementPresent(\"//div[@id='tabs']\");", "30000");
-
-        selenium.click("//div[@id='tabs']/ul/li[2]/a/span");
-        selenium.click("//div[3]/div/div/a");
+    public void readReportlet() {
+        selenium.click("css=img[alt=\"Reports\"]");
+        selenium.waitForCondition("selenium.isElementPresent(\"//div[@id='tabs']\");", "30000");
 
+        selenium.click("//table/tbody/tr/td[6]/span/span[7]/a");
         selenium.waitForCondition("selenium.isElementPresent("
-                + "\"//*[@id='_wicket_window_0']\");",
-                "30000");
+                + "\"//form/div[2]/div/div/span/div/div[5]/div[2]/span/div[2]/div/a\");",
"30000");
 
+        selenium.click("css=img[alt=\"plus icon\"]");
         selenium.waitForCondition("selenium.isElementPresent("
-                + "\"//*[@name='name:textField']\");",
-                "30000");
+                + "\"//form/div[2]/div/div/div[2]/div[2]/span/select\");", "30000");
 
-        selenium.select("name=type:dropDownChoiceField", "value=0");
-        selenium.type("name=name:textField", "newschema");
-        selenium.click("name=apply");
+        selenium.select("//form/div[2]/div/div/div[2]/div[2]/span/select",
+                "label=org.syncope.client.report.UserReportletConf");
+        selenium.waitForCondition("selenium.isElementPresent(\"//form/div[2]/div[2]/div/span/div/div/span\")",
"30000");
 
-        selenium.waitForCondition(
-                "selenium.isTextPresent(\"newschema\");", "30000");
+        selenium.click("css=a.w_close");
+        selenium.click("css=a.w_close");
     }
 
     @Test
-    public void delete() {
-        selenium.click("css=img[alt=\"Schema\"]");
-
-        selenium.waitForCondition(
-                "selenium.isElementPresent(\"//div[@id='tabs']\");", "30000");
+    public void execute() {
+        selenium.click("css=img[alt=\"Reports\"]");
 
-        selenium.click("//div[@id='tabs']/ul/li[3]/a/span");
-        selenium.click("//div[@id='membership']/ul/li[3]/a/span");
+        selenium.waitForCondition("selenium.isElementPresent(\"//div[@id='tabs']\");", "30000");
 
-        selenium.click("//table/tbody/tr/td[3]/span/span[9]/a");
+        selenium.click("//table/tbody/tr/td[6]/span/span[3]/a");
 
-        assertTrue(selenium.getConfirmation().matches(
-                "^Do you really want to delete the selected item[\\s\\S]$"));
+        selenium.waitForCondition("selenium.isTextPresent(\"Operation executed successfully\");",
"30000");
     }
 }



Mime
View raw message