Bug 55674

Summary: Many tests fail in WebKit2 mode on Windows due to incorrect parsing of absolute Windows-style file: URLs
Product: WebKit Reporter: Adam Roben (:aroben) <aroben>
Component: Tools / TestsAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: abarth, eric.carlson, eric, jer.noble, webkit.review.bot
Priority: P2 Keywords: InRadar, LayoutTestFailure, PlatformOnly
Version: 528+ (Nightly build)   
Hardware: PC   
OS: Windows 7   
URL: http://build.webkit.org/results/Windows%207%20Release%20%28WebKit2%20Tests%29/r80235%20(3670)/results.html
Attachments:
Description Flags
Work around a bug in KURL's parsing of Windows-style absolute file: URLs timothy: review+

Description Adam Roben (:aroben) 2011-03-03 07:21:32 PST
Most/all media tests time out on Windows 7 Release (WebKit2 Tests). See the URL for an example.
Comment 1 Adam Roben (:aroben) 2011-03-03 08:01:14 PST
<rdar://problem/9080865>
Comment 2 Adam Roben (:aroben) 2011-03-03 08:50:25 PST
Just looking at media/audio-constructor-preload.html, I see HTMLMediaElement::scheduleLoad get called, but the load timer never fires.
Comment 3 Adam Roben (:aroben) 2011-03-03 09:02:25 PST
Even though the timer doesn't fire, HTMLMediaElement::load is getting called by JS, so the load is starting. But it looks like we're getting a bogus URL:

file://c/Documents%20and%20Settings/Adam%20Roben/dev/WebKit/OpenSource/LayoutTests/media/content/test.wav

Note the missing colon after "file://c". I think this is actually the root cause of a lot of test failures in WebKit2 on Windows.
Comment 4 Adam Roben (:aroben) 2011-03-03 09:03:50 PST
Just to close the loop on the timer issue: HTMLMediaElement::load is canceling the timer, since the load is now happening synchronously.
Comment 5 Adam Roben (:aroben) 2011-03-03 09:04:28 PST
Document::m_baseURL is also missing the colon.
Comment 6 Adam Roben (:aroben) 2011-03-03 09:05:46 PST
As is Document::m_documentURI.
Comment 7 Adam Roben (:aroben) 2011-03-03 09:22:54 PST
KURL::parse is getting passed this:

file://c:/Documents and Settings/Adam Roben/dev/WebKit/OpenSource/LayoutTests/media/audio-constructor-preload.html

It parses the colon in "c:" as introducing a port number. But then there is no port number so it continues on its merry way, and "c" gets set as the host. Clearly KURL is buggy with respect to absolute Windows-style file: URLs.

DRT on Windows used CFURL to convert the path into a URL.
Comment 8 Adam Roben (:aroben) 2011-03-03 09:25:18 PST
I have a workaround. I'll file a new bug for the underlying KURL issue.
Comment 9 Adam Roben (:aroben) 2011-03-03 09:27:29 PST
Bug 55683 covers the KURL issue.
Comment 10 Adam Roben (:aroben) 2011-03-03 09:32:03 PST
Created attachment 84574 [details]
Work around a bug in KURL's parsing of Windows-style absolute file: URLs
Comment 11 Adam Roben (:aroben) 2011-03-03 09:36:53 PST
Committed r80249: <http://trac.webkit.org/changeset/80249>
Comment 12 WebKit Review Bot 2011-03-03 11:22:06 PST
http://trac.webkit.org/changeset/80249 might have broken Windows 7 Release (Tests)
The following tests are not passing:
animations/combo-transform-rotate+scale.html
animations/keyframe-timing-functions-transform.html
inspector/extensions/extensions-audits.html