Bug 164570

Summary: REGRESSION (r208522): LayoutTest fast/loader/reload-zero-byte-plugin.html is a flaky failure
Product: WebKit Reporter: Ryan Haddad <ryanhaddad>
Component: New BugsAssignee: Chris Dumez <cdumez>
Status: RESOLVED FIXED    
Severity: Normal CC: achristensen, cdumez, darin, rniwa
Priority: P2    
Version: Other   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 164458    
Attachments:
Description Flags
Patch simon.fraser: review+

Description Ryan Haddad 2016-11-09 17:00:17 PST
LayoutTest fast/loader/reload-zero-byte-plugin.html is failing

https://build.webkit.org/results/Apple%20Sierra%20Release%20WK2%20(Tests)/r208504%20(1288)/results.html

--- /Volumes/Data/slave/sierra-release-tests-wk2/build/layout-test-results/fast/loader/reload-zero-byte-plugin-expected.txt
+++ /Volumes/Data/slave/sierra-release-tests-wk2/build/layout-test-results/fast/loader/reload-zero-byte-plugin-actual.txt
@@ -1 +1,4 @@
+Download started.
+Downloading URL with suggested filename "Unknown"
+Download completed.
 This test passes if it doesn't crash. To run manually, please disable your popup blocker.
Comment 1 Ryan Haddad 2016-11-10 11:42:20 PST
Marked as flaky in http://trac.webkit.org/projects/webkit/changeset/208553
Comment 2 Ryan Haddad 2016-11-10 13:16:13 PST
Hmm, a similar diff with imported/w3c/web-platform-tests/html/browsers/browsing-the-web/read-media/pageload-video.html

https://build.webkit.org/results/Apple%20Yosemite%20Release%20WK2%20(Tests)/r208550%20(19346)/results.html
Comment 3 Ryan Haddad 2016-11-10 13:18:08 PST
I think this may be somehow related to http://trac.webkit.org/changeset/208522

The test fast/dom/HTMLAnchorElement/anchor-file-blob-download.html expects some of the text seen in the diffs above.

https://trac.webkit.org/browser/trunk/LayoutTests/fast/dom/HTMLAnchorElement/anchor-file-blob-download-expected.txt?rev=208522
Comment 4 Ryan Haddad 2016-11-10 15:45:34 PST
Similar failure here with http/tests/loading/text-content-type-with-binary-extension.html

https://build.webkit.org/results/Apple%20Yosemite%20Release%20WK2%20(Tests)/r208562%20(19351)/results.html
Comment 5 Chris Dumez 2016-11-10 15:51:56 PST
(In reply to comment #3)
> I think this may be somehow related to
> http://trac.webkit.org/changeset/208522
> 
> The test fast/dom/HTMLAnchorElement/anchor-file-blob-download.html expects
> some of the text seen in the diffs above.
> 
> https://trac.webkit.org/browser/trunk/LayoutTests/fast/dom/HTMLAnchorElement/
> anchor-file-blob-download-expected.txt?rev=208522

Actually, since the filename is "Unknown", this is unlikely to be https://trac.webkit.org/browser/trunk/LayoutTests/fast/dom/HTMLAnchorElement/
> anchor-file-blob-download-expected.txt.

$ git grep "Downloading URL with suggested filename" LayoutTests/ | grep nknown
LayoutTests/fast/dom/HTMLAnchorElement/anchor-download-expected.txt:Downloading URL with suggested filename "unknown"
LayoutTests/fast/dom/HTMLAnchorElement/anchor-download-user-triggered-synthetic-click-expected.txt:Downloading URL with suggested filename "unknown"
LayoutTests/fast/dom/HTMLAnchorElement/anchor-file-blob-convert-to-download-expected.txt:Downloading URL with suggested filename "unknown"
LayoutTests/fast/dom/HTMLAnchorElement/anchor-nodownload-set-expected.txt:Downloading URL with suggested filename "unknown"

Interestingly though, they all expect "unknown" with a lowercase "u" but the flaky test has "Unknown" with a capital "U".
Comment 6 Chris Dumez 2016-11-10 15:53:51 PST
(In reply to comment #5)
> (In reply to comment #3)
> > I think this may be somehow related to
> > http://trac.webkit.org/changeset/208522
> > 
> > The test fast/dom/HTMLAnchorElement/anchor-file-blob-download.html expects
> > some of the text seen in the diffs above.
> > 
> > https://trac.webkit.org/browser/trunk/LayoutTests/fast/dom/HTMLAnchorElement/
> > anchor-file-blob-download-expected.txt?rev=208522
> 
> Actually, since the filename is "Unknown", this is unlikely to be
> https://trac.webkit.org/browser/trunk/LayoutTests/fast/dom/HTMLAnchorElement/
> > anchor-file-blob-download-expected.txt.
> 
> $ git grep "Downloading URL with suggested filename" LayoutTests/ | grep
> nknown
> LayoutTests/fast/dom/HTMLAnchorElement/anchor-download-expected.txt:
> Downloading URL with suggested filename "unknown"
> LayoutTests/fast/dom/HTMLAnchorElement/anchor-download-user-triggered-
> synthetic-click-expected.txt:Downloading URL with suggested filename
> "unknown"
> LayoutTests/fast/dom/HTMLAnchorElement/anchor-file-blob-convert-to-download-
> expected.txt:Downloading URL with suggested filename "unknown"
> LayoutTests/fast/dom/HTMLAnchorElement/anchor-nodownload-set-expected.txt:
> Downloading URL with suggested filename "unknown"
> 
> Interestingly though, they all expect "unknown" with a lowercase "u" but the
> flaky test has "Unknown" with a capital "U".

LayoutTests/fast/dom/HTMLAnchorElement/anchor-file-blob-convert-to-download.html uses:
testRunner.setShouldDownloadUndisplayableMIMETypes(true);

Maybe this does not get reset properly between tests and it causes the next test to download.
Comment 7 Chris Dumez 2016-11-10 15:58:28 PST
Created attachment 294429 [details]
Patch
Comment 8 Chris Dumez 2016-11-10 16:02:49 PST
Committed r208569: <http://trac.webkit.org/changeset/208569>