Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
2010-09-23 Tony Chang <tony@chromium.org>
        Reviewed by David Levin.

        [chromium] make fast/events/standalone-image-drag-to-editable.html non-flakey
        https://bugs.webkit.org/show_bug.cgi?id=46381

        In chromium, the image that was dropped sometimes hasn't loaded when
        the pixel results are taken.  This results in a 0x0 image and makes
        the test flakey.  The fix is to wait for the image load event if it's
        not already loaded.

        * fast/events/resources/standalone-image-drag-to-editable-frame.html:
        * fast/events/standalone-image-drag-to-editable.html:
        * platform/chromium-linux/fast/events/standalone-image-drag-to-editable-expected.checksum: Image result with dropped image loaded.
        * platform/chromium-linux/fast/events/standalone-image-drag-to-editable-expected.png:
        * platform/chromium/test_expectations.txt:

Canonical link: https://commits.webkit.org/58912@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@68213 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
idealisms committed Sep 23, 2010
1 parent f16891c commit 8db5aef
Show file tree
Hide file tree
Showing 6 changed files with 40 additions and 8 deletions.
18 changes: 18 additions & 0 deletions LayoutTests/ChangeLog
@@ -1,3 +1,21 @@
2010-09-23 Tony Chang <tony@chromium.org>

Reviewed by David Levin.

[chromium] make fast/events/standalone-image-drag-to-editable.html non-flakey
https://bugs.webkit.org/show_bug.cgi?id=46381

In chromium, the image that was dropped sometimes hasn't loaded when
the pixel results are taken. This results in a 0x0 image and makes
the test flakey. The fix is to wait for the image load event if it's
not already loaded.

* fast/events/resources/standalone-image-drag-to-editable-frame.html:
* fast/events/standalone-image-drag-to-editable.html:
* platform/chromium-linux/fast/events/standalone-image-drag-to-editable-expected.checksum: Image result with dropped image loaded.
* platform/chromium-linux/fast/events/standalone-image-drag-to-editable-expected.png:
* platform/chromium/test_expectations.txt:

2010-09-23 Mihai Parparita <mihaip@chromium.org>

Reviewed by Tony Chang.
Expand Down
@@ -1,4 +1,21 @@
<html><body style='margin: 0 0 0 0;'><div style='height: 100px; border: solid 1px black;' contenteditable=true>
This layout test is checks that we don't crash when a stand alone image is dragged into a content editable div. <br />
<a href='rdar://problem/5021127'>rdar://problem/5021127</a>
</div></body></html>
</div></body>
<script>
function waitForImageLoad()
{
if (!window.layoutTestController)
return;

var img = document.body.getElementsByTagName("img")[0];
if (img.width != 0)
layoutTestController.notifyDone();
else {
img.addEventListener("load", function() {
layoutTestController.notifyDone();
}, false);
}
}
</script>
</html>
Expand Up @@ -10,13 +10,16 @@
eventSender.leapForward(500);
eventSender.mouseMoveTo(200, 50);
eventSender.mouseUp();
frames[0].waitForImageLoad();
}
var numFramesLoaded = 0;
function frameLoaded()
{
if (++numFramesLoaded == 2)
runTest();
}
if (window.layoutTestController)
layoutTestController.waitUntilDone();
</script>
<frameset rows="100px, 100px, *">
<frame onload="frameLoaded()" src="resources/standalone-image-drag-to-editable-frame.html">
Expand Down
@@ -1 +1 @@
7429c38b94fe347b650e87fa3b75d41f
b0912533e2471dd0f47bb205acbc2302
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 0 additions & 6 deletions LayoutTests/platform/chromium/test_expectations.txt
Expand Up @@ -2315,12 +2315,6 @@ BUG36019 WIN LINUX : fast/images/svg-as-tiled-background.html = IMAGE
// WebKit roll 55250 to 55339
BUG36966 : fast/loader/about-blank-hash-kept.html = FAIL

// Bugs that went unreported when we upstreamed run_webkit_tests
// This one may be an actual regression! Started being flaky after
// http://trac.webkit.org/log/?verbose=on&rev=55742&stop_rev=55710
BUG37896 LINUX : fast/events/standalone-image-drag-to-editable.html = IMAGE IMAGE+TEXT PASS TEXT
BUG37896 WIN : fast/events/standalone-image-drag-to-editable.html = IMAGE+TEXT PASS TEXT
BUG37896 MAC DEBUG : fast/events/standalone-image-drag-to-editable.html = IMAGE+TEXT PASS
// New test, added http://trac.webkit.org/changeset/55546
BUG37896 WIN LINUX : fast/multicol/hit-test-above-or-below.html = TEXT
// Added in http://trac.webkit.org/changeset/55669
Expand Down

0 comments on commit 8db5aef

Please sign in to comment.