mochitest-plain: docshell/test/navigation/test_bug430723.html fails if asynchronous scroll doesn't finish by checking

RESOLVED FIXED in mozilla11

Status

()

Core
Keyboard: Navigation
RESOLVED FIXED
8 years ago
5 years ago

People

(Reporter: sgautherie, Assigned: masayuki)

Tracking

({intermittent-failure, regression})

Trunk
mozilla11
x86
All
intermittent-failure, regression
Points:
---
Dependency tree / graph
Bug Flags:
blocking1.9.2 -

Firefox Tracking Flags

(Not tracked)

Details

(URL)

Attachments

(1 attachment, 1 obsolete attachment)

(Reporter)

Description

8 years ago
[Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.9.2a1pre) Gecko/20090715 SeaMonkey/2.1a1pre] (home, optim default) (W2Ksp4)
(http://hg.mozilla.org/mozilla-central/rev/d190d9b6ccd1
 +http://hg.mozilla.org/comm-central/rev/773809454cf2 + bug 503724 patch)

{
...
... | Page2: Ensure we could scrol. - Didn't expect 0, but got it.
...
... | Page2Again: Ensure we can still scroll. - Didn't expect 0, but got it.
}

NB: While there, add missing 'l' to 'scrol'.

(I don't know if this is anyhow related to bug 465096.)
(Reporter)

Comment 1

8 years ago
[Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.9.2a1pre) Gecko/20090715
SeaMonkey/2.0b1pre] (experimental/_m-c_, home, optim default) (W2Ksp4)

(http://hg.mozilla.org/mozilla-central/rev/1057ca8f2a91
 +http://hg.mozilla.org/comm-central/rev/d1a9b79cf5c2)

Passes.

(http://hg.mozilla.org/mozilla-central/rev/cabb8925dcd3
 +http://hg.mozilla.org/comm-central/rev/d1a9b79cf5c2)

Fails.

Regression timeframe:
https://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=1057ca8f2a91&tochange=cabb8925dcd3
2 changesets:
bug 488846 is Firefox only,
then this is a "Bug 178324, refactor focus" fallout.

This is probably a case of bug 497839.
Blocks: 178324
Severity: minor → normal
Depends on: 497839
Flags: blocking1.9.2?
Keywords: regression
What's the issue here? Is test_bug430723 failing when you add some patch to seamonkey branch?
(Reporter)

Comment 3

8 years ago
(In reply to comment #2)

> What's the issue here?

The test used to pass even without being focused.

> Is test_bug430723 failing when you add some patch to seamonkey branch?

No sure what you mean.
(In reply to comment #3)
> (In reply to comment #2)
> The test used to pass even without being focused.

Maybe a regression from the great focus rewrite then.

Where is the test failing and under what conditions?

> > Is test_bug430723 failing when you add some patch to seamonkey branch?
> 
> No sure what you mean.

Your bug report is unclear. I was trying to guess what you meant based on the you comments provided.
(Reporter)

Comment 5

8 years ago
(In reply to comment #4)
> Maybe a regression from the great focus rewrite then.

Comment 1 says it is...

> Where is the test failing and under what conditions?

Comment 0 says 'Page2' and 'Page2Again' checks...

Summary says 'when test window does not have focus'...
(As in: run the test command from shell, (quickly) switch to another window, let the test load and run in background, ...)

> Your bug report is unclear.

Well, I thought it couldn't be clearer: has condition, error report, regression timeframe, ...
Summary: mochitest-plain: docshell/test/navigation/test_bug430723.html fails when reftest window does not have focus → mochitest-plain: docshell/test/navigation/test_bug430723.html fails when test window does not have focus
(In reply to comment #5)
> Summary says 'when test window does not have focus'...
> (As in: run the test command from shell, (quickly) switch to another window,
> let the test load and run in background, ...)

You should always leave the focus on the mochitest window. It's known to have problems when it loses focus. Many tests fail if the window loses focus.
(Reporter)

Comment 7

8 years ago
(In reply to comment #6)
> It's known to have problems when it loses focus.

It is ... and this bug is about the regression affecting this very test...
From what I understand from it, eventutils.sendkeyevent can't be expected to work when the window doesn't have focus.
That this apparently used to work is a bug, which is now fixed by bug 178324.
Linux mozilla-central test mochitests on 2009/07/22 19:35:28
http://tinderbox.mozilla.org/showlog.cgi?log=Firefox-Unittest/1248316528.1248318609.21339.gz
Blocks: 438871
OS: Windows 2000 → All
Whiteboard: [orange]

Comment 10

8 years ago
WINNT 5.2 mozilla-central test mochitests on 2009/07/28 10:26:40  
http://tinderbox.mozilla.org/showlog.cgi?log=Firefox-Unittest/1248802000.1248804768.21084.gz

Comment 11

8 years ago
29085 ERROR TEST-UNEXPECTED-FAIL | /tests/docshell/test/navigation/test_bug430723.html | Page2: Ensure we could scrol. - Didn't expect 0, but got it.

http://tinderbox.mozilla.org/showlog.cgi?log=Firefox-Unittest/1249925504.1249927242.28886.gz
Flags: blocking1.9.2? → blocking1.9.2-
Linux mozilla-central unit test on 2009/08/20 17:46:20
http://tinderbox.mozilla.org/showlog.cgi?log=Firefox/1250815580.1250822663.11076.gz

31093 ERROR TEST-UNEXPECTED-FAIL | /tests/docshell/test/navigation/test_bug430723.html | Page2: Ensure we could scrol. - Didn't expect 0, but got it.
etc.
Linux mozilla-central test mochitests on 2009/09/01 19:45:24
http://tinderbox.mozilla.org/showlog.cgi?log=Firefox-Unittest/1251859524.1251861874.13258.gz
(Reporter)

Comment 14

8 years ago
http://tinderbox.mozilla.org/showlog.cgi?log=Firefox-Unittest/1253114345.1253116296.23138.gz
Linux mozilla-central test mochitests on 2009/09/16 08:19:05

... | Page2: Ensure we could scrol. - Didn't expect 0, but got it.
http://tinderbox.mozilla.org/showlog.cgi?log=Firefox3.6-Unittest/1258457641.1258461442.15374.gz
WINNT 5.2 mozilla-1.9.2 test mochitests on 2009/11/17 03:34:01
http://tinderbox.mozilla.org/showlog.cgi?log=Firefox3.6-Unittest/1258602637.1258605859.22542.gz
Linux mozilla-1.9.2 test mochitests on 2009/11/18 19:50:37
Comment hidden (Treeherder Robot)
Created attachment 580056 [details] [diff] [review]
Patch

The cause isn't a focus problem.

The scroll by arrow keys are asynchronous scrolling. So, the scroll might not finish by next executeSoon. So, the tests should listen to scroll events before sending key events.

try:
https://tbpl.mozilla.org/?tree=Try&usebuildbot=1&rev=f670c36557ec
Assignee: nobody → masayuki
Status: NEW → ASSIGNED
Attachment #580056 - Flags: review?(bugs)
Comment on attachment 580056 [details] [diff] [review]
Patch

oops, we shouldn't send key events directly from event handlers. I'll post a new patch.
Attachment #580056 - Flags: review?(bugs)
Created attachment 580378 [details] [diff] [review]
Patch
Attachment #580056 - Attachment is obsolete: true
Attachment #580378 - Flags: review?(bugs)

Updated

5 years ago
Attachment #580378 - Flags: review?(bugs) → review+
https://hg.mozilla.org/integration/mozilla-inbound/rev/e218f75ccc41
Whiteboard: [orange] → [orange][inbound]
Target Milestone: --- → mozilla11
No longer depends on: 497839
Summary: mochitest-plain: docshell/test/navigation/test_bug430723.html fails when test window does not have focus → mochitest-plain: docshell/test/navigation/test_bug430723.html fails if asynchronous scroll doesn't finish by checking
https://hg.mozilla.org/mozilla-central/rev/e218f75ccc41
Status: ASSIGNED → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
Whiteboard: [orange][inbound] → [orange]
Keywords: intermittent-failure
Whiteboard: [orange]
You need to log in before you can comment on or make changes to this bug.