Author: dsvyatobatsko
Date: 2008-07-23 08:43:30 -0400 (Wed, 23 Jul 2008)
New Revision: 9745
Modified:
trunk/test-applications/seleniumTest/src/main/webapp/pages/inplaceInput/inplaceInputTest.xhtml
trunk/test-applications/seleniumTest/src/test/java/org/richfaces/testng/InplaceInputTest.java
Log:
some fixes
Modified:
trunk/test-applications/seleniumTest/src/main/webapp/pages/inplaceInput/inplaceInputTest.xhtml
===================================================================
(Binary files differ)
Modified:
trunk/test-applications/seleniumTest/src/test/java/org/richfaces/testng/InplaceInputTest.java
===================================================================
---
trunk/test-applications/seleniumTest/src/test/java/org/richfaces/testng/InplaceInputTest.java 2008-07-23
12:36:11 UTC (rev 9744)
+++
trunk/test-applications/seleniumTest/src/test/java/org/richfaces/testng/InplaceInputTest.java 2008-07-23
12:43:30 UTC (rev 9745)
@@ -13,8 +13,10 @@
private static final String INPLACE_INPUT_DECORATED_OK =
"inplaceInputDecoratedok";
- private static final String INPLACE_INPUT_FIELD_POSTFIX =
"inplaceTmpValue";
+ private static final String INPLACE_INPUT_DECORATED_CANCEL =
"inplaceInputDecoratedcancel";
+ private static final String INPLACE_INPUT_FIELD_POSTFIX = "tempValue";
+
private final static String EVENT_TEST_RESULT_FAILED_TEXT = "No";
private final static String EVENT_TEST_RESULT_PASSED_TEXT = "Passed";
@@ -49,9 +51,10 @@
writeStatus("Check component event triggering");
- String inplaceInputS = getParentId() + "_form:" +
INPLACE_INPUT_SIMPLE;
- String inplaceInputD = getParentId() + "_form:" +
INPLACE_INPUT_DECORATED;
- String inplaceInputDOk = getParentId() + "_form:" +
INPLACE_INPUT_DECORATED_OK;
+ String inplaceInputS = getParentId() + "_form:" +
INPLACE_INPUT_SIMPLE;
+ String inplaceInputD = getParentId() + "_form:" +
INPLACE_INPUT_DECORATED;
+ String inplaceInputDOk = getParentId() + "_form:" +
INPLACE_INPUT_DECORATED_OK;
+ String inplaceInputDCancel = getParentId() + "_form:" +
INPLACE_INPUT_DECORATED_CANCEL;
writeStatus("Click first component being tested");
@@ -60,17 +63,21 @@
writeStatus("Stop editing first component being tested");
- selenium.windowFocus();
+ String inplaceInputSInput = inplaceInputS + INPLACE_INPUT_FIELD_POSTFIX;
+ selenium.fireEvent(inplaceInputSInput, "blur");
+
AssertTextEquals(inplaceInputS + "_view",
EVENT_TEST_RESULT_PASSED_TEXT, "onviewactivated event is not fired");
writeStatus("Double-click second component being tested");
selenium.doubleClick(inplaceInputD);
AssertTextEquals(inplaceInputD + "_edit",
EVENT_TEST_RESULT_PASSED_TEXT, "oneditactivated event is not fired");
-
+ type(inplaceInputSInput, "Hello");
+
writeStatus("Stop editing second component being tested");
selenium.fireEvent(inplaceInputDOk, "mousedown");
+
AssertTextEquals(inplaceInputD + "_view",
EVENT_TEST_RESULT_PASSED_TEXT, "onviewactivated event is not fired");
}
Show replies by date