Author: ppitonak(a)redhat.com
Date: 2010-11-15 10:26:58 -0500 (Mon, 15 Nov 2010)
New Revision: 20049
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/AbstractMetamerTest.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richAccordion/TestRichAccordion.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richInputNumberSpinner/TestRichSpinner.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richTab/TestRichTab.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richTabPanel/TestRichTabPanel.java
Log:
* testStyle refactored
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/AbstractMetamerTest.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/AbstractMetamerTest.java 2010-11-15
15:22:36 UTC (rev 20048)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/AbstractMetamerTest.java 2010-11-15
15:26:58 UTC (rev 20049)
@@ -163,12 +163,14 @@
/**
* A helper method for testing attribute "style". It sets
"background-color: yellow; font-size: 1.5em;" to the input
* field and checks that it was changed on the page.
- *
+ *
* @param element
* locator of tested element
+ * @param attribute
+ * name of the attribute that will be set (e.g. style, headerStyle,
itemContentStyle)
*/
- protected void testStyle(ElementLocator<?> element) {
- ElementLocator<?> styleInput = pjq("input[id$=styleInput]");
+ protected void testStyle(ElementLocator<?> element, String attribute) {
+ ElementLocator<?> styleInput = pjq("input[id$=" + attribute +
"Input]");
final String value = "background-color: yellow; font-size: 1.5em;";
selenium.type(styleInput, value);
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richAccordion/TestRichAccordion.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richAccordion/TestRichAccordion.java 2010-11-15
15:22:36 UTC (rev 20048)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richAccordion/TestRichAccordion.java 2010-11-15
15:26:58 UTC (rev 20049)
@@ -342,7 +342,7 @@
@Test
public void testStyle() {
- testStyle(accordion);
+ testStyle(accordion, "style");
}
@Test
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richInputNumberSpinner/TestRichSpinner.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richInputNumberSpinner/TestRichSpinner.java 2010-11-15
15:22:36 UTC (rev 20048)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richInputNumberSpinner/TestRichSpinner.java 2010-11-15
15:26:58 UTC (rev 20049)
@@ -474,7 +474,7 @@
@Test
public void testStyle() {
- testStyle(spinner);
+ testStyle(spinner, "style");
}
@Test
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richTab/TestRichTab.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richTab/TestRichTab.java 2010-11-15
15:22:36 UTC (rev 20048)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richTab/TestRichTab.java 2010-11-15
15:26:58 UTC (rev 20049)
@@ -336,7 +336,7 @@
@Test
public void testStyle() {
- testStyle(tab);
+ testStyle(tab, "style");
}
@Test
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richTabPanel/TestRichTabPanel.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richTabPanel/TestRichTabPanel.java 2010-11-15
15:22:36 UTC (rev 20048)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richTabPanel/TestRichTabPanel.java 2010-11-15
15:26:58 UTC (rev 20049)
@@ -316,7 +316,7 @@
@Test
public void testStyle() {
- testStyle(panel);
+ testStyle(panel, "style");
}
@Test
Show replies by date