Author: ppitonak(a)redhat.com
Date: 2010-11-23 08:29:42 -0500 (Tue, 23 Nov 2010)
New Revision: 20147
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richInplaceSelect/TestRichInplaceSelect.java
Log:
https://jira.jboss.org/browse/RF-9037
* added test for selectItemClass
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richInplaceSelect/TestRichInplaceSelect.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richInplaceSelect/TestRichInplaceSelect.java 2010-11-23
11:55:28 UTC (rev 20146)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richInplaceSelect/TestRichInplaceSelect.java 2010-11-23
13:29:42 UTC (rev 20147)
@@ -394,7 +394,7 @@
selenium.click(pjq("input[type=radio][name$=renderedInput][value=false]"));
selenium.waitForPageToLoad();
- assertFalse(selenium.isElementPresent(select), "Panel should not be rendered
when rendered=false.");
+ assertFalse(selenium.isElementPresent(select), "Component should not be
rendered when rendered=false.");
}
@Test
@@ -463,6 +463,21 @@
}
@Test
+ @IssueTracking("https://jira.jboss.org/browse/RF-9854")
+ public void testSelectItemClass() {
+ selenium.type(pjq("input[type=text][id$=selectItemClassInput]"),
"metamer-ftest-class");
+ selenium.waitForPageToLoad();
+
+ selenium.click(select);
+ selenium.mouseOver(options.format(0));
+
+ assertTrue(selenium.belongsClass(options.format(0),
"metamer-ftest-class"), "Selected item does not contains defined
class.");
+ for (int i = 1; i < 50; i++) {
+ assertFalse(selenium.belongsClass(options.format(i),
"metamer-ftest-class"), "Not selected item " + i + " should not
contain defined class.");
+ }
+ }
+
+ @Test
public void testShowControls() {
selenium.click(pjq("input[type=radio][name$=showControlsInput][value=true]"));
selenium.waitForPageToLoad();