Author: ppitonak(a)redhat.com
Date: 2011-02-03 12:40:45 -0500 (Thu, 03 Feb 2011)
New Revision: 21424
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/cheiron/halt/XHRHalter.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/cheiron/retriever/ColorRetriever.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/cheiron/retriever/RetrieverAdapter.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/cheiron/retriever/ScriptEvaluationRetriever.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/RequestTypeModelGuard.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/SeleniumGetter.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/javascript/JQueryScript.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/javascript/JavaScriptEvaluator.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/locator/reference/LocatorReference.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/locator/reference/ReferencedLocator.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/waiting/WaitFactory.java
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/MatrixConfigurator.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MetamerFailureLoggingTestListener.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MetamerProperties.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MetamerSeleniumLoggingTestListener.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MetamerTestInfo.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richInputNumberSlider/TestRichSlider.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richInputNumberSpinner/TestRichSpinner.java
Log:
* added new tests for slider and spinner
* header fixed
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/cheiron/halt/XHRHalter.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/cheiron/halt/XHRHalter.java 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/cheiron/halt/XHRHalter.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -1,6 +1,6 @@
/*******************************************************************************
* JBoss, Home of Professional Open Source
- * Copyright 2010, Red Hat, Inc. and individual contributors
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/cheiron/retriever/ColorRetriever.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/cheiron/retriever/ColorRetriever.java 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/cheiron/retriever/ColorRetriever.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -1,6 +1,6 @@
/*
* JBoss, Home of Professional Open Source
- * Copyright 2010, Red Hat, Inc. and individual contributors
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/cheiron/retriever/RetrieverAdapter.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/cheiron/retriever/RetrieverAdapter.java 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/cheiron/retriever/RetrieverAdapter.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -1,6 +1,6 @@
/*******************************************************************************
* JBoss, Home of Professional Open Source
- * Copyright 2010, Red Hat, Inc. and individual contributors
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/cheiron/retriever/ScriptEvaluationRetriever.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/cheiron/retriever/ScriptEvaluationRetriever.java 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/cheiron/retriever/ScriptEvaluationRetriever.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -1,6 +1,6 @@
/*
* JBoss, Home of Professional Open Source
- * Copyright 2010, Red Hat, Inc. and individual contributors
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/RequestTypeModelGuard.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/RequestTypeModelGuard.java 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/RequestTypeModelGuard.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -1,6 +1,6 @@
/*
* JBoss, Home of Professional Open Source
- * Copyright 2010, Red Hat, Inc. and individual contributors
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/SeleniumGetter.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/SeleniumGetter.java 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/SeleniumGetter.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -1,6 +1,6 @@
/*
* JBoss, Home of Professional Open Source
- * Copyright 2010, Red Hat, Inc. and individual contributors
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/javascript/JQueryScript.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/javascript/JQueryScript.java 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/javascript/JQueryScript.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -1,6 +1,6 @@
/*
* JBoss, Home of Professional Open Source
- * Copyright 2010, Red Hat, Inc. and individual contributors
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/javascript/JavaScriptEvaluator.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/javascript/JavaScriptEvaluator.java 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/javascript/JavaScriptEvaluator.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -1,6 +1,6 @@
/*
* JBoss, Home of Professional Open Source
- * Copyright 2010, Red Hat, Inc. and individual contributors
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/locator/reference/LocatorReference.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/locator/reference/LocatorReference.java 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/locator/reference/LocatorReference.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -1,6 +1,6 @@
/*
* JBoss, Home of Professional Open Source
- * Copyright 2010, Red Hat, Inc. and individual contributors
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/locator/reference/ReferencedLocator.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/locator/reference/ReferencedLocator.java 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/locator/reference/ReferencedLocator.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -1,6 +1,6 @@
/*
* JBoss, Home of Professional Open Source
- * Copyright 2010, Red Hat, Inc. and individual contributors
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/waiting/WaitFactory.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/waiting/WaitFactory.java 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/jboss/test/selenium/waiting/WaitFactory.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -1,6 +1,6 @@
/*
* JBoss, Home of Professional Open Source
- * Copyright 2010, Red Hat, Inc. and individual contributors
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
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 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/AbstractMetamerTest.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -359,8 +359,7 @@
*/
protected void testHtmlAttribute(ElementLocator<?> element, String attribute,
String value) {
AttributeLocator<?> attr = element.getAttribute(new Attribute(attribute));
- assertFalse(selenium.isAttributePresent(attr), "Attribute " + attribute
+ " should not be present.");
-
+
selenium.type(pjq("input[id$=" + attribute + "Input]"),
value);
selenium.waitForPageToLoad();
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MatrixConfigurator.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MatrixConfigurator.java 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MatrixConfigurator.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -1,6 +1,6 @@
/*******************************************************************************
* JBoss, Home of Professional Open Source
- * Copyright 2010, Red Hat, Inc. and individual contributors
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MetamerFailureLoggingTestListener.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MetamerFailureLoggingTestListener.java 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MetamerFailureLoggingTestListener.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -1,6 +1,6 @@
/*******************************************************************************
* JBoss, Home of Professional Open Source
- * Copyright 2010, Red Hat, Inc. and individual contributors
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MetamerProperties.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MetamerProperties.java 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MetamerProperties.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -1,6 +1,6 @@
/*******************************************************************************
* JBoss, Home of Professional Open Source
- * Copyright 2010, Red Hat, Inc. and individual contributors
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MetamerSeleniumLoggingTestListener.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MetamerSeleniumLoggingTestListener.java 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MetamerSeleniumLoggingTestListener.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -1,6 +1,6 @@
/*******************************************************************************
* JBoss, Home of Professional Open Source
- * Copyright 2010, Red Hat, Inc. and individual contributors
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MetamerTestInfo.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MetamerTestInfo.java 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/MetamerTestInfo.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -1,6 +1,6 @@
/*******************************************************************************
* JBoss, Home of Professional Open Source
- * Copyright 2010, Red Hat, Inc. and individual contributors
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richInputNumberSlider/TestRichSlider.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richInputNumberSlider/TestRichSlider.java 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richInputNumberSlider/TestRichSlider.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -24,7 +24,6 @@
import java.text.ParseException;
import static
org.jboss.test.selenium.guard.request.RequestTypeGuardFactory.guardNoRequest;
import static org.jboss.test.selenium.guard.request.RequestTypeGuardFactory.guardXhr;
-import static org.jboss.test.selenium.locator.LocatorFactory.jq;
import static org.jboss.test.selenium.locator.option.OptionLocatorFactory.optionLabel;
import static org.jboss.test.selenium.utils.URLUtils.buildUrl;
import static org.testng.Assert.assertEquals;
@@ -39,6 +38,7 @@
import java.util.List;
import java.util.Set;
import java.util.TreeSet;
+
import javax.faces.event.PhaseId;
import org.jboss.test.selenium.css.CssProperty;
@@ -210,6 +210,11 @@
}
@Test
+ public void testAccesskey() {
+ testHtmlAttribute(input, "accesskey", "x");
+ }
+
+ @Test
public void testDecreaseClass() {
selenium.click(pjq("input[type=radio][name$=showArrowsInput][value=true]"));
selenium.waitForPageToLoad();
@@ -299,10 +304,9 @@
guardXhr(selenium).mouseDownAt(track, new Point(0, 0));
waitGui.failWith("Page was not updated").waitForChange(reqTime,
retrieveText.locator(time));
- assertPhases(PhaseId.RESTORE_VIEW, PhaseId.APPLY_REQUEST_VALUES,
PhaseId.PROCESS_VALIDATIONS,
+ phaseInfo.assertPhases(PhaseId.RESTORE_VIEW, PhaseId.APPLY_REQUEST_VALUES,
PhaseId.PROCESS_VALIDATIONS,
PhaseId.UPDATE_MODEL_VALUES, PhaseId.INVOKE_APPLICATION,
PhaseId.RENDER_RESPONSE);
- String listenerText = selenium.getText(jq("div#phasesPanel
li:eq(2)"));
- assertEquals(listenerText, "* value changed: 2 -> -10", "Value
change listener was not invoked.");
+ phaseInfo.assertListener(PhaseId.APPLY_REQUEST_VALUES, "value changed: 2
-> -10");
}
@Test
@@ -578,6 +582,34 @@
}
@Test
+ public void testStep() {
+
selenium.click(pjq("input[type=radio][name$=showArrowsInput][value=true]"));
+ selenium.waitForPageToLoad();
+ selenium.type(pjq("input[type=text][id$=delayInput]"),
"100");
+ selenium.waitForPageToLoad();
+ selenium.type(pjq("input[id$=stepInput]"), "7");
+ selenium.waitForPageToLoad();
+
+ clickArrow(right, 1);
+ assertEquals(selenium.getText(output), "9", "Wrong output");
+
+ clickArrow(right, 1);
+ assertEquals(selenium.getText(output), "10", "Wrong
output");
+
+ clickArrow(left, 1);
+ assertEquals(selenium.getText(output), "3", "Wrong output");
+
+ clickArrow(left, 1);
+ assertEquals(selenium.getText(output), "-4", "Wrong
output");
+
+ clickArrow(left, 1);
+ assertEquals(selenium.getText(output), "-10", "Wrong
output");
+
+ clickArrow(right, 1);
+ assertEquals(selenium.getText(output), "-3", "Wrong
output");
+ }
+
+ @Test
public void testStyle() {
testStyle(slider, "style");
}
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 2011-02-03
16:13:39 UTC (rev 21423)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richInputNumberSpinner/TestRichSpinner.java 2011-02-03
17:40:45 UTC (rev 21424)
@@ -1,6 +1,6 @@
/*******************************************************************************
* JBoss, Home of Professional Open Source
- * Copyright 2010, Red Hat, Inc. and individual contributors
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
@@ -160,6 +160,11 @@
}
@Test
+ public void testAccesskey() {
+ testHtmlAttribute(input, "accesskey", "x");
+ }
+
+ @Test
public void testCycled() {
JQueryLocator selectOption =
pjq("input[type=radio][name$=cycledInput][value=true]");
selenium.click(selectOption);
@@ -222,12 +227,13 @@
waitGui.failWith("Page was not updated").waitForChange(reqTime,
retrieveText.locator(time));
assertEquals(selenium.getText(output), "4", "Output was not
updated.");
- assertPhases(PhaseId.RESTORE_VIEW, PhaseId.APPLY_REQUEST_VALUES,
PhaseId.PROCESS_VALIDATIONS, PhaseId.UPDATE_MODEL_VALUES,
- PhaseId.INVOKE_APPLICATION, PhaseId.RENDER_RESPONSE);
+ phaseInfo.assertPhases(PhaseId.RESTORE_VIEW, PhaseId.APPLY_REQUEST_VALUES,
PhaseId.PROCESS_VALIDATIONS,
+ PhaseId.UPDATE_MODEL_VALUES, PhaseId.INVOKE_APPLICATION,
PhaseId.RENDER_RESPONSE);
+ phaseInfo.assertListener(PhaseId.APPLY_REQUEST_VALUES, "value changed: 2
-> 4");
}
@Test
- public void testItemContentClass() {
+ public void testInputClass() {
testStyleClass(input, "inputClass");
}
@@ -314,9 +320,7 @@
@Test
public void testOnchangeType() {
- ElementLocator<?> eventInput = pjq("input[id$=onchangeInput]");
- String value = "metamerEvents += \"change \"";
- selenium.type(eventInput, value);
+ selenium.type(pjq("input[id$=onchangeInput]"), "metamerEvents +=
\"change \"");
selenium.waitForPageToLoad(TIMEOUT);
selenium.getEval(new JavaScript("window.metamerEvents =
\"\";"));
@@ -333,9 +337,7 @@
@Test
public void testOnchangeClick() {
- ElementLocator<?> eventInput = pjq("input[id$=onchangeInput]");
- String value = "metamerEvents += \"change \"";
- selenium.type(eventInput, value);
+ selenium.type(pjq("input[id$=onchangeInput]"), "metamerEvents +=
\"change \"");
selenium.waitForPageToLoad(TIMEOUT);
selenium.getEval(new JavaScript("window.metamerEvents =
\"\";"));
@@ -471,6 +473,30 @@
}
@Test
+ public void testStep() {
+ selenium.type(pjq("input[id$=stepInput]"), "7");
+ selenium.waitForPageToLoad();
+
+ clickArrow(up, 1);
+ assertEquals(selenium.getText(output), "9", "Wrong output");
+
+ clickArrow(up, 1);
+ assertEquals(selenium.getText(output), "10", "Wrong
output");
+
+ clickArrow(down, 1);
+ assertEquals(selenium.getText(output), "3", "Wrong output");
+
+ clickArrow(down, 1);
+ assertEquals(selenium.getText(output), "-4", "Wrong
output");
+
+ clickArrow(down, 1);
+ assertEquals(selenium.getText(output), "-10", "Wrong
output");
+
+ clickArrow(up, 1);
+ assertEquals(selenium.getText(output), "-3", "Wrong
output");
+ }
+
+ @Test
public void testStyle() {
testStyle(spinner, "style");
}
@@ -481,6 +507,11 @@
}
@Test
+ public void testTabindex() {
+ testHtmlAttribute(input, "tabindex", "57");
+ }
+
+ @Test
@Use(field = "number", value = "correctNumbers")
public void testValueCorrect() {
selenium.type(pjq("input[id$=valueInput]"), number);