Author: dsvyatobatsko
Date: 2009-02-20 06:56:17 -0500 (Fri, 20 Feb 2009)
New Revision: 12697
Added:
trunk/test-applications/seleniumTest/richfaces/src/main/webapp/pages/ajaxHTMLCommandLink/styleAndClasseStandardHTMLAttributesTest.xhtml
Modified:
trunk/test-applications/seleniumTest/richfaces/src/test/java/org/richfaces/testng/AjaxHTMLCommandLinkTest.java
Log:
https://jira.jboss.org/jira/browse/RF-6209
Added:
trunk/test-applications/seleniumTest/richfaces/src/main/webapp/pages/ajaxHTMLCommandLink/styleAndClasseStandardHTMLAttributesTest.xhtml
===================================================================
(Binary files differ)
Property changes on:
trunk/test-applications/seleniumTest/richfaces/src/main/webapp/pages/ajaxHTMLCommandLink/styleAndClasseStandardHTMLAttributesTest.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Modified:
trunk/test-applications/seleniumTest/richfaces/src/test/java/org/richfaces/testng/AjaxHTMLCommandLinkTest.java
===================================================================
---
trunk/test-applications/seleniumTest/richfaces/src/test/java/org/richfaces/testng/AjaxHTMLCommandLinkTest.java 2009-02-19
18:16:20 UTC (rev 12696)
+++
trunk/test-applications/seleniumTest/richfaces/src/test/java/org/richfaces/testng/AjaxHTMLCommandLinkTest.java 2009-02-20
11:56:17 UTC (rev 12697)
@@ -25,6 +25,7 @@
import org.ajax4jsf.template.Template;
import org.richfaces.AutoTester;
+import org.richfaces.SeleniumEvent;
import org.richfaces.SeleniumTestBase;
import org.testng.annotations.Test;
@@ -36,6 +37,8 @@
private final static String SUBMITTED_VALUE = "_form:_submittedValue";
+ private final static String LOOK_AND_FEEL_TEST_URL =
"pages/ajaxHTMLCommandLink/styleAndClasseStandardHTMLAttributesTest.xhtml";
+
private static Map<String, String> params = new HashMap<String,
String>();
static {
@@ -129,6 +132,25 @@
tester.testASRequestParameters(params);
}
+ @Test
+ public void testStandardHTMLAttributesAreOutputToClient(Template template) {
+ renderAutoTestPage(LOOK_AND_FEEL_TEST_URL, template, null);
+
+ writeStatus("Check standart HTML attributes");
+ assertEvents(getAutoTester(this).getClientId(AutoTester.COMPONENT_ID),
SeleniumEvent.STANDARD_HTML_EVENTS);
+ }
+
+ @Test
+ public void testStylesAndStyleClassesAreOutputToClient(Template template) {
+ renderAutoTestPage(LOOK_AND_FEEL_TEST_URL, template, null);
+ writeStatus("Check styles and classes are output to client");
+
+ writeStatus("Check styleClass/style attributes");
+ String componentId = getAutoTester(this).getClientId(AutoTester.COMPONENT_ID);
+ assertStyleAttributeContains(componentId, "font-size: 16px",
"Style attribute was not output to client");
+ assertClassAttributeContains(componentId, "noclass", "Class
attribute was not output to client");
+ }
+
@Override
public void sendAction() {
clickCommandAndWait(getAutoTester(this).getClientId(AutoTester.COMPONENT_ID));