[richfaces-svn-commits] JBoss Rich Faces SVN: r12348 - in trunk/test-applications/seleniumTest/richfaces/src: test/java/org/richfaces/testng and 1 other directory.

richfaces-svn-commits at lists.jboss.org richfaces-svn-commits at lists.jboss.org
Tue Jan 20 07:26:30 EST 2009


Author: alevkovsky
Date: 2009-01-20 07:26:29 -0500 (Tue, 20 Jan 2009)
New Revision: 12348

Added:
   trunk/test-applications/seleniumTest/richfaces/src/main/webapp/pages/tabPanel/testTabServerModeWithExternalValidation.xhtml
Modified:
   trunk/test-applications/seleniumTest/richfaces/src/test/java/org/richfaces/testng/TabPanelTest.java
Log:
Tab panel selenium tests

Added: trunk/test-applications/seleniumTest/richfaces/src/main/webapp/pages/tabPanel/testTabServerModeWithExternalValidation.xhtml
===================================================================
(Binary files differ)


Property changes on: trunk/test-applications/seleniumTest/richfaces/src/main/webapp/pages/tabPanel/testTabServerModeWithExternalValidation.xhtml
___________________________________________________________________
Name: svn:mime-type
   + application/xhtml+xml

Modified: trunk/test-applications/seleniumTest/richfaces/src/test/java/org/richfaces/testng/TabPanelTest.java
===================================================================
--- trunk/test-applications/seleniumTest/richfaces/src/test/java/org/richfaces/testng/TabPanelTest.java	2009-01-20 12:25:30 UTC (rev 12347)
+++ trunk/test-applications/seleniumTest/richfaces/src/test/java/org/richfaces/testng/TabPanelTest.java	2009-01-20 12:26:29 UTC (rev 12348)
@@ -58,6 +58,8 @@
     private final static String IMMEDIATE_TAB_URL = "pages/tabPanel/immediateTabTest.xhtml";
     
     private final static String SERVER_AWARE_MODE_URL = "pages/tabPanel/testTabServerMode.xhtml";
+    
+    private final static String SERVER_AWARE_MODE_WITH_EXTERAL_VALIDATIO_URL = "pages/tabPanel/testTabServerModeWithExternalValidation.xhtml";
 
     private static Map<String, String> params = new HashMap<String, String>();
     
@@ -278,6 +280,15 @@
     }
     
     @Test
+    public void testAjaxSingleTabWithEXternalValidationFailureAndProcess(Template template) {
+        renderPage(INIT_AJAX_SINGLE_TEST_URL, template, INIT_AJAX_SINGLE_TEST);
+        
+
+        //FIXME https://jira.jboss.org/jira/browse/RF-5759
+        Assert.fail("https://jira.jboss.org/jira/browse/RF-5759");
+    }
+    
+    @Test
     public void testDisabledTabs(Template template) {
     	renderPage(DISABLED_TAB_URL, template, RESET_METHOD);
     	
@@ -387,6 +398,32 @@
     }
     
     @Test
+    public void testServerAwareModeWithExternalValidation(Template template) {
+    	renderPage(SERVER_AWARE_MODE_WITH_EXTERAL_VALIDATIO_URL, template, RESET_METHOD);
+    	
+    	String parentId = getParentId() + FORM_ID;
+    	String tab1 = parentId + "tab1";
+    	String tab2 = parentId + "tab2";
+    	String message = parentId + "message";
+    	String input = parentId + "external_input";
+    	
+    	AssertVisible(tab1, "TabPanel was not swtiched to the second tab");   	   	
+    	assertMessageEquals(message, "", "Validation was processed for rendered tab");
+    	
+    	clickCommandAndWait(tab2 + "_lbl");
+    	
+    	assertMessageNotEquals(message, "", "Validation was not processed for rendered tab");   	
+    	AssertVisible(tab1, "TabPanel was not swtiched to the second tab");
+    	
+    	setValueById(input, "Some text"); 	
+    	clickCommandAndWait(tab2 + "_lbl");
+    	
+    	assertMessageEquals(message, "", "Validation should be passed");   	
+    	AssertVisible(tab2, "TabPanel was not swtiched to the second tab");
+    	
+    }
+    
+    @Test
     public void testStylesAndClassesStandardAttributes(Template template) {
     	AutoTester autoTester = getAutoTester(this);
     	autoTester.renderPage(template, RESET_METHOD);




More information about the richfaces-svn-commits mailing list