Title: [124806] trunk/LayoutTests
- Revision
- 124806
- Author
- [email protected]
- Date
- 2012-08-06 16:01:54 -0700 (Mon, 06 Aug 2012)
Log Message
Testcase LayoutTests/editing/input/editable-container-with-word-wrap-normal.html failing on Mac
https://bugs.webkit.org/show_bug.cgi?id=93287
Patch by Pravin D <[email protected]> on 2012-08-06
Reviewed by Ryosuke Niwa.
The testcase uses 'End' keypress event emulation to scroll the caret to the end of the line. As the behavior of 'End' keypress
is platform dependent, replacing it platform independent code.
* editing/input/editable-container-with-word-wrap-normal-expected.txt:
* editing/input/editable-container-with-word-wrap-normal.html:
Replaced 'End' keypress event with testRunner's execCommand() to make testcase behavior independent of platform.
Modified Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (124805 => 124806)
--- trunk/LayoutTests/ChangeLog 2012-08-06 23:01:06 UTC (rev 124805)
+++ trunk/LayoutTests/ChangeLog 2012-08-06 23:01:54 UTC (rev 124806)
@@ -1,3 +1,17 @@
+2012-08-06 Pravin D <[email protected]>
+
+ Testcase LayoutTests/editing/input/editable-container-with-word-wrap-normal.html failing on Mac
+ https://bugs.webkit.org/show_bug.cgi?id=93287
+
+ Reviewed by Ryosuke Niwa.
+
+ The testcase uses 'End' keypress event emulation to scroll the caret to the end of the line. As the behavior of 'End' keypress
+ is platform dependent, replacing it platform independent code.
+
+ * editing/input/editable-container-with-word-wrap-normal-expected.txt:
+ * editing/input/editable-container-with-word-wrap-normal.html:
+ Replaced 'End' keypress event with testRunner's execCommand() to make testcase behavior independent of platform.
+
2012-08-06 Roger Fong <[email protected]>
Layout Test: Windows specific tests needed for fast/css/getComputedStyle/computed-style.html & computed-style-without-renderer.html
Modified: trunk/LayoutTests/editing/input/editable-container-with-word-wrap-normal-expected.txt (124805 => 124806)
--- trunk/LayoutTests/editing/input/editable-container-with-word-wrap-normal-expected.txt 2012-08-06 23:01:06 UTC (rev 124805)
+++ trunk/LayoutTests/editing/input/editable-container-with-word-wrap-normal-expected.txt 2012-08-06 23:01:54 UTC (rev 124806)
@@ -2,6 +2,7 @@
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+To manually test, move the caret to the end of the line.
The content must scroll for the caret to reach the end of the editable text.
PASS editableContainer.scrollLeft > 0 is true
Modified: trunk/LayoutTests/editing/input/editable-container-with-word-wrap-normal.html (124805 => 124806)
--- trunk/LayoutTests/editing/input/editable-container-with-word-wrap-normal.html 2012-08-06 23:01:06 UTC (rev 124805)
+++ trunk/LayoutTests/editing/input/editable-container-with-word-wrap-normal.html 2012-08-06 23:01:54 UTC (rev 124806)
@@ -17,10 +17,6 @@
</style>
<script src=""
<script>
-startCaretRect = null;
-finalCaretRect = null;
-editableContainer = null;
-caretWidth = null;
function runTest() {
description('Testcase for bug <a href="" \
The test case checks if caret is drawn properly(especially scrolls properly) inside a editable container having word-wrap:normal.');
@@ -31,15 +27,16 @@
startCaretRect = internals.absoluteCaretBounds(document);
window.getSelection().setPosition(editableContainer,0);
- if (window.eventSender)
- eventSender.keyDown('end');
+ if (window.testRunner)
+ testRunner.execCommand('MoveToEndOfLine');
+ finalCaretRect = {right:-1,left:-1};
if (window.internals)
finalCaretRect = internals.absoluteCaretBounds(document);
caretWidth = finalCaretRect.right - finalCaretRect.left;
- debug("The content must scroll for the caret to reach the end of the editable text.")
+ debug('To manually test, move the caret to the end of the line. \nThe content must scroll for the caret to reach the end of the editable text.');
shouldBeTrue("editableContainer.scrollLeft > 0");
debug('<br>Final caret rect is calculated by following constraints');
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes