WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
252554
WebKitTestRunner: Non-Cocoa TestController::platformAdjustContext should recreate WKPreferences
https://bugs.webkit.org/show_bug.cgi?id=252554
Summary
WebKitTestRunner: Non-Cocoa TestController::platformAdjustContext should recr...
Fujii Hironori
Reported
2023-02-19 23:21:20 PST
favicon-loads-with-images-disabled.html has LoadsImagesAutomatically=false. It makes some subsequent tests fail. Unexpected flakiness: text-only failures (2) http/tests/misc/image-blocked-src-change.html [ Pass Failure ] Unexpected flakiness: timeouts (2) http/tests/misc/image-checks-for-accept.html [ Timeout Pass ]
Attachments
WIP patch
(674 bytes, patch)
2023-02-20 21:36 PST
,
Fujii Hironori
no flags
Details
Formatted Diff
Diff
Patch
(1.48 KB, patch)
2023-02-21 12:48 PST
,
Fujii Hironori
no flags
Details
Formatted Diff
Diff
[fast-cq] Patch
(1.51 KB, patch)
2023-02-22 12:42 PST
,
Fujii Hironori
no flags
Details
Formatted Diff
Diff
Show Obsolete
(2)
View All
Add attachment
proposed patch, testcase, etc.
Fujii Hironori
Comment 1
2023-02-20 21:36:08 PST
Created
attachment 465103
[details]
WIP patch
Fujii Hironori
Comment 2
2023-02-20 22:39:34 PST
This isn't producible with Mac port. How does it reset the pref?
> run-webkit-tests http/tests/misc/favicon-loads-with-icon-loading-override.html http/tests/misc/image-blocked-src-change.html --iterations=2 --child-processes=1
Fujii Hironori
Comment 3
2023-02-20 23:52:47 PST
The implementations of TestController::platformPreferences and TestController::platformAdjustContext are different. TestController::ensureViewSupportsOptionsForTest decides to create a new webview because test options don't match. However, non-Cocoa TestController::platformPreferences constantly returns a same preference object. Cocoa's TestController::platformAdjustContext re-initializes it.
Fujii Hironori
Comment 4
2023-02-21 12:24:31 PST
The result of "grep -r LoadsImagesAutomatically *" in LayoutTests directory:
> fast/loader/display-image-unset-can-block-image-and-can-reload-in-place.html\012: internals.settings.setLoadsImagesAutomatically(false); > fast/loader/display-image-unset-can-block-image-and-can-reload-in-place.html\024: internals.settings.setLoadsImagesAutomatically(true); > http/tests/cache/display-image-unset-allows-cached-image-load.html\021: window.internals.settings.setLoadsImagesAutomatically(false); > http/tests/misc/favicon-loads-with-icon-loading-override.html\01:<html><!-- webkit-test-runner [ LoadsImagesAutomatically=false ] --> > http/tests/misc/favicon-loads-with-images-disabled.html\01:<html><!-- webkit-test-runner [ LoadsImagesAutomatically=false LoadsSiteIconsIgnoringImageLoadingPreference=false ] --> > svg/as-image/svg-image-with-data-uri-images-disabled.html\014: internals.settings.setLoadsImagesAutomatically(false);
LoadsImagesAutomatically=false webkit-test-runner header is used only by two tests. wk2/TestExpectations skipps both.
>
webkit.org/b/115809
http/tests/misc/favicon-loads-with-images-disabled.html >
webkit.org/b/115809
http/tests/misc/favicon-loads-with-icon-loading-override.html
This is the reason GTK and WPE layout tests don't observe this bug. wincairo/TestExpectations marks it as Failure for WinCairo WK1.
> http/tests/misc/favicon-loads-with-icon-loading-override.html [ Failure ]
This is the reason only WinCairo detects.
Fujii Hironori
Comment 5
2023-02-21 12:48:37 PST
Created
attachment 465113
[details]
Patch
Fujii Hironori
Comment 6
2023-02-22 11:42:10 PST
Comment on
attachment 465113
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=465113&action=review
> Tools/WebKitTestRunner/TestController.cpp:3082 > + WKPageGroupSetPreferences(m_pageGroup.get(), WKPreferencesCreate());
This pref leaks. I have to adopt it.
Fujii Hironori
Comment 7
2023-02-22 12:42:21 PST
Created
attachment 465123
[details]
[fast-cq] Patch
Darin Adler
Comment 8
2023-02-22 13:02:54 PST
Comment on
attachment 465123
[details]
[fast-cq] Patch Glad you caught the need to adopt!
EWS
Comment 9
2023-02-22 13:33:18 PST
Committed
260699@main
(b9b283e66f3d): <
https://commits.webkit.org/260699@main
> All reviewed patches have been landed. Closing bug and clearing flags on
attachment 465123
[details]
.
Radar WebKit Bug Importer
Comment 10
2023-02-22 13:34:19 PST
<
rdar://problem/105796205
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug