Stop using dispatch_set_target_queue()
[WebKit-https.git] / Tools / ChangeLog
1 2018-03-23  David Kilzer  <ddkilzer@apple.com>
2
3         Stop using dispatch_set_target_queue()
4         <https://webkit.org/b/183908>
5         <rdar://problem/33553533>
6
7         Reviewed by Daniel Bates.
8
9         * Scripts/webkitpy/style/checkers/cpp.py:
10         (check_language): Add check for use of
11         dispatch_set_target_queue().
12         (CppChecker): Add 'runtime/dispatch_set_target_queue' category.
13         * Scripts/webkitpy/style/checkers/cpp_unittest.py:
14         (CppStyleTest): Add test.
15
16 2018-03-23  Youenn Fablet  <youenn@apple.com>
17
18         Allow fully whitelisted plug-ins to match non HTTP URLs
19         https://bugs.webkit.org/show_bug.cgi?id=183938
20         rdar://problem/38534312
21
22         Reviewed by Chris Dumez.
23
24         * TestWebKitAPI/Tests/WebCore/URL.cpp:
25         (TestWebKitAPI::TEST_F):
26
27 2018-03-23  JF Bastien  <jfbastien@apple.com>
28
29         dump-class-layout is just wrong
30         https://bugs.webkit.org/show_bug.cgi?id=183939
31
32         Reviewed by Yusuke Suzuki.
33
34         Looks like r229291 contained a half-renamed variable in it, so it
35         just doesn't work.
36
37         * Scripts/dump-class-layout:
38         (verify_type):
39         (verify_type_recursive):
40
41 2018-03-23  Carlos Garcia Campos  <cgarcia@igalia.com>
42
43         Unreviewed. Run JSC GLib API tests in GTK+ and WPE bots.
44
45         The test runners were still considering the JSC tests as google tests, but they are now GLib tests.
46
47         * Scripts/run-gtk-tests:
48         (GtkTestRunner.is_glib_test):
49         (GtkTestRunner.is_google_test):
50         * Scripts/run-wpe-tests:
51         (WPETestRunner.is_glib_test):
52         (WPETestRunner.is_google_test):
53
54 2018-03-22  Daniel Bates  <dabates@apple.com>
55
56         Expose SchemeRegistry::registerAsCanDisplayOnlyIfCanRequest() as WebKit SPI
57         https://bugs.webkit.org/show_bug.cgi?id=183907
58         <rdar://problem/38759127>
59
60         Reviewed by Alex Christensen.
61
62         Adds unit tests for the modern Objective-C and C SPI to ensure we do not regress it.
63
64         We use the deprecated -[WKBrowsingContextController registerSchemeForCustomProtocol:]
65         in both the modern Objective-C API and C API tests to share code. Once we no longer
66         need to support the C API we should remove the tests and transition the modern Objective-
67         C tests to use -[WKWebViewConfiguration setURLSchemeHandler:forURLScheme:].
68
69         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
70         * TestWebKitAPI/Tests/WebKitCocoa/SchemeRegistry.mm: Added.
71         (+[EchoURLProtocol canInitWithRequest:]):
72         (+[EchoURLProtocol canonicalRequestForRequest:]):
73         (+[EchoURLProtocol requestIsCacheEquivalent:toRequest:]):
74         (-[EchoURLProtocol startLoading]):
75         (-[EchoURLProtocol stopLoading]):
76         (-[WKContextRegisterURLSchemeAsCanDisplayOnlyIfCanRequestLoadDelegate browsingContextController:didFailProvisionalLoadWithError:]):
77         (-[WKContextRegisterURLSchemeAsCanDisplayOnlyIfCanRequestLoadDelegate browsingContextControllerDidFinishLoad:]):
78         (TestWebKitAPI::TEST):
79
80 2018-03-22  Adrian Perez de Castro  <aperez@igalia.com>
81
82         [WPE] Enable WOFF2 support
83         https://bugs.webkit.org/show_bug.cgi?id=178158
84
85         Reviewed by Frédéric Wang.
86
87         * wpe/jhbuild.modules: Add "brotli" and "woff2" to the JHBuild moduleset.
88
89 2018-03-22  Brendan McLoughlin  <brendan@bocoup.com>
90
91         Do not export web-platform-test files generated by the wpt importer to assist the webkit test runner
92         https://bugs.webkit.org/show_bug.cgi?id=183916
93
94         Reviewed by Youenn Fablet.
95
96         * Scripts/webkitpy/w3c/test_exporter.py:
97         (TestExporter.create_branch_with_patch):
98         * Scripts/webkitpy/w3c/test_exporter_unittest.py:
99         (TestExporterTest.test_export):
100         (TestExporterTest.test_export_with_specific_branch):
101
102 2018-03-22  Tim Horton  <timothy_horton@apple.com>
103
104         Improve readability of WebCore's OTHER_LDFLAGS
105         https://bugs.webkit.org/show_bug.cgi?id=183909
106         <rdar://problem/38760992>
107
108         Reviewed by Dan Bernstein.
109
110         * TestWebKitAPI/Configurations/Base.xcconfig:
111         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
112
113 2018-03-21  Fujii Hironori  <Hironori.Fujii@sony.com>
114
115         Unreviewed. Marked myself as a committer.
116
117         * Scripts/webkitpy/common/config/contributors.json:
118
119 2018-03-21  Yoshiaki Jitsukawa  <yoshiaki.jitsukawa@sony.com>
120
121         Unreviewed, make the email address of Yoshiaki Jitsukawa all lower case.
122
123         * Scripts/webkitpy/common/config/contributors.json:
124
125 2018-03-21  Yoshiaki Jitsukawa  <Yoshiaki.Jitsukawa@sony.com>
126
127         Unreviewed, add myself as a WebKit committer.
128
129         * Scripts/webkitpy/common/config/contributors.json:
130
131 2018-03-21  Chris Dumez  <cdumez@apple.com>
132
133         ScrollViewInsetTests.RestoreInitialContentOffsetAfterCrash API test is failing with async delegates
134         https://bugs.webkit.org/show_bug.cgi?id=183787
135
136         Reviewed by Wenson Hsieh.
137
138         Add API test coverage.
139
140         * TestWebKitAPI/Tests/ios/ScrollViewInsetTests.mm:
141         (-[AsyncPolicyDelegateForInsetTest webView:didFinishNavigation:]):
142         (-[AsyncPolicyDelegateForInsetTest webView:decidePolicyForNavigationAction:decisionHandler:]):
143         (-[AsyncPolicyDelegateForInsetTest webView:decidePolicyForNavigationResponse:decisionHandler:]):
144         (-[AsyncPolicyDelegateForInsetTest webViewWebContentProcessDidTerminate:]):
145         (TestWebKitAPI::TEST):
146
147 2018-03-21  Chris Dumez  <cdumez@apple.com>
148
149         Fix DataInteractionTests.InjectedBundleAllowPerformTwoStepDrop to use synchronouslyLoadTestPageNamed
150         https://bugs.webkit.org/show_bug.cgi?id=183858
151
152         Reviewed by Wenson Hsieh.
153
154         Fix DataInteractionTests.InjectedBundleAllowPerformTwoStepDrop to use synchronouslyLoadTestPageNamed
155         instead of loadTestPageNamed because injecting script.
156
157         * TestWebKitAPI/Tests/ios/DataInteractionTests.mm:
158         (TestWebKitAPI::TEST):
159
160 2018-03-21  Zalan Bujtas  <zalan@apple.com>
161
162         [LayoutReloaded] Enable formatting state for InlineFormattingContext
163         https://bugs.webkit.org/show_bug.cgi?id=183853
164
165         Reviewed by Antti Koivisto.
166
167         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:
168         (BlockFormattingContext.prototype._contentHeight):
169         * LayoutReloaded/FormattingContext/InlineFormatting/InlineFormattingContext.js:
170         (InlineFormattingContext):
171         (InlineFormattingContext.prototype.layout):
172         (InlineFormattingContext.prototype._createNewLine):
173         * LayoutReloaded/LayoutState.js:
174         (LayoutState.prototype.formattingState):
175         * LayoutReloaded/README.md:
176         * LayoutReloaded/Utils.js:
177         (Utils._dumpTree):
178         * LayoutReloaded/test/index.html:
179         * LayoutReloaded/test/simple-inline-text.html: Added.
180
181 2018-03-21  Zalan Bujtas  <zalan@apple.com>
182
183         [LayoutReloaded] Move inline lines to InlineFormattingState.
184         https://bugs.webkit.org/show_bug.cgi?id=183814
185
186         Reviewed by Antti Koivisto.
187
188         InlineFormattingContext is not supposed to hold state.
189
190         * LayoutReloaded/FormattingContext/InlineFormatting/InlineFormattingContext.js:
191         (InlineFormattingContext):
192         (InlineFormattingContext.prototype._commitLine):
193         (InlineFormattingContext.prototype._createNewLine):
194         (InlineFormattingContext.prototype.lines): Deleted.
195         (InlineFormattingContext.prototype._initializeLine): Deleted.
196         * LayoutReloaded/FormattingState/InlineFormattingState.js:
197         (InlineFormattingState):
198         (InlineFormattingState.prototype.lines):
199         (InlineFormattingState.prototype.appendLine):
200
201 2018-03-21  Ms2ger  <Ms2ger@igalia.com>
202
203         [WPE] Disable most of TestWebKitFaviconDatabase.
204         https://bugs.webkit.org/show_bug.cgi?id=183813
205
206         Unreviewed test gardening.
207
208         The relevant APIs were mostly removed in r223953, making this test
209         time out consistently.
210
211         * TestWebKitAPI/Tests/WebKitGLib/TestWebKitFaviconDatabase.cpp:
212
213 2018-03-21  Carlos Garcia Campos  <cgarcia@igalia.com>
214
215         [GTK][WPE] JSC bindings not introspectable
216         https://bugs.webkit.org/show_bug.cgi?id=136989
217
218         Reviewed by Michael Catanzaro.
219
220         Use the new API instead of the deprecated one.
221
222         * MiniBrowser/gtk/main.c:
223         (aboutDataScriptMessageReceivedCallback):
224         * TestWebKitAPI/Tests/WebKitGLib/FrameTest.cpp:
225         (WebKitFrameTest::testJavaScriptContext):
226         * TestWebKitAPI/Tests/WebKitGLib/TestWebKitWebView.cpp:
227         (testWebViewRunJavaScript):
228         * TestWebKitAPI/Tests/WebKitGLib/WebExtensionTest.cpp:
229         (consoleMessageSentCallback):
230         (echoCallback):
231         (windowObjectCleared):
232         (methodCallCallback):
233         * TestWebKitAPI/Tests/WebKitGLib/WebProcessTest.cpp:
234         (runTest):
235         (webProcessTestRunnerFinalize):
236         (windowObjectClearedCallback):
237         * TestWebKitAPI/glib/PlatformGTK.cmake:
238         * TestWebKitAPI/glib/WebKitGLib/WebViewTest.cpp:
239         (WebViewTest::javascriptResultToCString):
240         (WebViewTest::javascriptResultToNumber):
241         (WebViewTest::javascriptResultToBoolean):
242         (WebViewTest::javascriptResultIsNull):
243         (WebViewTest::javascriptResultIsUndefined):
244
245 2018-03-21  Carlos Garcia Campos  <cgarcia@igalia.com>
246
247         [GTK][WPE] Initial implementation of JavaScriptCore glib bindings
248         https://bugs.webkit.org/show_bug.cgi?id=164061
249
250         Reviewed by Michael Catanzaro.
251
252         Add unit tests for the new API and generate the API documentation with generate-gtkdoc.
253
254         * Scripts/webkitpy/style/checker.py: Ignore some style errors in public GLib API headers.
255         * TestWebKitAPI/PlatformGTK.cmake:
256         * TestWebKitAPI/PlatformWPE.cmake:
257         * TestWebKitAPI/Tests/JavaScriptCore/glib/TestJSC.cpp: Added.
258         (LeakChecker::~LeakChecker):
259         (LeakChecker::watch):
260         (ExceptionHandler::ExceptionHandler):
261         (ExceptionHandler::~ExceptionHandler):
262         (ExceptionHandler::push):
263         (ExceptionHandler::pop):
264         (jscContextGarbageCollect):
265         (testJSCBasic):
266         (testJSCTypes):
267         (foo):
268         (callback):
269         (doubleAndSetInResult):
270         (sumFunction):
271         (testJSCFunction):
272         (testJSCObject):
273         (fooCreate):
274         (fooCreateWithFoo):
275         (fooFree):
276         (setFoo):
277         (getFoo):
278         (setSibling):
279         (getSibling):
280         (multiplyFoo):
281         (getMultiplyFoo):
282         (getMultiplyFooAsync):
283         (bazCreate):
284         (testJSCClass):
285         (barCreate):
286         (barFree):
287         (setBar):
288         (getBar):
289         (testJSCPrototypes):
290         (createError):
291         (testJSCExceptions):
292         (testJSCPromises):
293         (fooFreeAndLog):
294         (testJSCGarbageCollector):
295         (testsJSCVirtualMachine):
296         (testsJSCAutocleanups):
297         (main):
298         * gtk/generate-gtkdoc:
299         (get_generator_for_config):
300
301 2018-03-20  Tim Horton  <timothy_horton@apple.com>
302
303         Enable the minimal simulator feature flag when appropriate
304         https://bugs.webkit.org/show_bug.cgi?id=183807
305
306         Reviewed by Dan Bernstein.
307
308         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
309
310 2018-03-20  Zalan Bujtas  <zalan@apple.com>
311
312         [LayoutReloaded] Disconnect Display.Box from Layout.Box
313         https://bugs.webkit.org/show_bug.cgi?id=183805
314
315         Reviewed by Antti Koivisto.
316
317         Display.Box is only accessed through the FormattingState.
318
319         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:
320         (BlockFormattingContext):
321         (BlockFormattingContext.prototype.layout):
322         (BlockFormattingContext.prototype._placeInFlowPositionedChildren):
323         (BlockFormattingContext.prototype._layoutOutOfFlowDescendants):
324         (BlockFormattingContext.prototype._adjustBottomWithFIXME):
325         (BlockFormattingContext.prototype._computeOutOfFlowPosition):
326         * LayoutReloaded/FormattingContext/FormattingContext.js:
327         (FormattingContext):
328         (FormattingContext.prototype.formattingRoot):
329         (FormattingContext.prototype.formattingState):
330         (FormattingContext.prototype.layoutState):
331         (FormattingContext.prototype._toAbsolutePosition):
332         (FormattingContext.prototype._toRootAbsolutePosition):
333         (FormattingContext.prototype._addToLayoutQueue):
334         (FormattingContext.prototype.displayBox):
335         (FormattingContext.prototype._outOfFlowDescendants):
336         (FormattingContext.prototype.rootContainer): Deleted.
337         (FormattingContext.prototype.layoutContext): Deleted.
338         * LayoutReloaded/FormattingContext/InlineFormatting/InlineFormattingContext.js:
339         (InlineFormattingContext):
340         (InlineFormattingContext.prototype.layout):
341         (InlineFormattingContext.prototype._initializeLine):
342         * LayoutReloaded/FormattingState/BlockFormattingState.js:
343         (BlockFormattingState):
344         * LayoutReloaded/FormattingState/FormattingState.js:
345         (FormattingState):
346         (FormattingState.prototype.formattingRoot):
347         (FormattingState.prototype.layoutState):
348         (FormattingState.prototype.createDisplayBox):
349         (FormattingState.prototype.displayBoxMap):
350         (FormattingState.prototype.displayBox):
351         (FormattingState.prototype.layoutContext): Deleted.
352         * LayoutReloaded/FormattingState/InlineFormattingState.js:
353         (InlineFormattingState):
354         * LayoutReloaded/Layout.js:
355         (layout):
356         * LayoutReloaded/LayoutReloaded.xcworkspace/contents.xcworkspacedata:
357         * LayoutReloaded/LayoutState.js: Renamed from Tools/LayoutReloaded/LayoutContext.js.
358         (LayoutState):
359         (LayoutState.prototype.layout):
360         (LayoutState.prototype._createFormattingState):
361         (LayoutState.prototype.formattingStates):
362         (LayoutState.prototype.initialDisplayBox):
363         * LayoutReloaded/LayoutTree/Box.js:
364         (Layout.Box.prototype.isOutOfFlowPositioned):
365         (Layout.Box.prototype.containingBlock):
366         (Layout.Box.prototype.setDisplayBox): Deleted.
367         (Layout.Box.prototype.displayBox): Deleted.
368         * LayoutReloaded/Utils.js:
369         (Utils.layoutTreeDump):
370         (Utils._findDisplayBox):
371         (Utils._dumpBox):
372         (Utils._dumpTree):
373         * LayoutReloaded/misc/headers/BlockFormattingContext.h:
374         * LayoutReloaded/misc/headers/FormattingContext.h:
375         * LayoutReloaded/misc/headers/LayoutContext.h:
376         * LayoutReloaded/test/index.html:
377
378 2018-03-19  Ryosuke Niwa  <rniwa@webkit.org>
379
380         Expose content attributes on _WKLinkIconParameters
381         https://bugs.webkit.org/show_bug.cgi?id=183768
382
383         Reviewed by Alex Christensen.
384
385         Expanded the basic test case for _WKLinkIconParameters's properties including newly added "attributes".
386
387         * TestWebKitAPI/Tests/WebKitCocoa/IconLoadingDelegate.mm:
388         (IconLoading.DefaultFavicon):
389
390 2018-03-20  Wenson Hsieh  <wenson_hsieh@apple.com>
391
392         Add AssistedNodeInformation plumbing for form control placeholder text and label text
393         https://bugs.webkit.org/show_bug.cgi?id=183802
394         <rdar://problem/38686273>
395
396         Reviewed by Tim Horton.
397
398         Adds a new API test to exercise new placeholder and label SPI on _WKFocusedFormElement.
399
400         * TestWebKitAPI/Tests/WebKitCocoa/_WKInputDelegate.mm:
401         (-[InputDelegate _webView:focusShouldStartInputSession:]):
402         (-[InputDelegate shouldStartInputSessionHandler]):
403         (-[InputDelegate setShouldStartInputSessionHandler:]):
404         (TEST):
405         (-[FormSubmissionDelegate webView:startURLSchemeTask:]): Deleted.
406         (-[FormSubmissionDelegate webView:stopURLSchemeTask:]): Deleted.
407         (-[FormSubmissionDelegate _webView:willSubmitFormValues:userObject:submissionHandler:]): Deleted.
408
409 2018-03-20  Basuke Suzuki  <Basuke.Suzuki@sony.com>
410
411         [WinCairo] Fix to run-webkit-httpd from native Windows.
412         https://bugs.webkit.org/show_bug.cgi?id=183605
413
414         Reviewed by Daniel Bates.
415
416         This fix is to run Apache HTTP server from native Windows. The environment is different
417         from cygwin, which is used for AppleWin, in following points:
418         - A temporary file behaves differently. It cannot reopen by anybody when indicated as 
419           delete on close. To solve this situation, filesystem.mkdtemp() is used instead.
420         - It's not unix so that `tail` command is not available. Replaced with python equivalent
421           function.
422
423         * Scripts/webkitpy/common/system/filesystem.py:
424         (FileSystem.mkdtemp.TemporaryDirectory.__init__):
425         (FileSystem.mkdtemp.TemporaryDirectory.__exit__): The existing contents would be deleted.
426         (FileSystem.mkdtemp):
427         * Scripts/webkitpy/layout_tests/servers/run_webkit_httpd.py:
428         (parse_args):
429         (run_server):
430         (run_server_with_log_file):
431         (follow_file):
432
433 2018-03-20  Brady Eidson  <beidson@apple.com>
434
435         First piece of process swapping on navigation.
436         https://bugs.webkit.org/show_bug.cgi?id=183665
437
438         Reviewed by Andy Estes.
439
440         Expose the "swaps processes on navigation" setting in MiniBrowser UI for testing:
441
442         * MiniBrowser/mac/AppDelegate.m:
443         (defaultConfiguration):
444         * MiniBrowser/mac/SettingsController.h:
445         * MiniBrowser/mac/SettingsController.m:
446         (-[SettingsController _populateMenu]):
447         (-[SettingsController validateMenuItem:]):
448         (-[SettingsController processSwapOnNavigationEnabled]):
449         (-[SettingsController toggleProcessSwapOnNavigation:]):
450
451         Makes sure the current behavior is tested:
452         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
453         * TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm: Added.
454         (-[PSONNavigationDelegate webView:didFinishNavigation:]):
455         (-[PSONScheme webView:startURLSchemeTask:]):
456         (-[PSONScheme webView:stopURLSchemeTask:]):
457         (TEST):
458
459 2018-03-20  Chris Dumez  <cdumez@apple.com>
460
461         QuickLook.NavigationDelegate API test is failing on iOS with async policy delegates
462         https://bugs.webkit.org/show_bug.cgi?id=183791
463
464         Reviewed by Alex Christensen.
465
466         Add API test coverage.
467
468         * TestWebKitAPI/Tests/WebKitCocoa/QuickLook.mm:
469         (-[QuickLookAsyncNavigationDelegate webView:decidePolicyForNavigationResponse:decisionHandler:]):
470         (-[QuickLookAsyncNavigationDelegate _webView:didStartLoadForQuickLookDocumentInMainFrameWithFileName:uti:]):
471         (-[QuickLookAsyncNavigationDelegate _webView:didFinishLoadForQuickLookDocumentInMainFrame:]):
472         (-[QuickLookAsyncNavigationDelegate webView:didFinishNavigation:]):
473         (TEST):
474
475 2018-03-20  Tim Horton  <timothy_horton@apple.com>
476
477         Add and adopt WK_PLATFORM_NAME and adjust default feature defines
478         https://bugs.webkit.org/show_bug.cgi?id=183758
479         <rdar://problem/38017644>
480
481         Reviewed by Dan Bernstein.
482
483         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
484
485 2018-03-20  Chris Dumez  <cdumez@apple.com>
486
487         Unreviewed, rolling out r229726 and r229763.
488
489         Caused some API test failures on iOS
490
491         Reverted changesets:
492
493         "Make policy decisions asynchronous"
494         https://bugs.webkit.org/show_bug.cgi?id=180568
495         https://trac.webkit.org/changeset/229726
496
497         "Rebaseline three webarchive tests for WK2 after r229726."
498         https://bugs.webkit.org/show_bug.cgi?id=180568
499         https://trac.webkit.org/changeset/229763
500
501 2018-03-20  Zalan Bujtas  <zalan@apple.com>
502
503         [LayoutReloaded] Move Display.Box handling from FormattingContext to FormattingState
504         https://bugs.webkit.org/show_bug.cgi?id=183779
505
506         Reviewed by Antti Koivisto.
507
508         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:
509         (BlockFormattingContext.prototype._computeStaticPosition):
510         (BlockFormattingContext.prototype._computeOutOfFlowWidth):
511         (BlockFormattingContext.prototype._computeFloatingWidth):
512         (BlockFormattingContext.prototype._computeInFlowWidth):
513         (BlockFormattingContext.prototype._computeOutOfFlowHeight):
514         (BlockFormattingContext.prototype._computeFloatingHeight):
515         (BlockFormattingContext.prototype._computeInFlowHeight):
516         (BlockFormattingContext.prototype._horizontalConstraint):
517         (BlockFormattingContext.prototype._contentHeight):
518         (BlockFormattingContext.prototype._adjustBottomWithFIXME):
519         (BlockFormattingContext.prototype._computeInFlowPositionedPosition):
520         (BlockFormattingContext.prototype._computeOutOfFlowPosition):
521         * LayoutReloaded/FormattingContext/FloatingContext.js:
522         (FloatingContext.prototype.computePosition):
523         (FloatingContext.prototype._positionForClear):
524         (FloatingContext.prototype._computePositionToAvoidIntrudingFloats):
525         (FloatingContext.prototype._availableSpace):
526         (FloatingContext.prototype._adjustedFloatingPosition):
527         * LayoutReloaded/FormattingContext/FormattingContext.js:
528         (FormattingContext):
529         (FormattingContext.prototype.absoluteMarginBox):
530         (FormattingContext.prototype.absoluteBorderBox):
531         (FormattingContext.prototype.absolutePaddingBox):
532         (FormattingContext.prototype.absoluteContentBox):
533         (FormattingContext.prototype._toAbsolutePosition):
534         (FormattingContext.prototype._toRootAbsolutePosition):
535         (FormattingContext.prototype._addToLayoutQueue):
536         (FormattingContext.prototype.displayBox):
537         (FormattingContext.prototype._createDisplayBox): Deleted.
538         (FormattingContext.prototype.toDisplayBox): Deleted.
539         (FormattingContext.prototype.toLayoutBox): Deleted.
540         * LayoutReloaded/FormattingState/FormattingState.js:
541         (FormattingState):
542         (FormattingState.prototype.createDisplayBox):
543         (FormattingState.prototype.displayBox):
544
545 2018-03-20  Zalan Bujtas  <zalan@apple.com>
546
547         [LayoutReloaded] Introduce FormattingState (Block/Inline/etc)
548         https://bugs.webkit.org/show_bug.cgi?id=183777
549
550         Reviewed by Antti Koivisto.
551
552         This is in preparation for moving out states from the formatting contexts.
553
554         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:
555         (BlockFormattingContext):
556         * LayoutReloaded/FormattingContext/FormattingContext.js:
557         (FormattingContext):
558         (FormattingContext.prototype.layoutState):
559         (FormattingContext.prototype.layoutContext):
560         (FormattingContext.prototype.layout):
561         * LayoutReloaded/FormattingContext/InlineFormatting/InlineFormattingContext.js:
562         (InlineFormattingContext):
563         * LayoutReloaded/FormattingState/BlockFormattingState.js: Copied from Tools/LayoutReloaded/LayoutContext.js.
564         (BlockFormattingState):
565         * LayoutReloaded/FormattingState/FormattingState.js: Copied from Tools/LayoutReloaded/LayoutContext.js.
566         (FormattingState):
567         (FormattingState.prototype.formattingContext):
568         (FormattingState.prototype.layoutContext):
569         (FormattingState.prototype._setFormattingContext):
570         * LayoutReloaded/FormattingState/InlineFormattingState.js: Copied from Tools/LayoutReloaded/LayoutContext.js.
571         (InlineFormattingState):
572         * LayoutReloaded/LayoutContext.js:
573         (LayoutContext):
574         (LayoutContext.prototype.layout):
575         (LayoutContext.prototype._createFormattingState):
576         (LayoutContext.prototype._createFormattingContext): Deleted.
577         * LayoutReloaded/LayoutReloaded.xcworkspace/contents.xcworkspacedata:
578         * LayoutReloaded/test/index.html:
579
580 2018-03-19  Zalan Bujtas  <zalan@apple.com>
581
582         [LayoutReloaded] Layout.Box should not create the formatting context.
583         https://bugs.webkit.org/show_bug.cgi?id=183766
584
585         Reviewed by Antti Koivisto.
586
587         Since the formattingContext's lifetime is tied to the layout, the LayoutContext
588         should construct it instead.
589
590         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:
591         (BlockFormattingContext):
592         (BlockFormattingContext.prototype.layout):
593         (BlockFormattingContext.prototype._layoutOutOfFlowDescendants):
594         (BlockFormattingContext.prototype._contentHeight):
595         * LayoutReloaded/FormattingContext/FormattingContext.js:
596         (FormattingContext):
597         (FormattingContext.prototype.layoutContext):
598         (FormattingContext.prototype.toDisplayBox):
599         (FormattingContext.prototype._outOfFlowDescendants):
600         * LayoutReloaded/FormattingContext/InlineFormatting/InlineFormattingContext.js:
601         (InlineFormattingContext):
602         (InlineFormattingContext.prototype.layout):
603         * LayoutReloaded/Layout.js:
604         (layout):
605         * LayoutReloaded/LayoutContext.js:
606         (LayoutContext.prototype.layout):
607         (LayoutContext.prototype._createFormattingContext):
608         (LayoutContext):
609         (LayoutContext.prototype.layoutFormattingContext): Deleted.
610         * LayoutReloaded/LayoutTree/Box.js:
611         (Layout.Box):
612         (Layout.Box.prototype.establishedFormattingContext): Deleted.
613         * LayoutReloaded/misc/headers/Box.h:
614
615 2018-03-19  Chris Dumez  <cdumez@apple.com>
616
617         Have one service worker process per security origin
618         https://bugs.webkit.org/show_bug.cgi?id=183600
619         <rdar://problem/35280128>
620
621         Reviewed by Brady Eidson.
622
623         Add API test coverage.
624
625         * TestWebKitAPI/Tests/WebKitCocoa/ServiceWorkerBasic.mm:
626
627 2018-03-19  Zalan Bujtas  <zalan@apple.com>
628
629         [LayoutReloaded] Remove border/padding/contentBox() functions from Layout.Box
630         https://bugs.webkit.org/show_bug.cgi?id=183761
631
632         Reviewed by Antti Koivisto.
633
634         Display.Box has them.
635
636         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:
637         (BlockFormattingContext.prototype._computeOutOfFlowWidth):
638         (BlockFormattingContext.prototype._computeOutOfFlowHeight):
639         (BlockFormattingContext.prototype._horizontalConstraint):
640         (BlockFormattingContext.prototype._contentHeight):
641         (BlockFormattingContext.prototype._adjustBottomWithFIXME):
642         (BlockFormattingContext.prototype._computeOutOfFlowPosition):
643         * LayoutReloaded/FormattingContext/FloatingContext.js:
644         (FloatingContext.prototype._availableSpace):
645         * LayoutReloaded/FormattingContext/FormattingContext.js:
646         (FormattingContext.prototype.absoluteBorderBox):
647         (FormattingContext.prototype.absolutePaddingBox):
648         (FormattingContext.prototype.absoluteContentBox):
649         * LayoutReloaded/LayoutTree/Box.js:
650         (Layout.Box.prototype.isDescendantOf):
651         (Layout.Box):
652         (Layout.Box.prototype.borderBox): Deleted.
653         (Layout.Box.prototype.paddingBox): Deleted.
654         (Layout.Box.prototype.contentBox): Deleted.
655
656 2018-03-19  Jiewen Tan  <jiewen_tan@apple.com>
657
658         Unreviewed, another quick fix for r229699
659
660         Restricts ENABLE_WEB_AUTHN to only macOS and iOS.
661
662         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
663         * TestWebKitAPI/Tests/ios/LocalAuthenticator.mm:
664
665 2018-03-19  Zalan Bujtas  <zalan@apple.com>
666
667         [LayoutReloaded] Move statically positioned absolute box positioning to _computeOutOfFlowPosition
668         https://bugs.webkit.org/show_bug.cgi?id=183750
669
670         Reviewed by Antti Koivisto.
671
672         * LayoutReloaded/DisplayTree/Box.js:
673         (Display.Box.prototype.setTop):
674         (Display.Box.prototype.paddingBox):
675         (Display.Box.prototype.contentBox):
676         (Display.Box):
677         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:
678         (BlockFormattingContext.prototype._computeStaticPosition):
679         (BlockFormattingContext.prototype._layoutOutOfFlowDescendants):
680         (BlockFormattingContext.prototype._computeOutOfFlowPosition):
681         * LayoutReloaded/FormattingContext/FormattingContext.js:
682         (FormattingContext.prototype.absoluteMarginBox):
683         (FormattingContext.prototype.absoluteBorderBox):
684         (FormattingContext.prototype.absolutePaddingBox):
685         (FormattingContext.prototype.absoluteContentBox):
686         (FormattingContext.prototype._toAbsolutePosition):
687         (FormattingContext.prototype._toRootAbsolutePosition):
688         (FormattingContext.prototype.toDisplayBox):
689         * LayoutReloaded/LayoutTree/InitialBlockContainer.js:
690         (Layout.InitialBlockContainer.prototype.establishesBlockFormattingContext):
691         (Layout.InitialBlockContainer):
692         (Layout.InitialBlockContainer.prototype.paddingBox): Deleted.
693         (Layout.InitialBlockContainer.prototype.contentBox): Deleted.
694         * LayoutReloaded/Utils.js:
695         (Utils.isStaticallyPositioned):
696
697 2018-03-19  Chris Dumez  <cdumez@apple.com>
698
699         WebKit.WebsitePoliciesAutoplayQuirks API test times out with async policy delegates
700         https://bugs.webkit.org/show_bug.cgi?id=183702
701         <rdar://problem/38566060>
702
703         Reviewed by Alex Christensen.
704
705         Add API test coverage.
706
707         * TestWebKitAPI/Tests/WebKitCocoa/WebsitePolicies.mm:
708         (-[AsyncAutoplayPoliciesDelegate webView:decidePolicyForNavigationAction:decisionHandler:]):
709         (-[AsyncAutoplayPoliciesDelegate _webView:decidePolicyForNavigationAction:decisionHandler:]):
710         (-[AsyncAutoplayPoliciesDelegate _webView:handleAutoplayEvent:withFlags:]):
711         (TEST):
712
713 2018-03-19  Daniel Bates  <dabates@apple.com>
714
715         test-webkitpy no longer runs WebKit2 tests
716         https://bugs.webkit.org/show_bug.cgi?id=183724
717
718         Reviewed by Alexey Proskuryakov.
719
720         The WebKit2 tests have seen been moved from Source/WebKit2/Scripts/webkit2 to Source/WebKit/Scripts/webkit.
721
722         * Scripts/webkitpy/test/main.py:
723         (main):
724
725 2018-03-19  Daniel Bates  <dabates@apple.com>
726
727         Make run-webkit-app work for non-GUI apps
728         https://bugs.webkit.org/show_bug.cgi?id=183701
729
730         Reviewed by Lucas Forschler.
731
732         Launch the app directly if it is an executable file. Otherwise, assume it is an app bundle
733         and launch it using open(1) as we currently do.
734
735         Note that open(1) is meant for launching GUI apps. Standard output and standard error are
736         not sent to the tty when using open(1) to launch a non-GUI app.
737
738         * Scripts/run-webkit-app: We make the assumption that 
739         * Scripts/webkitdirs.pm:
740             - Define and export constant DO_NOT_USE_OPEN_COMMAND.
741
742 2018-03-19  Daniel Bates  <dabates@apple.com>
743
744         run-webkit-app -g does not work
745         https://bugs.webkit.org/show_bug.cgi?id=183699
746
747         Reviewed by Lucas Forschler.
748
749         Check for the optional command line argument -g/--guard-malloc before taking the
750         first argument passed to be the path to the app to run.
751
752         * Scripts/run-webkit-app:
753
754 2018-03-18  Commit Queue  <commit-queue@webkit.org>
755
756         Unreviewed, rolling out r229689.
757         https://bugs.webkit.org/show_bug.cgi?id=183735
758
759         Causes fast/loader/inner-iframe-loads-data-url-into-parent-on-
760         unload-crash.html to fail with async delegates (Requested by
761         cdumez_ on #webkit).
762
763         Reverted changeset:
764
765         "WebKit.WebsitePoliciesAutoplayQuirks API test times out with
766         async policy delegates"
767         https://bugs.webkit.org/show_bug.cgi?id=183702
768         https://trac.webkit.org/changeset/229689
769
770 2018-03-18  Zalan Bujtas  <zalan@apple.com>
771
772         [LayoutReloaded] Remove left/right width/height getters from Layout.Box
773         https://bugs.webkit.org/show_bug.cgi?id=183734
774
775         Reviewed by Antti Koivisto.
776
777         ...and use Display.Box instead.
778
779         * LayoutReloaded/DisplayTree/Box.js:
780         (Display.Box.prototype.bottomRight):
781         (Display.Box.prototype.size):
782         (Display.Box.prototype.height):
783         (Display.Box.prototype.width):
784         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:
785         (BlockFormattingContext.prototype._computeStaticPosition):
786         (BlockFormattingContext.prototype._adjustBottomWithFIXME):
787         (BlockFormattingContext.prototype._computeInFlowPositionedPosition):
788         (BlockFormattingContext.prototype._computeOutOfFlowPosition):
789         * LayoutReloaded/FormattingContext/FloatingContext.js:
790         (FloatingContext.prototype._positionForClear):
791         (FloatingContext.prototype._computePositionToAvoidIntrudingFloats):
792         (FloatingContext.prototype._adjustedFloatingPosition):
793         * LayoutReloaded/FormattingContext/FormattingContext.js:
794         (FormattingContext.prototype.absoluteMarginBox):
795         (FormattingContext.prototype.absoluteBorderBox):
796         (FormattingContext.prototype.absolutePaddingBox):
797         (FormattingContext.prototype.absoluteContentBox):
798         (FormattingContext.prototype._toAbsolutePosition):
799         (FormattingContext.prototype._toRootAbsolutePosition):
800         * LayoutReloaded/LayoutTree/Box.js:
801         (Layout.Box.prototype.rect): Deleted.
802         (Layout.Box.prototype.topLeft): Deleted.
803         (Layout.Box.prototype.bottomRight): Deleted.
804         * LayoutReloaded/Utils.js:
805         (Utils._dumpBox):
806         (Utils.mapToContainer): Deleted.
807
808 2018-03-18  Zalan Bujtas  <zalan@apple.com>
809
810         [LayoutReloaded] Remove left/right width/height setters from Layout.Box
811         https://bugs.webkit.org/show_bug.cgi?id=183731
812
813         Reviewed by Antti Koivisto.
814
815         ...and use Display.Box instead.
816
817         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:
818         (BlockFormattingContext.prototype._computeStaticPosition):
819         (BlockFormattingContext.prototype._computeOutOfFlowWidth):
820         (BlockFormattingContext.prototype._computeFloatingWidth):
821         (BlockFormattingContext.prototype._computeInFlowWidth):
822         (BlockFormattingContext.prototype._computeOutOfFlowHeight):
823         (BlockFormattingContext.prototype._computeFloatingHeight):
824         (BlockFormattingContext.prototype._computeInFlowHeight):
825         (BlockFormattingContext.prototype._computeInFlowPositionedPosition):
826         (BlockFormattingContext.prototype._computeOutOfFlowPosition):
827         * LayoutReloaded/FormattingContext/FloatingContext.js:
828         (FloatingContext.prototype.computePosition):
829         * LayoutReloaded/FormattingContext/FormattingContext.js:
830         (FormattingContext.prototype._toDisplayBox):
831         (FormattingContext.prototype._toLayoutBox):
832         * LayoutReloaded/Layout.js:
833         (layout):
834         * LayoutReloaded/LayoutTree/Box.js:
835         (Layout.Box.prototype.setTopLeft): Deleted.
836         (Layout.Box.prototype.setSize): Deleted.
837         (Layout.Box.prototype.setWidth): Deleted.
838         (Layout.Box.prototype.setHeight): Deleted.
839
840 2018-03-18  Zalan Bujtas  <zalan@apple.com>
841
842         [LayoutReloaded] Collect out-of-flow positioned boxes for a given formatting context.
843         https://bugs.webkit.org/show_bug.cgi?id=183730
844
845         Reviewed by Antti Koivisto.
846
847         Collect and layout out-of-flow positioned boxes as the final step of the formatting context layout.
848
849         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:
850         (BlockFormattingContext.prototype.layout):
851         (BlockFormattingContext.prototype._placeInFlowPositionedChildren):
852         (BlockFormattingContext.prototype._layoutOutOfFlowDescendants):
853         (BlockFormattingContext.prototype._placePositionedDescendants): Deleted.
854         (BlockFormattingContext.prototype._placeOutOfFlowDescendants): Deleted.
855         * LayoutReloaded/FormattingContext/FormattingContext.js:
856         (FormattingContext.prototype._toAbsolutePosition):
857         (FormattingContext.prototype._outOfFlowDescendants):
858         (FormattingContext):
859         * LayoutReloaded/LayoutTree/Box.js:
860         (Layout.Box.prototype.nextInFlowOrFloatSibling):
861         (Layout.Box.prototype.isDescendantOf):
862         * LayoutReloaded/LayoutTree/Container.js:
863         (Layout.Container.prototype.firstInFlowOrFloatChild):
864         (Layout.Container.prototype.hasInFlowOrFloatChild):
865         (Layout.Container.prototype.outOfFlowDescendants):
866         (Layout.Container):
867         * LayoutReloaded/Utils.js:
868         (Utils.isDescendantOf): Deleted.
869         (Utils.collectOutOfFlowDescendants): Deleted.
870
871 2018-03-17  Jiewen Tan  <jiewen_tan@apple.com>
872
873         [WebAuthN] Implement authenticatorMakeCredential
874         https://bugs.webkit.org/show_bug.cgi?id=183527
875         <rdar://problem/35275886>
876
877         Reviewed by Brent Fulgham.
878
879         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
880         * TestWebKitAPI/Tests/ios/LocalAuthenticator.mm: Added.
881         (TestWebKitAPI::getTestKey):
882         (TestWebKitAPI::cleanUpKeychain):
883         (TestWebKitAPI::LACantEvaluatePolicySwizzler::LACantEvaluatePolicySwizzler):
884         (TestWebKitAPI::LACantEvaluatePolicySwizzler::cantEvaluatePolicy):
885         (TestWebKitAPI::LACanEvaluatePolicySwizzler::LACanEvaluatePolicySwizzler):
886         (TestWebKitAPI::LACanEvaluatePolicySwizzler::canEvaluatePolicy):
887         (TestWebKitAPI::LAEvaluatePolicyFailedSwizzler::LAEvaluatePolicyFailedSwizzler):
888         (TestWebKitAPI::LAEvaluatePolicyFailedSwizzler::evaluatePolicyFailed):
889         (TestWebKitAPI::LAEvaluatePolicyPassedSwizzler::LAEvaluatePolicyPassedSwizzler):
890         (TestWebKitAPI::LAEvaluatePolicyPassedSwizzler::evaluatePolicyPassed):
891         (TestWebKitAPI::TestLocalAuthenticator::setFailureFlag):
892         (TestWebKitAPI::TEST):
893
894 2018-03-17  Zalan Bujtas  <zalan@apple.com>
895
896         [LayoutReloaded] BlockFormattingContext::placePositionedDescendants takes care of both in- and out-of-flow placement
897         https://bugs.webkit.org/show_bug.cgi?id=183727
898
899         Reviewed by Antti Koivisto.
900
901         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:
902         (BlockFormattingContext.prototype.layout):
903         (BlockFormattingContext.prototype._placePositionedDescendants):
904         (BlockFormattingContext.prototype._placeInFlowPositionedChildren):
905         (BlockFormattingContext.prototype._placeOutOfFlowDescendants):
906         * LayoutReloaded/test/absolute-position-when-containing-block-is-not-in-the-formatting-context.html: Added.
907         * LayoutReloaded/test/absolute-position-when-containing-block-is-not-in-the-formatting-context2.html: Added.
908         * LayoutReloaded/test/index.html:
909         * LayoutReloaded/test/relative-position-when-containing-block-is-not-in-the-formatting-context.html: Added.
910
911 2018-03-17  Zalan Bujtas  <zalan@apple.com>
912
913         [LayoutReloaded] Ensure that positioning happens within the formatting context
914         https://bugs.webkit.org/show_bug.cgi?id=183722
915
916         Reviewed by Antti Koivisto.
917
918         All sizing and positioning need to happen in the formatting context that the box lives in
919         including the final position of in- and out-of-flow descendants.
920
921         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:
922         (BlockFormattingContext.prototype.layout):
923         (BlockFormattingContext.prototype._placeInFlowPositionedChildren):
924         * LayoutReloaded/LayoutTree/Box.js:
925         (Layout.Box.prototype.establishesBlockFormattingContext):
926         (Layout.Box.prototype.isPositioned):
927         (Layout.Box.prototype.isRelativelyPositioned):
928         (Layout.Box.prototype.isAbsolutelyPositioned):
929         (Layout.Box.prototype.isOutOfFlowPositioned):
930         (Layout.Box.prototype.containingBlock):
931         (Layout.Box.prototype.isRelativePositioned): Deleted.
932         (Layout.Box.prototype.isAbsolutePositioned): Deleted.
933         * LayoutReloaded/Utils.js:
934         (Utils.isRelativelyPositioned):
935         (Utils.isAbsolutelyPositioned):
936         (Utils.isRelativePositioned): Deleted.
937         (Utils.isAbsolutePositioned): Deleted.
938         * LayoutReloaded/misc/headers/Box.h:
939
940 2018-03-16  Wenson Hsieh  <wenson_hsieh@apple.com>
941
942         Unreviewed, rolling out r229688.
943
944         There's a solution that doesn't require this SPI.
945
946         Reverted changeset:
947
948         "Add SPI to expose width and height anchors for WKWebView's
949         content view"
950         https://bugs.webkit.org/show_bug.cgi?id=183711
951         https://trac.webkit.org/changeset/229688
952
953 2018-03-16  Zalan Bujtas  <zalan@apple.com>
954
955         [LayoutReloaded] Move move functions to the base class from BlockFormattingContext
956         https://bugs.webkit.org/show_bug.cgi?id=183719
957
958         Reviewed by Antti Koivisto.
959
960         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:
961         (BlockFormattingContext):
962         (BlockFormattingContext.prototype.layout):
963         (BlockFormattingContext.prototype._shrinkToFitWidth):
964         (BlockFormattingContext.prototype._toAbsolutePosition): Deleted.
965         (BlockFormattingContext.prototype._needsLayout): Deleted.
966         (BlockFormattingContext.prototype._addToLayoutQueue): Deleted.
967         (BlockFormattingContext.prototype._nextInLayoutQueue): Deleted.
968         (BlockFormattingContext.prototype._removeFromLayoutQueue): Deleted.
969         (BlockFormattingContext.prototype._createDisplayBox): Deleted.
970         (BlockFormattingContext.prototype._toDisplayBox): Deleted.
971         (BlockFormattingContext.prototype._toLayoutBox): Deleted.
972         * LayoutReloaded/FormattingContext/FormattingContext.js:
973         (FormattingContext):
974         (FormattingContext.prototype._toAbsolutePosition):
975         (FormattingContext.prototype._descendantNeedsLayout):
976         (FormattingContext.prototype._addToLayoutQueue):
977         (FormattingContext.prototype._nextInLayoutQueue):
978         (FormattingContext.prototype._removeFromLayoutQueue):
979         (FormattingContext.prototype._createDisplayBox):
980         (FormattingContext.prototype._toDisplayBox):
981         (FormattingContext.prototype._toLayoutBox):
982         * LayoutReloaded/FormattingContext/InlineFormatting/InlineFormattingContext.js:
983         (InlineFormattingContext.prototype.layout):
984
985 2018-03-16  Chris Dumez  <cdumez@apple.com>
986
987         WebKit.WebsitePoliciesAutoplayQuirks API test times out with async policy delegates
988         https://bugs.webkit.org/show_bug.cgi?id=183702
989
990         Reviewed by Alex Christensen.
991
992         Add API test coverage.
993
994         * TestWebKitAPI/Tests/WebKitCocoa/WebsitePolicies.mm:
995         (-[AsyncAutoplayPoliciesDelegate webView:decidePolicyForNavigationAction:decisionHandler:]):
996         (-[AsyncAutoplayPoliciesDelegate _webView:decidePolicyForNavigationAction:decisionHandler:]):
997         (-[AsyncAutoplayPoliciesDelegate _webView:handleAutoplayEvent:withFlags:]):
998         (TEST):
999
1000 2018-03-16  Wenson Hsieh  <wenson_hsieh@apple.com>
1001
1002         Add SPI to expose width and height anchors for WKWebView's content view
1003         https://bugs.webkit.org/show_bug.cgi?id=183711
1004         <rdar://problem/38562899>
1005
1006         Reviewed by Tim Horton.
1007
1008         Adds an API test exercising the new SPI.
1009
1010         * TestWebKitAPI/Tests/WebKitCocoa/AutoLayoutIntegration.mm:
1011         (checkCGRect):
1012         (TEST):
1013
1014 2018-03-16  Chris Dumez  <cdumez@apple.com>
1015
1016         WebKit.RestoreSessionStateContainingScrollRestorationDefault API test is failing with async policy delegates
1017         https://bugs.webkit.org/show_bug.cgi?id=183679
1018
1019         Reviewed by Alex Christensen.
1020
1021         Add API test coverage.
1022
1023         * TestWebKitAPI/Tests/WebKit/RestoreSessionState.cpp:
1024         (TestWebKitAPI::decidePolicyForNavigationAction):
1025         (TestWebKitAPI::decidePolicyForResponse):
1026         (TestWebKitAPI::TEST):
1027
1028 2018-03-16  Zalan Bujtas  <zalan@apple.com>
1029
1030         [LayoutReloaded] Introduce Display.Box
1031         https://bugs.webkit.org/show_bug.cgi?id=183700
1032
1033         Reviewed by Antti Koivisto.
1034
1035         Display.Box objects will end up in the display(box) tree. Currently
1036         they are just hanging off of the Layout.Box objects.
1037
1038         * LayoutReloaded/DisplayTree/Box.js: Added.
1039         (Display.Box):
1040         (Display.Box.prototype.rect):
1041         (Display.Box.prototype.top):
1042         (Display.Box.prototype.left):
1043         (Display.Box.prototype.bottom):
1044         (Display.Box.prototype.right):
1045         (Display.Box.prototype.topLeft):
1046         (Display.Box.prototype.bottomRight):
1047         (Display.Box.prototype.setTopLeft):
1048         (Display.Box.prototype.setSize):
1049         (Display.Box.prototype.setWidth):
1050         (Display.Box.prototype.setHeight):
1051         (Display.Box.prototype.borderBox):
1052         (Display.Box.prototype.paddingBox):
1053         (Display.Box.prototype.contentBox):
1054         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:
1055         (BlockFormattingContext):
1056         (BlockFormattingContext.prototype.layout):
1057         (BlockFormattingContext.prototype._toAbsolutePosition):
1058         (BlockFormattingContext.prototype._needsLayout):
1059         (BlockFormattingContext.prototype._addToLayoutQueue):
1060         (BlockFormattingContext.prototype._nextInLayoutQueue):
1061         (BlockFormattingContext.prototype._removeFromLayoutQueue):
1062         (BlockFormattingContext.prototype._createDisplayBox):
1063         (BlockFormattingContext.prototype._toDisplayBox):
1064         (BlockFormattingContext.prototype._toLayoutBox):
1065         * LayoutReloaded/Layout.js:
1066         (layout):
1067         * LayoutReloaded/LayoutReloaded.xcworkspace/contents.xcworkspacedata:
1068         * LayoutReloaded/LayoutTree/Box.js:
1069         (Layout.Box):
1070         (Layout.Box.prototype.setDisplayBox):
1071         (Layout.Box.prototype.displayBox):
1072         (Layout.Box.prototype.rect):
1073         (Layout.Box.prototype.setTopLeft):
1074         (Layout.Box.prototype.setSize):
1075         (Layout.Box.prototype.setWidth):
1076         (Layout.Box.prototype.setHeight):
1077         (Layout.Box.prototype.borderBox):
1078         (Layout.Box.prototype.paddingBox):
1079         (Layout.Box.prototype.contentBox):
1080         * LayoutReloaded/test/index.html:
1081
1082 2018-03-16  Chris Dumez  <cdumez@apple.com>
1083
1084         URLSchemeHandler.Basic API test fails with async policy delegates
1085         https://bugs.webkit.org/show_bug.cgi?id=183678
1086
1087         Reviewed by Alex Christensen.
1088
1089         Add API test coverage.
1090
1091         * TestWebKitAPI/Tests/WebKitCocoa/WKURLSchemeHandler-1.mm:
1092         (-[URLSchemeHandlerAsyncNavigationDelegate webView:decidePolicyForNavigationAction:decisionHandler:]):
1093         (-[URLSchemeHandlerAsyncNavigationDelegate webView:decidePolicyForNavigationResponse:decisionHandler:]):
1094         (TEST):
1095
1096 2018-03-16  Zalan Bujtas  <zalan@apple.com>
1097
1098         [LayoutReloaded] Utils.computed* functions should just take node instead of box.
1099         https://bugs.webkit.org/show_bug.cgi?id=183697
1100
1101         Reviewed by Antti Koivisto.
1102
1103         This is in preparation for introducing the display tree.
1104
1105         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:
1106         (BlockFormattingContext.prototype._computeOutOfFlowWidth):
1107         (BlockFormattingContext.prototype._computeFloatingWidth):
1108         (BlockFormattingContext.prototype._computeInFlowWidth):
1109         (BlockFormattingContext.prototype._computeOutOfFlowHeight):
1110         (BlockFormattingContext.prototype._computeFloatingHeight):
1111         (BlockFormattingContext.prototype._computeInFlowHeight):
1112         (BlockFormattingContext.prototype._shrinkToFitWidth):
1113         * LayoutReloaded/FormattingContext/BlockFormatting/BlockMarginCollapse.js:
1114         (BlockMarginCollapse._nonCollapsedMarginTop):
1115         (BlockMarginCollapse._nonCollapsedMarginBottom):
1116         (BlockMarginCollapse._collapsedMarginTopFromFirstChild):
1117         (BlockMarginCollapse._collapsedMarginBottomFromLastChild):
1118         * LayoutReloaded/FormattingContext/FormattingContext.js:
1119         (FormattingContext.prototype.marginTop):
1120         (FormattingContext.prototype.marginLeft):
1121         (FormattingContext.prototype.marginBottom):
1122         (FormattingContext.prototype.marginRight):
1123         * LayoutReloaded/LayoutTree/Box.js:
1124         (Layout.Box.prototype.paddingBox):
1125         (Layout.Box.prototype.contentBox):
1126         (Layout.Box):
1127         * LayoutReloaded/Utils.js:
1128         (Utils.computedMarginTop):
1129         (Utils.computedMarginLeft):
1130         (Utils.computedMarginBottom):
1131         (Utils.computedMarginRight):
1132         (Utils.computedBorderTopLeft):
1133         (Utils.computedBorderBottomRight):
1134         (Utils.computedPaddingTopLeft):
1135         (Utils.computedPaddingBottomRight):
1136         (Utils.computedBorderAndPaddingTop):
1137         (Utils.computedBorderAndPaddingLeft):
1138         (Utils.computedBorderAndPaddingBottom):
1139         (Utils.computedBorderAndPaddingRight):
1140         (Utils.computedHorizontalBorderAndPadding):
1141         (Utils.computedVerticalBorderAndPadding):
1142         (Utils.computedLineHeight):
1143         (Utils.hasClearLeft):
1144         (Utils.hasClearRight):
1145         (Utils.hasClearBoth):
1146
1147 2018-03-15  Zalan Bujtas  <zalan@apple.com>
1148
1149         [LayoutReloaded] Should never need to go beyond the root container when asking for the containing block.
1150         https://bugs.webkit.org/show_bug.cgi?id=183691
1151
1152         Reviewed by Antti Koivisto.
1153
1154         While laying out the boxes in a block formatting context, if we happen to need
1155         to get to the containing block of a box to compute geometry, it should always be a
1156         descendant of the root container (or the root container itself).
1157         Nothing outside of the formatting context should be able to impact the boxes inside.
1158
1159         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:
1160         (BlockFormattingContext.prototype._computeOutOfFlowPosition):
1161         (BlockFormattingContext.prototype._toAbsolutePosition):
1162         (BlockFormattingContext):
1163         * LayoutReloaded/FormattingContext/BlockFormatting/BlockMarginCollapse.js:
1164         (BlockMarginCollapse._isMarginTopCollapsedWithParent):
1165         (BlockMarginCollapse._isMarginBottomCollapsedWithParent):
1166         * LayoutReloaded/LayoutTree/Box.js:
1167         (Layout.Box.prototype.isRootBox):
1168         (Layout.Box.prototype.isRootElement): Deleted.
1169         * LayoutReloaded/Utils.js:
1170         (Utils.isDescendantOf):
1171         (Utils.mapStaticToAbsolute): Deleted.
1172         * LayoutReloaded/misc/headers/Box.h:
1173
1174 2018-03-15  Wenson Hsieh  <wenson_hsieh@apple.com>
1175
1176         [iOS WK2] Hit-testing fails when specifying a large top content inset
1177         https://bugs.webkit.org/show_bug.cgi?id=183648
1178         <rdar://problem/38421894>
1179
1180         Reviewed by Tim Horton.
1181
1182         Adds four new API tests to verify that adding top or bottom content insets to the WKWebView's scroll view does
1183         not cause the DOMWindow's innerHeight to shrink. Currently, doing so would cause the innerHeight to be reported
1184         as (viewHeight - inset.top) or (viewHeight - inset.bottom).
1185
1186         See WebKit ChangeLog for more details.
1187
1188         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
1189         * TestWebKitAPI/Tests/ios/ScrollViewInsetTests.mm: Added.
1190         (TestWebKitAPI::TEST):
1191
1192 2018-03-15  Aakash Jain  <aakash_jain@apple.com>
1193
1194         Add unit-test for NetworkTransaction URLError handling
1195         https://bugs.webkit.org/show_bug.cgi?id=183664
1196
1197         Reviewed by Alexey Proskuryakov.
1198
1199         * Scripts/webkitpy/common/net/networktransaction_unittest.py:
1200         (NetworkTransactionTest._raise_URLError): Method to raise URLError.
1201         (NetworkTransactionTest.test_retry_on_HTTPError): Renamed from test_retry.
1202         (NetworkTransactionTest.test_retry_on_URLError): unit-test for testing URLError handling.
1203
1204 2018-03-15  Aakash Jain  <aakash_jain@apple.com>
1205
1206         EWS should print the URL in logs on URLError
1207         https://bugs.webkit.org/show_bug.cgi?id=183651
1208
1209         Reviewed by Alexey Proskuryakov.
1210
1211         * Scripts/webkitpy/common/net/bugzilla/bugzilla.py:
1212         (Bugzilla.open_url): Pass the url.
1213         * Scripts/webkitpy/common/net/networktransaction.py:
1214         (NetworkTransaction.run): Accept optional url parameter and print it on URLError.
1215
1216 2018-03-15  Zalan Bujtas  <zalan@apple.com>
1217
1218         [LayoutReloaded] Introduce Layout namespace
1219         https://bugs.webkit.org/show_bug.cgi?id=183659
1220
1221         Reviewed by Antti Koivisto.
1222
1223         This is in preparation for introducing the display tree.
1224         Box -> Layout.Box
1225
1226         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:
1227         (BlockFormattingContext.prototype.layout):
1228         (BlockFormattingContext.prototype.computeWidth):
1229         (BlockFormattingContext.prototype.computeHeight):
1230         (BlockFormattingContext.prototype.marginTop):
1231         (BlockFormattingContext.prototype.marginBottom):
1232         (BlockFormattingContext.prototype._computeStaticPosition):
1233         (BlockFormattingContext.prototype._placeInFlowPositionedChildren):
1234         (BlockFormattingContext.prototype._placeOutOfFlowDescendants):
1235         (BlockFormattingContext.prototype._computeOutOfFlowWidth):
1236         (BlockFormattingContext.prototype._computeFloatingWidth):
1237         (BlockFormattingContext.prototype._computeInFlowWidth):
1238         (BlockFormattingContext.prototype._computeOutOfFlowHeight):
1239         (BlockFormattingContext.prototype._computeFloatingHeight):
1240         (BlockFormattingContext.prototype._computeInFlowHeight):
1241         (BlockFormattingContext.prototype._horizontalConstraint):
1242         (BlockFormattingContext.prototype._contentHeight):
1243         (BlockFormattingContext.prototype._adjustBottomWithFIXME):
1244         (BlockFormattingContext.prototype._computeInFlowPositionedPosition):
1245         (BlockFormattingContext.prototype._computeOutOfFlowPosition):
1246         (BlockFormattingContext.prototype._shrinkToFitWidth):
1247         (BlockFormattingContext):
1248         (BlockFormattingContext.prototype._computeHorizontalConstraint): Deleted.
1249         (BlockFormattingContext.prototype._computeContentHeight): Deleted.
1250         * LayoutReloaded/FormattingContext/BlockFormatting/BlockMarginCollapse.js:
1251         (BlockMarginCollapse.marginTop):
1252         (BlockMarginCollapse.marginBottom):
1253         (BlockMarginCollapse._isMarginTopCollapsedWithSibling):
1254         (BlockMarginCollapse._isMarginBottomCollapsedWithSibling):
1255         (BlockMarginCollapse._isMarginTopCollapsedWithParent):
1256         (BlockMarginCollapse._isMarginBottomCollapsedWithParent):
1257         (BlockMarginCollapse._nonCollapsedMarginTop):
1258         (BlockMarginCollapse._nonCollapsedMarginBottom):
1259         (BlockMarginCollapse._collapsedMarginTopFromFirstChild):
1260         (BlockMarginCollapse._collapsedMarginBottomFromLastChild):
1261         (BlockMarginCollapse._hasAdjoiningMarginTopAndBottom):
1262         (BlockMarginCollapse):
1263         * LayoutReloaded/FormattingContext/FloatingContext.js:
1264         (FloatingContext.prototype.computePosition):
1265         (FloatingContext.prototype._positionForClear):
1266         (FloatingContext.prototype._computePositionToAvoidIntrudingFloats):
1267         * LayoutReloaded/FormattingContext/FormattingContext.js:
1268         (FormattingContext.prototype.computeWidth):
1269         (FormattingContext.prototype.computeHeight):
1270         (FormattingContext.prototype.marginTop):
1271         (FormattingContext.prototype.marginLeft):
1272         (FormattingContext.prototype.marginBottom):
1273         (FormattingContext.prototype.marginRight):
1274         (FormattingContext.prototype.absoluteMarginBox):
1275         (FormattingContext.prototype.absoluteBorderBox):
1276         (FormattingContext.prototype.absolutePaddingBox):
1277         (FormattingContext.prototype.absoluteContentBox):
1278         (FormattingContext):
1279         * LayoutReloaded/FormattingContext/InlineFormatting/InlineFormattingContext.js:
1280         (InlineFormattingContext.prototype.layout):
1281         * LayoutReloaded/LayoutTree/BlockContainer.js:
1282         (BlockContainer): Deleted.
1283         (BlockContainer.prototype.establishesInlineFormattingContext): Deleted.
1284         * LayoutReloaded/LayoutTree/Box.js:
1285         (Box): Deleted.
1286         (Box.prototype.id): Deleted.
1287         (Box.prototype.setRendererName): Deleted.
1288         (Box.prototype.name): Deleted.
1289         (Box.prototype.node): Deleted.
1290         (Box.prototype.parent): Deleted.
1291         (Box.prototype.nextSibling): Deleted.
1292         (Box.prototype.nextInFlowSibling): Deleted.
1293         (Box.prototype.previousSibling): Deleted.
1294         (Box.prototype.previousInFlowSibling): Deleted.
1295         (Box.prototype.setParent): Deleted.
1296         (Box.prototype.setNextSibling): Deleted.
1297         (Box.prototype.setPreviousSibling): Deleted.
1298         (Box.prototype.rect): Deleted.
1299         (Box.prototype.topLeft): Deleted.
1300         (Box.prototype.bottomRight): Deleted.
1301         (Box.prototype.setTopLeft): Deleted.
1302         (Box.prototype.setSize): Deleted.
1303         (Box.prototype.setWidth): Deleted.
1304         (Box.prototype.setHeight): Deleted.
1305         (Box.prototype.isContainer): Deleted.
1306         (Box.prototype.isBlockLevelBox): Deleted.
1307         (Box.prototype.isBlockContainerBox): Deleted.
1308         (Box.prototype.isInlineLevelBox): Deleted.
1309         (Box.prototype.setIsAnonymous): Deleted.
1310         (Box.prototype.isAnonymous): Deleted.
1311         (Box.prototype.establishesFormattingContext): Deleted.
1312         (Box.prototype.establishedFormattingContext): Deleted.
1313         (Box.prototype.establishesBlockFormattingContext): Deleted.
1314         (Box.prototype.establishesInlineFormattingContext): Deleted.
1315         (Box.prototype.isPositioned): Deleted.
1316         (Box.prototype.isRelativePositioned): Deleted.
1317         (Box.prototype.isAbsolutePositioned): Deleted.
1318         (Box.prototype.isFixedPositioned): Deleted.
1319         (Box.prototype.isInFlow): Deleted.
1320         (Box.prototype.isOutOfFlowPositioned): Deleted.
1321         (Box.prototype.isInFlowPositioned): Deleted.
1322         (Box.prototype.isFloatingPositioned): Deleted.
1323         (Box.prototype.isFloatingOrOutOfFlowPositioned): Deleted.
1324         (Box.prototype.isRootElement): Deleted.
1325         (Box.prototype.containingBlock): Deleted.
1326         (Box.prototype.borderBox): Deleted.
1327         (Box.prototype.paddingBox): Deleted.
1328         (Box.prototype.contentBox): Deleted.
1329         * LayoutReloaded/LayoutTree/Container.js:
1330         (Container): Deleted.
1331         (Container.prototype.isContainer): Deleted.
1332         (Container.prototype.setFirstChild): Deleted.
1333         (Container.prototype.setLastChild): Deleted.
1334         (Container.prototype.firstChild): Deleted.
1335         (Container.prototype.firstInFlowChild): Deleted.
1336         (Container.prototype.lastChild): Deleted.
1337         (Container.prototype.lastInFlowChild): Deleted.
1338         (Container.prototype.hasChild): Deleted.
1339         (Container.prototype.hasInFlowChild): Deleted.
1340         * LayoutReloaded/LayoutTree/InitialBlockContainer.js:
1341         (InitialBlockContainer): Deleted.
1342         (InitialBlockContainer.prototype.establishesBlockFormattingContext): Deleted.
1343         (InitialBlockContainer.prototype.paddingBox): Deleted.
1344         (InitialBlockContainer.prototype.contentBox): Deleted.
1345         * LayoutReloaded/LayoutTree/InlineBox.js:
1346         (InlineBox): Deleted.
1347         (InlineBox.prototype.setText): Deleted.
1348         (InlineBox.prototype.text): Deleted.
1349         * LayoutReloaded/TreeBuilder.js:
1350         (TreeBuilder.prototype.createTree):
1351         (TreeBuilder.prototype._createAndAttachBox):
1352         * LayoutReloaded/Utils.js:
1353         (Utils._dumpBox):
1354
1355 2018-03-14  Chris Fleizach  <cfleizach@apple.com>
1356
1357         AX: Implement accessible dismiss action on iOS
1358         https://bugs.webkit.org/show_bug.cgi?id=183352
1359         <rdar://problem/38161500>
1360
1361         Reviewed by Zalan Bujtas.
1362
1363         * WebKitTestRunner/InjectedBundle/AccessibilityUIElement.cpp:
1364         (WTR::AccessibilityUIElement::dismiss const):
1365         * WebKitTestRunner/InjectedBundle/AccessibilityUIElement.h:
1366         * WebKitTestRunner/InjectedBundle/Bindings/AccessibilityUIElement.idl:
1367         * WebKitTestRunner/InjectedBundle/ios/AccessibilityUIElementIOS.mm:
1368         (WTR::AccessibilityUIElement::dismiss):
1369
1370 2018-03-14  Youenn Fablet  <youenn@apple.com>
1371
1372         Update libwebrtc up to 36af4e9614f707f733eb2340fae66d6325aaac5b
1373         https://bugs.webkit.org/show_bug.cgi?id=183481
1374
1375         Reviewed by Eric Carlson.
1376
1377         * Scripts/webkitpy/style/checker.py: Do not check style.
1378
1379 2018-03-14  Brendan McLoughlin  <brendan@bocoup.com>
1380
1381         Add label on github when exporting wpt tests to w3c/web-platform-test repo
1382         https://bugs.webkit.org/show_bug.cgi?id=183575
1383
1384         Reviewed by Youenn Fablet.
1385
1386         * Scripts/webkitpy/w3c/test_exporter.py:
1387         (TestExporter.make_pull_request):
1388         (parse_args):
1389         * Scripts/webkitpy/w3c/test_exporter_unittest.py:
1390         (TestExporterTest.test_export):
1391
1392 2018-03-14  Zalan Bujtas  <zalan@apple.com>
1393
1394         [LayoutReloaded] Add InlineBox dump
1395         https://bugs.webkit.org/show_bug.cgi?id=183625
1396
1397         Reviewed by Antti Koivisto.
1398
1399         Right now line boxes live off of the inline formatting context but that's temporary and
1400         they will be moved over to the BoxTree.
1401
1402         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:
1403         (BlockFormattingContext.prototype._computeContentHeight):
1404         * LayoutReloaded/FormattingContext/InlineFormatting/InlineFormattingContext.js:
1405         (InlineFormattingContext):
1406         (InlineFormattingContext.prototype.lines):
1407         (InlineFormattingContext.prototype.layout):
1408         (InlineFormattingContext.prototype._handleText):
1409         (InlineFormattingContext.prototype._commitLine):
1410         (InlineFormattingContext.prototype._initializeLine):
1411         * LayoutReloaded/FormattingContext/InlineFormatting/Line.js:
1412         (Line):
1413         (Line.prototype.isEmpty):
1414         (Line.prototype.rect):
1415         (Line.prototype.lineBoxes):
1416         (Line.prototype.addLineBox):
1417         (Line.prototype.appendFragment): Deleted.
1418         * LayoutReloaded/README.md:
1419         * LayoutReloaded/Utils.js:
1420         (Utils.computedLineHeight):
1421         (Utils.isBlockContainerElement):
1422         (Utils.textHeight):
1423         (Utils._dumpBox):
1424         (Utils._dumpLines.):
1425         (Utils._dumpLines):
1426         (Utils._dumpTree):
1427         (Utils.precisionRound):
1428         (Utils):
1429         * LayoutReloaded/misc/LayoutReloadedWebKit.patch:
1430         * LayoutReloaded/test/index.html:
1431
1432 2018-03-14  Tim Horton  <timothy_horton@apple.com>
1433
1434         Fix the build after r229567
1435
1436         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
1437
1438 2018-03-13  Jer Noble  <jer.noble@apple.com>
1439
1440         [iOS] Muted media playback can interrupt out-of-process audio
1441         https://bugs.webkit.org/show_bug.cgi?id=183606
1442         <rdar://problem/37466253>
1443
1444         Reviewed by Eric Carlson.
1445
1446         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
1447         * TestWebKitAPI/Tests/WebKitLegacy/ios/AudioSessionCategoryIOS.mm:
1448         (TestWebKitAPI::TEST):
1449         * TestWebKitAPI/Tests/WebKitLegacy/ios/video-with-paused-audio-and-playing-muted.html: Added.
1450
1451 2018-03-13  Ross Kirsling  <ross.kirsling@sony.com>
1452
1453         [Win] Layout Test fast/html/menuitem-element.html is failing.
1454         https://bugs.webkit.org/show_bug.cgi?id=179299
1455
1456         Reviewed by Per Arne Vollan.
1457
1458         * DumpRenderTree/win/DumpRenderTree.cpp:
1459         (setWebPreferencesForTestOptions):
1460         Recognize test option "enableMenuItemElement".
1461
1462 2018-03-12  Tim Horton  <timothy_horton@apple.com>
1463
1464         Stop using SDK conditionals to control feature definitions
1465         https://bugs.webkit.org/show_bug.cgi?id=183430
1466         <rdar://problem/38251619>
1467
1468         Reviewed by Dan Bernstein.
1469
1470         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
1471         * TestWebKitAPI/Configurations/WebKitTargetConditionals.xcconfig: Renamed.
1472
1473 2018-03-12  Ross Kirsling  <ross.kirsling@sony.com>
1474
1475         [DRT] TestOptions should not be ObjC.
1476         https://bugs.webkit.org/show_bug.cgi?id=183487
1477
1478         Reviewed by Per Arne Vollan.
1479
1480         * DumpRenderTree/CMakeLists.txt:
1481         * DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj:
1482         * DumpRenderTree/PlatformMac.cmake:
1483         Move TestOptions to platform-agnostic sources.
1484
1485         * DumpRenderTree/TestOptions.h:
1486         * DumpRenderTree/TestOptions.cpp: Renamed from Tools/DumpRenderTree/TestOptions.mm.
1487         * DumpRenderTree/mac/DumpRenderTree.mm:
1488         Remove NSURL dependency and align with WTR as much as possible.
1489
1490         * DumpRenderTree/win/DumpRenderTree.cpp:
1491         Consume TestOptions (recognizing just the ones that have WebPreferences defined for now).
1492
1493 2018-03-12  Yoav Weiss  <yoav@yoav.ws>
1494
1495         Runtime flag for link prefetch and remove link subresource.
1496         https://bugs.webkit.org/show_bug.cgi?id=183540
1497
1498         Reviewed by Chris Dumez.
1499
1500         Remove the LINK_PREFETCH build time flag.
1501
1502         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
1503
1504 2018-03-12  Wenson Hsieh  <wenson_hsieh@apple.com>
1505
1506         REGRESSION(r211643): Dismissing WKActionSheet should not also dismiss its presenting view controller
1507         https://bugs.webkit.org/show_bug.cgi?id=183549
1508         <rdar://problem/34960698>
1509
1510         Reviewed by Andy Estes.
1511
1512         Add TestWebKitAPI support for testing WKWebViews embedded within presented view controllers, and use this to
1513         check that dismissing an action sheet does not additionally cause the view controller being used to present the
1514         web view to also dismiss.
1515
1516         * TestWebKitAPI/ClassMethodSwizzler.h: Added.
1517         * TestWebKitAPI/ClassMethodSwizzler.mm: Added.
1518         (TestWebKitAPI::ClassMethodSwizzler::ClassMethodSwizzler):
1519         (TestWebKitAPI::ClassMethodSwizzler::~ClassMethodSwizzler):
1520
1521         Add ClassMethodSwizzler, an RAII which swizzles an Objective-C class method over its lifetime.
1522
1523         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
1524         * TestWebKitAPI/Tests/ios/ActionSheetTests.mm:
1525
1526         Add a new API test that loads a view controller which embeds a WKWebView, and verifies that presenting and then
1527         dismissing an action sheet from that web view does not cause the view controller to also dismiss.
1528
1529         (TestWebKitAPI::setOverrideViewControllerForFullscreenPresentation):
1530         (TestWebKitAPI::overrideViewControllerForFullscreenPresentation):
1531
1532         Mock +[UIViewController _viewControllerForFullScreenPresentationFromView:] to return the web view. This works
1533         around the fact that TestWebKitAPI is not a UI application, so certain pieces of UIKit API and SPI need to be
1534         stubbed or mocked to simulate being a UI application. We can remove these workarounds once
1535         https://webkit.org/b/175204 is addressed, and TestWebKitAPI becomes a UI application that can actually maintain
1536         a root view controller and key window.
1537
1538         (TestWebKitAPI::TEST):
1539         * TestWebKitAPI/cocoa/TestWKWebView.h:
1540         * TestWebKitAPI/cocoa/TestWKWebView.mm:
1541         (-[TestWKWebView initWithFrame:configuration:addToWindow:]):
1542
1543         Add a new initializer for TestWKWebView that doesn't force the view to be hosted within a UIWindow. This is used
1544         by TestWKWebViewController to create a TestWKWebView in -loadView.
1545
1546         * TestWebKitAPI/ios/TestWKWebViewController.h: Added.
1547         * TestWebKitAPI/ios/TestWKWebViewController.mm: Added.
1548         (-[TestWKWebViewControllerWindow _beginKeyWindowDeferral]):
1549         (-[TestWKWebViewControllerWindow _endKeyWindowDeferral]):
1550
1551         Stub out these methods to prevent UIKit from hitting assertions when making this UIWindow the key window. This
1552         can also be removed once TestWebKitAPI is a UI application.
1553
1554         (-[TestWKWebViewController initWithFrame:configuration:]):
1555         (-[TestWKWebViewController loadView]):
1556         (-[TestWKWebViewController webView]):
1557         (-[TestWKWebViewController dismissViewControllerAnimated:completion:]):
1558         (-[TestWKWebViewController dismissalHandler]):
1559         (-[TestWKWebViewController setDismissalHandler:]):
1560
1561         Add a UIViewController helper subclass whose -view is a WKWebView. The new API test presents this view
1562         controller. Tests may also provide a dismissalHandler, which is invoked when the view controller is being
1563         dismissed. The new API test uses this hook to verify that the view controller containing the web view isn't also
1564         dismissed after the action sheet goes away.
1565
1566         * TestWebKitAPI/ios/UIKitSPI.h:
1567
1568 2018-03-12  Basuke Suzuki  <Basuke.Suzuki@sony.com>
1569
1570         [webkitpy] Remove openssl command dependency.
1571         https://bugs.webkit.org/show_bug.cgi?id=183494
1572
1573         Reviewed by Ryosuke Niwa.
1574
1575         Added Python implementation of PEM file perser and switched to use that
1576         from external `openssl` command.
1577
1578         * Scripts/webkitpy/common/system/pemfile.py: Added.
1579         (load):
1580         (BadFormatError):
1581         (Pem):
1582         (Pem.__init__):
1583         (Pem.get):
1584         (Pem.get_all):
1585         (Pem.certificate):
1586         (Pem.private_key):
1587         (Pem.csr):
1588         (Pem.certificate_request):
1589         (Pem.certificate_signing_request):
1590         (_parse_pem_format):
1591         (_parse_pem_format.find_begin):
1592         (_parse_pem_format.find_end):
1593         (_parse_pem_format.sections):
1594         * Scripts/webkitpy/common/system/pemfile_unittest.py: Added.
1595         (PemFileTest):
1596         (PemFileTest.test_parse):
1597         (PemFileTest.test_parse_bad_format):
1598         * Scripts/webkitpy/port/base.py:
1599         (Port.start_websocket_server):
1600         (Port._extract_certificate_from_pem): Deleted.
1601         (Port._extract_private_key_from_pem): Deleted.
1602
1603 2018-03-12  Javier Fernandez  <jfernandez@igalia.com>
1604
1605         Remove GridLayout runtime flag
1606         https://bugs.webkit.org/show_bug.cgi?id=183484
1607
1608         Reviewed by Myles C. Maxfield.
1609
1610         The Grid Layout feature has been enabled by default for almost a
1611         year, so I think it's time to remove the runtime flag and the
1612         codepath run when the feature is disabled.
1613
1614         * DumpRenderTree/mac/DumpRenderTree.mm:
1615         (enableExperimentalFeatures):
1616
1617 2018-03-12  Antoine Quint  <graouts@apple.com>
1618
1619         [Web Animations] Implement CSS Animations and CSS Transitions as Web Animations
1620         https://bugs.webkit.org/show_bug.cgi?id=183504
1621         <rdar://problem/38372965>
1622
1623         Reviewed by Jon Lee.
1624
1625         Add a new <!-- webkit-test-runner --> flag to enable the CSS Animations and CSS Transitions
1626         as Web Animations runtime flag in the new tests we've created for this feature.
1627
1628         * DumpRenderTree/TestOptions.h:
1629         * DumpRenderTree/TestOptions.mm:
1630         (TestOptions::TestOptions):
1631         * DumpRenderTree/mac/DumpRenderTree.mm:
1632         (setWebPreferencesForTestOptions):
1633         * WebKitTestRunner/TestController.cpp:
1634         (WTR::TestController::resetPreferencesToConsistentValues):
1635         (WTR::updateTestOptionsFromTestHeader):
1636         * WebKitTestRunner/TestOptions.h:
1637         (WTR::TestOptions::hasSameInitializationOptions const):
1638
1639 2018-03-11  Zalan Bujtas  <zalan@apple.com>
1640
1641         [LayoutReloaded] Add Line class for InlineFormattingContext -and move files around.
1642         https://bugs.webkit.org/show_bug.cgi?id=183551
1643
1644         Reviewed by Wenson Hsieh.
1645
1646         * LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js: Renamed from Tools/LayoutReloaded/BlockFormattingContext.js.
1647         (BlockFormattingContext):
1648         (BlockFormattingContext.prototype.layout):
1649         (BlockFormattingContext.prototype.computeWidth):
1650         (BlockFormattingContext.prototype.computeHeight):
1651         (BlockFormattingContext.prototype.marginTop):
1652         (BlockFormattingContext.prototype.marginBottom):
1653         (BlockFormattingContext.prototype._computeStaticPosition):
1654         (BlockFormattingContext.prototype._placeInFlowPositionedChildren):
1655         (BlockFormattingContext.prototype._placeOutOfFlowDescendants):
1656         (BlockFormattingContext.prototype._computeOutOfFlowWidth):
1657         (BlockFormattingContext.prototype._computeFloatingWidth):
1658         (BlockFormattingContext.prototype._computeInFlowWidth):
1659         (BlockFormattingContext.prototype._computeOutOfFlowHeight):
1660         (BlockFormattingContext.prototype._computeFloatingHeight):
1661         (BlockFormattingContext.prototype._computeInFlowHeight):
1662         (BlockFormattingContext.prototype._computeHorizontalConstraint):
1663         (BlockFormattingContext.prototype._computeContentHeight):
1664         (BlockFormattingContext.prototype._computeInFlowPositionedPosition):
1665         (BlockFormattingContext.prototype._computeOutOfFlowPosition):
1666         (BlockFormattingContext.prototype._shrinkToFitWidth):
1667         * LayoutReloaded/FormattingContext/BlockFormatting/BlockMarginCollapse.js: Renamed from Tools/LayoutReloaded/BlockMarginCollapse.js.
1668         (BlockMarginCollapse.marginTop):
1669         (BlockMarginCollapse.marginBottom):
1670         (BlockMarginCollapse._isMarginTopCollapsedWithSibling):
1671         (BlockMarginCollapse._isMarginBottomCollapsedWithSibling):
1672         (BlockMarginCollapse._isMarginTopCollapsedWithParent):
1673         (BlockMarginCollapse._isMarginBottomCollapsedWithParent):
1674         (BlockMarginCollapse._nonCollapsedMarginTop):
1675         (BlockMarginCollapse._nonCollapsedMarginBottom):
1676         (BlockMarginCollapse._collapsedMarginTopFromFirstChild):
1677         (BlockMarginCollapse._collapsedMarginBottomFromLastChild):
1678         (BlockMarginCollapse._marginValue):
1679         (BlockMarginCollapse._hasAdjoiningMarginTopAndBottom):
1680         (BlockMarginCollapse):
1681         * LayoutReloaded/FormattingContext/FloatingContext.js: Renamed from Tools/LayoutReloaded/FloatingContext.js.
1682         (FloatingContext):
1683         (FloatingContext.prototype.computePosition):
1684         (FloatingContext.prototype.bottom):
1685         (FloatingContext.prototype._positionForFloating):
1686         (FloatingContext.prototype._positionForClear):
1687         (FloatingContext.prototype._computePositionToAvoidIntrudingFloats):
1688         (FloatingContext.prototype._addFloating):
1689         (FloatingContext.prototype._findInnerMostLeftAndRight):
1690         (FloatingContext.prototype._moveToNextVerticalPosition):
1691         (FloatingContext.prototype._availableSpace):
1692         (FloatingContext.prototype._findFloatingAtVerticalPosition):
1693         (FloatingContext.prototype._isEmpty):
1694         (FloatingContext.prototype._adjustedFloatingPosition):
1695         (FloatingContext.prototype._bottom):
1696         (FloatingContext.prototype._formattingContext):
1697         * LayoutReloaded/FormattingContext/FormattingContext.js: Renamed from Tools/LayoutReloaded/FormattingContext.js.
1698         (FormattingContext):
1699         (FormattingContext.prototype.rootContainer):
1700         (FormattingContext.prototype.floatingContext):
1701         (FormattingContext.prototype.layout):
1702         (FormattingContext.prototype.computeWidth):
1703         (FormattingContext.prototype.computeHeight):
1704         (FormattingContext.prototype.marginTop):
1705         (FormattingContext.prototype.marginLeft):
1706         (FormattingContext.prototype.marginBottom):
1707         (FormattingContext.prototype.marginRight):
1708         (FormattingContext.prototype.absoluteMarginBox):
1709         (FormattingContext.prototype.absoluteBorderBox):
1710         (FormattingContext.prototype.absolutePaddingBox):
1711         (FormattingContext.prototype.absoluteContentBox):
1712         * LayoutReloaded/FormattingContext/InlineFormatting/InlineFormattingContext.js: Renamed from Tools/LayoutReloaded/InlineFormattingContext.js.
1713         (InlineFormattingContext):
1714         (InlineFormattingContext.prototype.layout):
1715         (InlineFormattingContext.prototype._handleInlineBox):
1716         (InlineFormattingContext.prototype._handleText):
1717         (InlineFormattingContext.prototype._commitLine):
1718         (InlineFormattingContext.prototype._line):
1719         * LayoutReloaded/FormattingContext/InlineFormatting/Line.js: Copied from Tools/LayoutReloaded/InitialBlockContainer.js.
1720         (Line):
1721         (Line.prototype.isEmpty):
1722         (Line.prototype.availableWidth):
1723         (Line.prototype.appendFragment):
1724         * LayoutReloaded/LayoutReloaded.xcworkspace/contents.xcworkspacedata:
1725         * LayoutReloaded/LayoutTree/BlockContainer.js: Renamed from Tools/LayoutReloaded/BlockContainer.js.
1726         (BlockContainer):
1727         (BlockContainer.prototype.establishesInlineFormattingContext):
1728         * LayoutReloaded/LayoutTree/Box.js: Renamed from Tools/LayoutReloaded/Box.js.
1729         (Box):
1730         (Box.prototype.id):
1731         (Box.prototype.setRendererName):
1732         (Box.prototype.name):
1733         (Box.prototype.node):
1734         (Box.prototype.parent):
1735         (Box.prototype.nextSibling):
1736         (Box.prototype.nextInFlowSibling):
1737         (Box.prototype.previousSibling):
1738         (Box.prototype.previousInFlowSibling):
1739         (Box.prototype.setParent):
1740         (Box.prototype.setNextSibling):
1741         (Box.prototype.setPreviousSibling):
1742         (Box.prototype.rect):
1743         (Box.prototype.topLeft):
1744         (Box.prototype.bottomRight):
1745         (Box.prototype.setTopLeft):
1746         (Box.prototype.setSize):
1747         (Box.prototype.setWidth):
1748         (Box.prototype.setHeight):
1749         (Box.prototype.isContainer):
1750         (Box.prototype.isBlockLevelBox):
1751         (Box.prototype.isBlockContainerBox):
1752         (Box.prototype.isInlineLevelBox):
1753         (Box.prototype.setIsAnonymous):
1754         (Box.prototype.isAnonymous):
1755         (Box.prototype.establishesFormattingContext):
1756         (Box.prototype.establishedFormattingContext):
1757         (Box.prototype.establishesBlockFormattingContext):
1758         (Box.prototype.establishesInlineFormattingContext):
1759         (Box.prototype.isPositioned):
1760         (Box.prototype.isRelativePositioned):
1761         (Box.prototype.isAbsolutePositioned):
1762         (Box.prototype.isFixedPositioned):
1763         (Box.prototype.isInFlow):
1764         (Box.prototype.isOutOfFlowPositioned):
1765         (Box.prototype.isInFlowPositioned):
1766         (Box.prototype.isFloatingPositioned):
1767         (Box.prototype.isFloatingOrOutOfFlowPositioned):
1768         (Box.prototype.isRootElement):
1769         (Box.prototype.containingBlock):
1770         (Box.prototype.borderBox):
1771         (Box.prototype.paddingBox):
1772         (Box.prototype.contentBox):
1773         * LayoutReloaded/LayoutTree/Container.js: Renamed from Tools/LayoutReloaded/Container.js.
1774         (Container):
1775         (Container.prototype.isContainer):
1776         (Container.prototype.setFirstChild):
1777         (Container.prototype.setLastChild):
1778         (Container.prototype.firstChild):
1779         (Container.prototype.firstInFlowChild):
1780         (Container.prototype.lastChild):
1781         (Container.prototype.lastInFlowChild):
1782         (Container.prototype.hasChild):
1783         (Container.prototype.hasInFlowChild):
1784         * LayoutReloaded/LayoutTree/InitialBlockContainer.js: Renamed from Tools/LayoutReloaded/InitialBlockContainer.js.
1785         (InitialBlockContainer):
1786         (InitialBlockContainer.prototype.establishesBlockFormattingContext):
1787         (InitialBlockContainer.prototype.paddingBox):
1788         (InitialBlockContainer.prototype.contentBox):
1789         * LayoutReloaded/LayoutTree/InlineBox.js: Renamed from Tools/LayoutReloaded/InlineBox.js.
1790         (InlineBox):
1791         (InlineBox.prototype.setText):
1792         (InlineBox.prototype.text):
1793         * LayoutReloaded/LayoutTree/Text.js: Renamed from Tools/LayoutReloaded/Text.js.
1794         (Text):
1795         (Text.prototype.node):
1796         (Text.prototype.content):
1797         (Text.prototype.length):
1798         * LayoutReloaded/Utils.js:
1799         (Utils.nextBreakingOpportunity):
1800         (Utils.measureText):
1801         * LayoutReloaded/misc/headers/Line.h: Copied from Tools/LayoutReloaded/misc/headers/Text.h.
1802         * LayoutReloaded/misc/headers/Text.h:
1803         * LayoutReloaded/test/border-simple.html:
1804         * LayoutReloaded/test/index.html:
1805
1806 2018-03-10  Wenson Hsieh  <wenson_hsieh@apple.com>
1807
1808         [macOS] Copying a table from the Numbers app and pasting into iCloud Numbers fails
1809         https://bugs.webkit.org/show_bug.cgi?id=183485
1810         <rdar://problem/38041984>
1811
1812         Reviewed by Ryosuke Niwa.
1813
1814         Add new API tests to cover scenarios in which we paste image data alongside text data.
1815
1816         * TestWebKitAPI/Tests/WebKitCocoa/PasteMixedContent.mm:
1817         (TestWebKitAPI::TEST):
1818         * TestWebKitAPI/Tests/ios/UIPasteboardTests.mm:
1819         (TestWebKitAPI::TEST):
1820
1821 2018-03-09  Zalan Bujtas  <zalan@apple.com>
1822
1823         [LayoutReloaded] Initial commit -block formatting context.
1824         https://bugs.webkit.org/show_bug.cgi?id=183462
1825
1826         Reviewed by Antti Koivisto.
1827
1828         See README.md
1829
1830         * LayoutReloaded/BlockContainer.js: Added.
1831         (BlockContainer):
1832         (BlockContainer.prototype.establishesInlineFormattingContext):
1833         * LayoutReloaded/BlockFormattingContext.js: Added.
1834         (BlockFormattingContext):
1835         (BlockFormattingContext.prototype.layout):
1836         (BlockFormattingContext.prototype.computeWidth):
1837         (BlockFormattingContext.prototype.computeHeight):
1838         (BlockFormattingContext.prototype.marginTop):
1839         (BlockFormattingContext.prototype.marginBottom):
1840         (BlockFormattingContext.prototype._computeStaticPosition):
1841         (BlockFormattingContext.prototype._placeInFlowPositionedChildren):
1842         (BlockFormattingContext.prototype._placeOutOfFlowDescendants):
1843         (BlockFormattingContext.prototype._computeOutOfFlowWidth):
1844         (BlockFormattingContext.prototype._computeFloatingWidth):
1845         (BlockFormattingContext.prototype._computeInFlowWidth):
1846         (BlockFormattingContext.prototype._computeOutOfFlowHeight):
1847         (BlockFormattingContext.prototype._computeFloatingHeight):
1848         (BlockFormattingContext.prototype._computeInFlowHeight):
1849         (BlockFormattingContext.prototype._computeHorizontalConstraint):
1850         (BlockFormattingContext.prototype._computeContentHeight):
1851         (BlockFormattingContext.prototype._computeInFlowPositionedPosition):
1852         (BlockFormattingContext.prototype._computeOutOfFlowPosition):
1853         (BlockFormattingContext.prototype._shrinkToFitWidth):
1854         * LayoutReloaded/BlockMarginCollapse.js: Added.
1855         (BlockMarginCollapse.marginTop):
1856         (BlockMarginCollapse.marginBottom):
1857         (BlockMarginCollapse._isMarginTopCollapsedWithSibling):
1858         (BlockMarginCollapse._isMarginBottomCollapsedWithSibling):
1859         (BlockMarginCollapse._isMarginTopCollapsedWithParent):
1860         (BlockMarginCollapse._isMarginBottomCollapsedWithParent):
1861         (BlockMarginCollapse._nonCollapsedMarginTop):
1862         (BlockMarginCollapse._nonCollapsedMarginBottom):
1863         (BlockMarginCollapse._collapsedMarginTopFromFirstChild):
1864         (BlockMarginCollapse._collapsedMarginBottomFromLastChild):
1865         (BlockMarginCollapse._marginValue):
1866         (BlockMarginCollapse._hasAdjoiningMarginTopAndBottom):
1867         (BlockMarginCollapse):
1868         * LayoutReloaded/Box.js: Added.
1869         (Box):
1870         (Box.prototype.id):
1871         (Box.prototype.setRendererName):
1872         (Box.prototype.name):
1873         (Box.prototype.node):
1874         (Box.prototype.parent):
1875         (Box.prototype.nextSibling):
1876         (Box.prototype.nextInFlowSibling):
1877         (Box.prototype.previousSibling):
1878         (Box.prototype.previousInFlowSibling):
1879         (Box.prototype.setParent):
1880         (Box.prototype.setNextSibling):
1881         (Box.prototype.setPreviousSibling):
1882         (Box.prototype.rect):
1883         (Box.prototype.topLeft):
1884         (Box.prototype.bottomRight):
1885         (Box.prototype.setTopLeft):
1886         (Box.prototype.setSize):
1887         (Box.prototype.setWidth):
1888         (Box.prototype.setHeight):
1889         (Box.prototype.isContainer):
1890         (Box.prototype.isBlockLevelBox):
1891         (Box.prototype.isBlockContainerBox):
1892         (Box.prototype.isInlineLevelBox):
1893         (Box.prototype.setIsAnonymous):
1894         (Box.prototype.isAnonymous):
1895         (Box.prototype.establishesFormattingContext):
1896         (Box.prototype.establishedFormattingContext):
1897         (Box.prototype.establishesBlockFormattingContext):
1898         (Box.prototype.establishesInlineFormattingContext):
1899         (Box.prototype.isPositioned):
1900         (Box.prototype.isRelativePositioned):
1901         (Box.prototype.isAbsolutePositioned):
1902         (Box.prototype.isFixedPositioned):
1903         (Box.prototype.isInFlow):
1904         (Box.prototype.isOutOfFlowPositioned):
1905         (Box.prototype.isInFlowPositioned):
1906         (Box.prototype.isFloatingPositioned):
1907         (Box.prototype.isFloatingOrOutOfFlowPositioned):
1908         (Box.prototype.isRootElement):
1909         (Box.prototype.containingBlock):
1910         (Box.prototype.borderBox):
1911         (Box.prototype.paddingBox):
1912         (Box.prototype.contentBox):
1913         * LayoutReloaded/Container.js: Added.
1914         (Container):
1915         (Container.prototype.isContainer):
1916         (Container.prototype.setFirstChild):
1917         (Container.prototype.setLastChild):
1918         (Container.prototype.firstChild):
1919         (Container.prototype.firstInFlowChild):
1920         (Container.prototype.lastChild):
1921         (Container.prototype.lastInFlowChild):
1922         (Container.prototype.hasChild):
1923         (Container.prototype.hasInFlowChild):
1924         * LayoutReloaded/FloatingContext.js: Added.
1925         (FloatingContext):
1926         (FloatingContext.prototype.computePosition):
1927         (FloatingContext.prototype.bottom):
1928         (FloatingContext.prototype._positionForFloating):
1929         (FloatingContext.prototype._positionForClear):
1930         (FloatingContext.prototype._computePositionToAvoidIntrudingFloats):
1931         (FloatingContext.prototype._addFloating):
1932         (FloatingContext.prototype._findInnerMostLeftAndRight):
1933         (FloatingContext.prototype._moveToNextVerticalPosition):
1934         (FloatingContext.prototype._availableSpace):
1935         (FloatingContext.prototype._findFloatingAtVerticalPosition):
1936         (FloatingContext.prototype._isEmpty):
1937         (FloatingContext.prototype._adjustedFloatingPosition):
1938         (FloatingContext.prototype._bottom):
1939         (FloatingContext.prototype._formattingContext):
1940         * LayoutReloaded/FormattingContext.js: Added.
1941         (FormattingContext):
1942         (FormattingContext.prototype.rootContainer):
1943         (FormattingContext.prototype.floatingContext):
1944         (FormattingContext.prototype.layout):
1945         (FormattingContext.prototype.computeWidth):
1946         (FormattingContext.prototype.computeHeight):
1947         (FormattingContext.prototype.marginTop):
1948         (FormattingContext.prototype.marginLeft):
1949         (FormattingContext.prototype.marginBottom):
1950         (FormattingContext.prototype.marginRight):
1951         (FormattingContext.prototype.absoluteMarginBox):
1952         (FormattingContext.prototype.absoluteBorderBox):
1953         (FormattingContext.prototype.absolutePaddingBox):
1954         (FormattingContext.prototype.absoluteContentBox):
1955         * LayoutReloaded/InitialBlockContainer.js: Added.
1956         (InitialBlockContainer):
1957         (InitialBlockContainer.prototype.establishesBlockFormattingContext):
1958         (InitialBlockContainer.prototype.paddingBox):
1959         (InitialBlockContainer.prototype.contentBox):
1960         * LayoutReloaded/InlineBox.js: Added.
1961         (InlineBox):
1962         (InlineBox.prototype.setText):
1963         (InlineBox.prototype.text):
1964         * LayoutReloaded/InlineFormattingContext.js: Added.
1965         (InlineFormattingContext):
1966         (InlineFormattingContext.prototype.layout):
1967         (InlineFormattingContext.prototype._handleInlineBox):
1968         (InlineFormattingContext.prototype._handleText):
1969         * LayoutReloaded/Layout.js: Added.
1970         (layout):
1971         * LayoutReloaded/LayoutContext.js: Added.
1972         (LayoutContext):
1973         (LayoutContext.prototype.layoutFormattingContext):
1974         * LayoutReloaded/LayoutReloaded.xcworkspace/contents.xcworkspacedata: Added.
1975         * LayoutReloaded/LayoutReloaded.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: Added.
1976         * LayoutReloaded/README.md: Added.
1977         * LayoutReloaded/Text.js: Added.
1978         (Text):
1979         * LayoutReloaded/TreeBuilder.js: Added.
1980         (TreeBuilder.prototype.createTree):
1981         (TreeBuilder.prototype._createAndAttachBox):
1982         (TreeBuilder.prototype._appendChild):
1983         (TreeBuilder.prototype._findBox):
1984         (TreeBuilder.prototype._findNode):
1985         (TreeBuilder):
1986         * LayoutReloaded/Utils.js: Added.
1987         (LayoutPoint):
1988         (LayoutPoint.prototype.setLeft):
1989         (LayoutPoint.prototype.setTop):
1990         (LayoutPoint.prototype.left):
1991         (LayoutPoint.prototype.top):
1992         (LayoutPoint.prototype.shiftLeft):
1993         (LayoutPoint.prototype.shiftTop):
1994         (LayoutPoint.prototype.moveBy):
1995         (LayoutPoint.prototype.equal):
1996         (LayoutPoint.prototype.clone):
1997         (LayoutSize):
1998         (LayoutSize.prototype.setWidth):
1999         (LayoutSize.prototype.setHeight):
2000         (LayoutSize.prototype.width):
2001         (LayoutSize.prototype.height):
2002         (LayoutSize.prototype.growBy):
2003         (LayoutSize.prototype.shrinkBy):
2004         (LayoutSize.prototype.isEmpty):
2005         (LayoutSize.prototype.equal):
2006         (LayoutSize.prototype.clone):
2007         (LayoutRect):
2008         (LayoutRect.prototype.setTop):
2009         (LayoutRect.prototype.setLeft):
2010         (LayoutRect.prototype.setBottom):
2011         (LayoutRect.prototype.setRight):
2012         (LayoutRect.prototype.left):
2013         (LayoutRect.prototype.top):
2014         (LayoutRect.prototype.bottom):
2015         (LayoutRect.prototype.right):
2016         (LayoutRect.prototype.setTopLeft):
2017         (LayoutRect.prototype.topLeft):
2018         (LayoutRect.prototype.topRight):
2019         (LayoutRect.prototype.bottomRight):
2020         (LayoutRect.prototype.setWidth):
2021         (LayoutRect.prototype.setHeight):
2022         (LayoutRect.prototype.setSize):
2023         (LayoutRect.prototype.size):
2024         (LayoutRect.prototype.width):
2025         (LayoutRect.prototype.height):
2026         (LayoutRect.prototype.growBy):
2027         (LayoutRect.prototype.shrinkBy):
2028         (LayoutRect.prototype.moveBy):
2029         (LayoutRect.prototype.isEmpty):
2030         (LayoutRect.prototype.equal):
2031         (LayoutRect.prototype.intersects):
2032         (LayoutRect.prototype.contains):
2033         (LayoutRect.prototype.clone):
2034         (ASSERT_NOT_REACHED):
2035         (ASSERT):
2036         (Utils.computedValue):
2037         (Utils.propertyIsAuto):
2038         (Utils.isWidthAuto):
2039         (Utils.isHeightAuto):
2040         (Utils.isTopAuto):
2041         (Utils.isLeftAuto):
2042         (Utils.isBottomAuto):
2043         (Utils.isRightAuto):
2044         (Utils.width):
2045         (Utils.height):
2046         (Utils.top):
2047         (Utils.bottom):
2048         (Utils.left):
2049         (Utils.right):
2050         (Utils.hasBorderTop):
2051         (Utils.hasBorderBottom):
2052         (Utils.hasPaddingTop):
2053         (Utils.hasPaddingBottom):
2054         (Utils.computedMarginTop):
2055         (Utils.computedMarginLeft):
2056         (Utils.computedMarginBottom):
2057         (Utils.computedMarginRight):
2058         (Utils.computedBorderTopLeft):
2059         (Utils.computedBorderBottomRight):
2060         (Utils.computedPaddingTopLeft):
2061         (Utils.computedPaddingBottomRight):
2062         (Utils.computedBorderAndPaddingTop):
2063         (Utils.computedBorderAndPaddingLeft):
2064         (Utils.computedBorderAndPaddingBottom):
2065         (Utils.computedBorderAndPaddingRight):
2066         (Utils.computedHorizontalBorderAndPadding):
2067         (Utils.computedVerticalBorderAndPadding):
2068         (Utils.hasClear):
2069         (Utils.hasClearLeft):
2070         (Utils.hasClearRight):
2071         (Utils.hasClearBoth):
2072         (Utils.isBlockLevelElement):
2073         (Utils.isBlockContainerElement):
2074         (Utils.isInlineLevelElement):
2075         (Utils.isTableElement):
2076         (Utils.isRelativePositioned):
2077         (Utils.isAbsolutePositioned):
2078         (Utils.isFixedPositioned):
2079         (Utils.isOverflowVisible):
2080         (Utils.isFloatingPositioned):
2081         (Utils.isFloatingLeft):
2082         (Utils.mapToContainer):
2083         (Utils.mapStaticToAbsolute):
2084         (Utils.collectOutOfFlowDescendants):
2085         (Utils.nextBreakingOpportunity):
2086         (Utils.measureText):
2087         (Utils.layoutTreeDump):
2088         (Utils._dumpBox):
2089         (Utils._dumpTree):
2090         (Utils):
2091         * LayoutReloaded/misc/LayoutReloadedWebKit.patch: Added.
2092         * LayoutReloaded/misc/headers/BlockContainer.h: Added.
2093         * LayoutReloaded/misc/headers/BlockFormattingContext.h: Added.
2094         * LayoutReloaded/misc/headers/BlockMarginCollapse.h: Added.
2095         * LayoutReloaded/misc/headers/Box.h: Added.
2096         * LayoutReloaded/misc/headers/Container.h: Added.
2097         * LayoutReloaded/misc/headers/FloatingContext.h: Added.
2098         * LayoutReloaded/misc/headers/FormattingContext.h: Added.
2099         * LayoutReloaded/misc/headers/InitialBlockContainer.h: Added.
2100         * LayoutReloaded/misc/headers/InlineBox.h: Added.
2101         * LayoutReloaded/misc/headers/LayoutContext.h: Added.
2102         * LayoutReloaded/misc/headers/Text.h: Added.
2103         * LayoutReloaded/test/TestHarness.js: Added.
2104         (verifyLayoutTreeDump):
2105         (runLayout):
2106         * LayoutReloaded/test/absolute-auto-with-sibling-margin-bottom.html: Added.
2107         * LayoutReloaded/test/absolute-bottom.html: Added.
2108         * LayoutReloaded/test/absolute-height-stretch.html: Added.
2109         * LayoutReloaded/test/absolute-left-auto.html: Added.
2110         * LayoutReloaded/test/absolute-left-right-top-bottom-auto.html: Added.
2111         * LayoutReloaded/test/absolute-nested.html: Added.
2112         * LayoutReloaded/test/absolute-nested2.html: Added.
2113         * LayoutReloaded/test/absolute-simple.html: Added.
2114         * LayoutReloaded/test/absolute-width-shrink-to-fit.html: Added.
2115         * LayoutReloaded/test/absolute-width-stretch.html: Added.
2116         * LayoutReloaded/test/absolute-with-inline-preferred-width.html: Added.
2117         * LayoutReloaded/test/absolute-with-static-block-position-nested.html: Added.
2118         * LayoutReloaded/test/almost-intruding-left-float-simple.html: Added.
2119         * LayoutReloaded/test/border-simple.html: Added.
2120         * LayoutReloaded/test/fixed-nested.html: Added.
2121         * LayoutReloaded/test/float-left-when-container-has-padding-margin.html: Added.
2122         * LayoutReloaded/test/floating-box-clear-both-simple.html: Added.
2123         * LayoutReloaded/test/floating-box-clear-right-simple.html: Added.
2124         * LayoutReloaded/test/floating-box-left-and-right-multiple-with-top-offset.html: Added.
2125         * LayoutReloaded/test/floating-box-left-and-right-multiple.html: Added.
2126         * LayoutReloaded/test/floating-box-right-simple.html: Added.
2127         * LayoutReloaded/test/floating-box-with-clear-siblings.html: Added.
2128         * LayoutReloaded/test/floating-box-with-clear-simple.html: Added.
2129         * LayoutReloaded/test/floating-box-with-new-formatting-context.html: Added.
2130         * LayoutReloaded/test/floating-box-with-relative-positioned-sibling.html: Added.
2131         * LayoutReloaded/test/floating-left-right-simple.html: Added.
2132         * LayoutReloaded/test/floating-left-right-with-all-margins.html: Added.
2133         * LayoutReloaded/test/floating-lefts-and-rights-simple.html: Added.
2134         * LayoutReloaded/test/floating-multiple-lefts-in-body.html: Added.
2135         * LayoutReloaded/test/floating-multiple-lefts-multiple-lines.html: Added.
2136         * LayoutReloaded/test/floating-multiple-lefts.html: Added.
2137         * LayoutReloaded/test/floating-sizing.html: Added.
2138         * LayoutReloaded/test/floating-sizing2.html: Added.
2139         * LayoutReloaded/test/floating-sizing3.html: Added.
2140         * LayoutReloaded/test/floating-with-new-block-formatting-context.html: Added.
2141         * LayoutReloaded/test/index.html: Added.
2142         * LayoutReloaded/test/inline-content-simple.html: Added.
2143         * LayoutReloaded/test/intruding-left-float-simple.html: Added.
2144         * LayoutReloaded/test/margin-collapse-bottom-bottom.html: Added.
2145         * LayoutReloaded/test/margin-collapse-bottom-nested.html: Added.
2146         * LayoutReloaded/test/margin-collapse-first-last-are-floating.html: Added.
2147         * LayoutReloaded/test/margin-collapse-simple.html: Added.
2148         * LayoutReloaded/test/margin-collapse-top-nested.html: Added.
2149         * LayoutReloaded/test/margin-collapse-when-child-has-padding-border.html: Added.
2150         * LayoutReloaded/test/margin-collapse-with-block-formatting-context.html: Added.
2151         * LayoutReloaded/test/margin-collapse-with-block-formatting-context2.html: Added.
2152         * LayoutReloaded/test/margin-left-right-sizing-out-of-flow.html: Added.
2153         * LayoutReloaded/test/margin-left-right-sizing.html: Added.
2154         * LayoutReloaded/test/margin-propagation-simple-content-height.html: Added.
2155         * LayoutReloaded/test/margin-sibling-collapse-propagated.html: Added.
2156         * LayoutReloaded/test/margin-simple.html: Added.
2157         * LayoutReloaded/test/negative-margin-simple.html: Added.
2158         * LayoutReloaded/test/padding-nested.html: Added.
2159         * LayoutReloaded/test/padding-simple.html: Added.
2160         * LayoutReloaded/test/relative-auto-with-parent-offset.html: Added.
2161         * LayoutReloaded/test/relative-auto.html: Added.
2162         * LayoutReloaded/test/relative-bottom.html: Added.
2163         * LayoutReloaded/test/relative-right.html: Added.
2164         * LayoutReloaded/test/relative-siblings.html: Added.
2165         * LayoutReloaded/test/relative-simple.html: Added.
2166
2167 2018-03-09  Stephan Szabo  <stephan.szabo@sony.com>
2168
2169         WebKitTestRunner: Do not build accessibility files/idl when !HAVE(ACCESSIBILITY)
2170         https://bugs.webkit.org/show_bug.cgi?id=183516
2171
2172         Reviewed by Alex Christensen.
2173
2174         * WebKitTestRunner/CMakeLists.txt:
2175
2176 2018-03-09  Basuke Suzuki  <Basuke.Suzuki@sony.com>
2177
2178         [webkitpy, WinCairo] Launch Apache HTTPD for HTTP Tests.
2179         https://bugs.webkit.org/show_bug.cgi?id=183265
2180
2181         Reviewed by Daniel Bates.
2182
2183         Launch apache httpd server from python script for WinCairo HTTP LayoutTests. By now, AppleWin uses
2184         Cygwin to launch httpd server. This patch enables native Windows to run HTTP LayoutTests by starting
2185         and stopping httpd server from the script.
2186
2187         * Scripts/webkitpy/layout_tests/servers/apache_http_server.py:
2188         (LayoutTestApacheHttpd.__init__):
2189         (LayoutTestApacheHttpd._copy_apache_config_file):
2190         (LayoutTestApacheHttpd):
2191         (LayoutTestApacheHttpd.platform):
2192         (LayoutTestApacheHttpd._spawn_process):
2193         (LayoutTestApacheHttpd._stop_running_server):
2194         (LayoutTestApacheHttpd._run):
2195         (LayoutTestApacheHttpd._server_error):
2196         * Scripts/webkitpy/layout_tests/servers/http_server_base.py:
2197         (HttpServerBase.aliases):
2198         (HttpServerBase):
2199         (HttpServerBase._build_alias_path_pairs):
2200         (HttpServerBase._build_alias_path_pairs._make_path):
2201         * Scripts/webkitpy/layout_tests/servers/http_server_base_unittest.py:
2202         (TestHttpServerBase.test_corrupt_pid_file):
2203         (TestHttpServerBase):
2204         (TestHttpServerBase.test_build_alias_path_pairs):
2205         * Scripts/webkitpy/port/base.py:
2206         (Port._apache_config_file_name_for_platform):
2207         * Scripts/webkitpy/port/port_testcase.py:
2208         (test_apache_config_file_name_for_platform):
2209         * Scripts/webkitpy/port/win.py:
2210         (WinPort._path_to_apache):
2211         (WinCairoPort.default_baseline_search_path):
2212         (WinCairoPort):
2213         (WinCairoPort.check_httpd):
2214
2215 2018-03-09  Carlos Garcia Campos  <cgarcia@igalia.com>
2216
2217         [GTK] Do not use WebKitDOMHTMLFormElement as argument of signal WebKitWebPage::will-submit-form
2218         https://bugs.webkit.org/show_bug.cgi?id=183510
2219
2220         Reviewed by Michael Catanzaro.
2221
2222         Update the test to use WebKitDOMElement instead and fix a memory leak.
2223
2224         * TestWebKitAPI/Tests/WebKitGLib/WebExtensionTest.cpp:
2225         (handleFormSubmissionCallback):
2226         (willSubmitFormCallback):
2227
2228 2018-03-08  Stephan Szabo  <stephan.szabo@sony.com>
2229
2230         WebKitTestRunner: Don't use accessibility controller when !HAVE(ACCESSIBILITY)
2231         https://bugs.webkit.org/show_bug.cgi?id=183475
2232
2233         Reviewed by Youenn Fablet.
2234
2235         * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
2236         (WTR::InjectedBundle::done):
2237         * WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
2238         (WTR::InjectedBundlePage::didClearWindowForFrame):
2239
2240 2018-03-08  Ms2ger  <Ms2ger@igalia.com>
2241
2242         [WPE] Update expectations for API tests
2243         https://bugs.webkit.org/show_bug.cgi?id=183434
2244
2245         Unreviewed test gardening.
2246
2247         * TestWebKitAPI/glib/TestExpectations.json:
2248
2249 2018-03-07  Carlos Garcia Campos  <cgarcia@igalia.com>
2250
2251         [GTK][WPE] Leak checker is not working in WebKitGLib web process tests
2252         https://bugs.webkit.org/show_bug.cgi?id=183404
2253
2254         Reviewed by Michael Catanzaro.
2255
2256         This might have regressed when we started to use the JSC garbage collector timers. The thing is that we expect
2257         that the WebProcessTester object that we expose to JavaScript is released when the web frame is destroyed, but
2258         that's no longer the case. On window object cleared a GC is scheduled, but JSC timers do the actual garbage
2259         collection later. In the case of tests that never happens because the web process finishes quickly after the
2260         test. We need to force a garbage collection at some point when the web page is destroyed. We can't use the
2261         WebKitWebPage destroy signal, since we are also checking that WebKitWebPage isn't leaked. The
2262         API::InjectedBundle::Client::willDestroyPage() always happen when the page is closed, even if WebKitWebPage is
2263         still alive, so we can force the GC at that point. The only problem is that the frame is detached right after
2264         that point, so we can't check WebKitFrame leaks. The only frame in the tests is the main one, so we can assume
2265         that if WebKitWebPage is released, the frame is too.
2266
2267         * TestWebKitAPI/Tests/WebKitGLib/FrameTest.cpp:
2268         (WebKitFrameTest::testMainFrame): Stop checking we don't leak WebKitFrame.
2269         (WebKitFrameTest::testURI): Ditto.
2270         (WebKitFrameTest::testJavaScriptContext): Ditto.
2271         * TestWebKitAPI/Tests/WebKitGLib/TestFrame.cpp:
2272         (testWebKitFrameMainFrame): Use new WebViewTest::runWebProcessTest() API.
2273         (testWebKitFrameURI): Ditto.
2274         (testWebKitFrameJavaScriptContext): Ditto.
2275         (webkitFrameTestRun): Deleted.
2276         * TestWebKitAPI/Tests/WebKitGLib/WebProcessTest.cpp:
2277         (runTest): We no longer need the special case for dom-cache test.
2278         (windowObjectClearedCallback): Only expose test runner object to JavaScript when loading tests.
2279         (webkit_web_extension_initialize): Call webkitWebExtensionSetGarbageCollectOnPageDestroy() to ensure a garbage
2280         collection is performed when the page is closing.
2281         * TestWebKitAPI/Tests/WebKitGtk/DOMClientRectTest.cpp:
2282         (WebKitDOMClientRectTest::testDivClientRectsPositionAndLength): Fix memory leak,
2283         webkit_dom_client_rect_list_item() returns a full reference.
2284         * TestWebKitAPI/Tests/WebKitGtk/TestAutocleanups.cpp:
2285         (testWebProcessAutocleanups):Use new WebViewTest::runWebProcessTest() API.
2286         * TestWebKitAPI/Tests/WebKitGtk/TestDOMClientRect.cpp:
2287         (testWebKitDOMClientRectDivBoundingClientRectPosition): Use new WebViewTest::runWebProcessTest() API.
2288         (testWebKitDOMClientRectDivClientRectsPositionAndLength): Use new WebViewTest::runWebProcessTest() API.
2289         (prepareDOMForClientRectPositionTests): Deleted.
2290         * TestWebKitAPI/Tests/WebKitGtk/TestDOMNode.cpp:
2291         (testWebKitDOMNodeHierarchyNavigation): Use new WebViewTest::runWebProcessTest() API.
2292         (testWebKitDOMNodeInsertion): Ditto.
2293         (testWebKitDOMNodeTagNamesNodeList): Ditto.
2294         (testWebKitDOMNodeTagNamesHTMLCollection): Ditto.
2295         (testWebKitDOMObjectCache): We no longer need to run the test several times, since runWebProcessTest() loads
2296         about blank after every test.
2297         (prepareDOMForTagNamesTests): Deleted.
2298         * TestWebKitAPI/Tests/WebKitGtk/TestDOMNodeFilter.cpp:
2299         (testWebKitDOMNodeFilterTreeWalker): Use new WebViewTest::runWebProcessTest() API.
2300         (testWebKitDOMNodeFilterNodeIterator): Ditto.
2301         (runTest): Deleted.
2302         * TestWebKitAPI/Tests/WebKitGtk/TestDOMXPathNSResolver.cpp:
2303         (testWebKitDOMXPathNSResolverNative): Use new WebViewTest::runWebProcessTest() API.
2304         (testWebKitDOMXPathNSResolverCustom): Ditto.
2305         * TestWebKitAPI/Tests/WebKitGtk/TestEditor.cpp:
2306         (testWebKitWebEditorSelectionChanged): Use new WebViewTest::runWebProcessTest() API.
2307         * TestWebKitAPI/glib/WebKitGLib/WebViewTest.cpp:
2308         (WebViewTest::runWebProcessTest): It now receives the contents, so it automatically loads the view using
2309         "webprocess://test" as base URI, used to detect tests in the web process. It also loads about:blank after every
2310         test to ensure that window object is cleared.
2311         * TestWebKitAPI/glib/WebKitGLib/WebViewTest.h:
2312
2313 2018-03-07  Youenn Fablet  <youenn@apple.com>
2314
2315         Match unsupported plugins based on domains and not origin
2316         https://bugs.webkit.org/show_bug.cgi?id=183384
2317
2318         Reviewed by Chris Dumez.
2319
2320         * TestWebKitAPI/Tests/WebCore/URL.cpp:
2321         (TestWebKitAPI::TEST_F):
2322         * WebKitTestRunner/TestController.cpp:
2323         (WTR::TestController::setPluginSupportedMode): Update to whitelist
2324         localhost and not http://localhost:8080
2325
2326 2018-03-07  Jonathan Bedard  <jbedard@apple.com>
2327
2328         webkitpy: Allow apple_additions() to define additional ports
2329         https://bugs.webkit.org/show_bug.cgi?id=183412
2330         <rdar://problem/38232353>
2331
2332         Reviewed by Aakash Jain.
2333
2334         * Scripts/webkitpy/port/factory.py:
2335         (PortFactory.get): Allow apple_additions to define port classes to be used
2336         in run-webkit-tests.
2337
2338 2018-03-07  Jonathan Bedard  <jbedard@apple.com>
2339
2340         webkitpy: Remove obsolete function from MockAppleAdditions
2341         https://bugs.webkit.org/show_bug.cgi?id=183415
2342         <rdar://problem/38236407>
2343
2344         Reviewed by Aakash Jain.
2345
2346         * Scripts/webkitpy/port/port_testcase.py:
2347         (bind_mock_apple_additions.MockAppleAdditions):
2348         (bind_mock_apple_additions.MockAppleAdditions.ios_os_name): Deleted.
2349         (bind_mock_apple_additions.MockAppleAdditions.mac_os_name): Deleted.
2350
2351 2018-03-07  Jonathan Bedard  <jbedard@apple.com>
2352
2353         webkitpy: --dedicated-simulators does not boot the correct number of simulators
2354         https://bugs.webkit.org/show_bug.cgi?id=183409
2355         <rdar://problem/38224631>
2356
2357         Reviewed by Aakash Jain.
2358
2359         * Scripts/webkitpy/port/ios_simulator.py:
2360         (IOSSimulatorPort.default_child_processes): When not using dedicated simulators,
2361         we should use the number of booted simulators as our default child processes.
2362
2363 2018-03-07  Alejandro G. Castro  <alex@igalia.com>
2364
2365         Make NetworkRTCResolver port agnostic
2366         https://bugs.webkit.org/show_bug.cgi?id=178855
2367
2368         Reviewed by Youenn Fablet.
2369
2370         Added new unit tests for he resolve and stopResolve functions. We need to compile them for the
2371         other platforms when the APIs are supported.
2372
2373         * TestWebKitAPI/PlatformGTK.cmake:
2374         * TestWebKitAPI/Tests/WebCore/DNS.cpp:
2375
2376 2018-03-06  Youenn Fablet  <youenn@apple.com>
2377
2378         didReceiveServerRedirectForProvisionalNavigation is not called in case of document redirection with service worker registration change
2379         https://bugs.webkit.org/show_bug.cgi?id=183299
2380         <rdar://problem/37547029>
2381
2382         Reviewed by Alex Christensen.
2383
2384         Add support for checking whether this callback is called.
2385         Used in the added layout test.
2386
2387         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
2388         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
2389         (WTR::TestRunner::didReceiveServerRedirectForProvisionalNavigation const):
2390         (WTR::TestRunner::clearDidReceiveServerRedirectForProvisionalNavigation):
2391         * WebKitTestRunner/InjectedBundle/TestRunner.h:
2392         * WebKitTestRunner/TestController.cpp:
2393         (WTR::TestController::createOtherPage):
2394         (WTR::TestController::resetStateToConsistentValues):
2395         (WTR::TestController::didReceiveServerRedirectForProvisionalNavigation):
2396         * WebKitTestRunner/TestController.h:
2397         (WTR::TestController::didReceiveServerRedirectForProvisionalNavigation const):
2398         (WTR::TestController::clearDidReceiveServerRedirectForProvisionalNavigation):
2399         * WebKitTestRunner/TestInvocation.cpp:
2400         (WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):
2401
2402 2018-03-06  Chris Dumez  <cdumez@apple.com>
2403
2404         fast/loader/redirect-to-invalid-url-using-meta-refresh-disallowed.html fails with async policy delegates
2405         https://bugs.webkit.org/show_bug.cgi?id=183345
2406
2407         Reviewed by Alex Christensen.
2408
2409         Add layout test infrastructure so a test can know when didCancelClientRedirectForFrame has
2410         been called. The tests used to rely on a 0-timer but this does not work when the client
2411         responds to the navigation policy asynchronously.
2412
2413         * DumpRenderTree/TestRunner.cpp:
2414         (getDidCancelClientRedirect):
2415         (TestRunner::staticValues):
2416         * DumpRenderTree/TestRunner.h:
2417         (TestRunner::didCancelClientRedirect const):
2418         (TestRunner::setDidCancelClientRedirect):
2419         * DumpRenderTree/mac/FrameLoadDelegate.mm:
2420         (-[FrameLoadDelegate webView:didCancelClientRedirectForFrame:]):
2421         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
2422         * WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
2423         (WTR::InjectedBundlePage::didCancelClientRedirectForFrame):
2424         * WebKitTestRunner/InjectedBundle/TestRunner.h:
2425         (WTR::TestRunner::didCancelClientRedirect const):
2426         (WTR::TestRunner::setDidCancelClientRedirect):
2427
2428 2018-03-06  Zan Dobersek  <zdobersek@igalia.com>
2429
2430         REGRESSION(r229309): s_exceptionInstructions allocation change causing crashes in LLInt on WPE
2431         https://bugs.webkit.org/show_bug.cgi?id=183366
2432
2433         Reviewed by Michael Catanzaro.
2434
2435         Have the TestRunnerInjectedBundle CMake library link against libraries
2436         in the WebKitTestRunnerInjectedBundle_LIBRARIES list, and not the
2437         WebKitTestRunner_LIBRARIES list, which is used for the WebKitTestRunner
2438         executable. This allows narrowing down the libraries to only those that
2439         are necessary for the injected bundle shared object.
2440
2441         The GTK+ port already has this list specified, adding one for the WPE
2442         port.
2443
2444         * WebKitTestRunner/CMakeLists.txt:
2445         Link the TestRunnerInjectedBundle library against the libraries in the
2446         WebKitTestRunnerInjectedBundle_LIBRARIES list.
2447         * WebKitTestRunner/PlatformWPE.cmake:
2448         Specify the WebKitTestRunnerInjectedBundle_LIBRARIES list, including the
2449         basic system dependencies, WebCoreTestSupport and WebKit. This follows
2450         the GTK+ port.
2451
2452 2018-03-06  Dominik Infuehr  <dinfuehr@igalia.com>
2453
2454         [ARM] Disable tests that run out of memory
2455         https://bugs.webkit.org/show_bug.cgi?id=182699
2456
2457         Reviewed by Žan Doberšek.
2458
2459         Add run mode to allow running modules.yaml-tests without
2460         disabling LLInt for specific tests.
2461
2462         * Scripts/run-jsc-stress-tests:
2463
2464 2018-03-05  Yusuke Suzuki  <utatane.tea@gmail.com>
2465
2466         Fix std::make_unique / new[] using system malloc
2467         https://bugs.webkit.org/show_bug.cgi?id=182975
2468
2469         Reviewed by JF Bastien.
2470
2471         * TestWebKitAPI/CMakeLists.txt:
2472         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
2473         * TestWebKitAPI/Tests/WTF/UniqueArray.cpp: Copied from Source/WebKit/Platform/win/LoggingWin.cpp.
2474         (TestWebKitAPI::NonTrivialDestructor::NonTrivialDestructor):
2475         (TestWebKitAPI::NonTrivialDestructor::~NonTrivialDestructor):
2476         (TestWebKitAPI::NonTrivialDestructor::setLog):
2477         (TestWebKitAPI::TEST):
2478
2479 2018-03-05  Myles C. Maxfield  <mmaxfield@apple.com>
2480
2481         DumpRenderTree build fix
2482
2483         Unreviewed.
2484
2485         * DumpRenderTree/mac/LayoutTestHelper.m:
2486
2487 2018-03-05  Andy Estes  <aestes@apple.com>
2488
2489         [Mac] Teach WebCore::Pasteboard about file promise drags
2490         https://bugs.webkit.org/show_bug.cgi?id=183314
2491         <rdar://problem/38105493>
2492
2493         Reviewed by Darin Adler.
2494
2495         * DumpRenderTree/DumpRenderTreeFileDraggingSource.h:
2496         * DumpRenderTree/DumpRenderTreeFileDraggingSource.m:
2497         (-[DumpRenderTreeFileDraggingSource initWithPromisedFileURLs:]):
2498         (-[DumpRenderTreeFileDraggingSource dealloc]):
2499
2500         Taught DumpRenderTreeFileDraggingSource to store the promised file URLs.
2501
2502         * DumpRenderTree/mac/DumpRenderTree.mm:
2503         (runTest):
2504
2505         Called +[DumpRenderTreeDraggingInfo clearAllFilePromiseReceivers] after running a test.
2506
2507         * DumpRenderTree/mac/DumpRenderTreeDraggingInfo.h:
2508         * DumpRenderTree/mac/DumpRenderTreeDraggingInfo.mm:
2509         (-[DumpRenderTreeFilePromiseReceiver initWithPromisedUTIs:]):
2510         (-[DumpRenderTreeFilePromiseReceiver fileTypes]):
2511         (-[DumpRenderTreeFilePromiseReceiver fileNames]):
2512         (-[DumpRenderTreeFilePromiseReceiver dealloc]):
2513         (copyFile):
2514         (-[DumpRenderTreeFilePromiseReceiver receivePromisedFilesAtDestination:options:operationQueue:reader:]):
2515
2516         We can't instantiate real NSFilePromiseReceivers in DumpRenderTree. They rely on the
2517         pasteboard server to generate unique file URLs, which is incompatible with our swizzled
2518         NSPasteboard.
2519
2520         Instead, create a subclass of NSFilePromiseReceiver that implements its own promise resolution.
2521         -receivePromisedFilesAtDestination:... asks its DumpRenderTreeFileDraggingSource for the
2522         array of file URLs, then copies each to the destination directory on the specified operation
2523         queue. It emulates how NSPasteboard tries to find a unique destination name by appending
2524         numbers to the file name.
2525
2526         All receivers are collected in a global array that is cleared when each test finishes.
2527         DumpRenderTreeFilePromiseReceiver will delete the files it copied in -dealloc.
2528
2529         (+[DumpRenderTreeDraggingInfo clearAllFilePromiseReceivers]):
2530         (-[DumpRenderTreeDraggingInfo enumerateDraggingItemsWithOptions:forView:classes:searchOptions:usingBlock:]):
2531         
2532         If NSFilesPromisePboardType is on the pasteboard and classArray contains
2533         NSFilePromiseReceiver, construct a DumpRenderTreeFilePromiseReceiver, add it to the array of
2534         all file promise receivers, then wrap it in an NSDraggingItem and call block.
2535
2536         * DumpRenderTree/mac/EventSendingController.mm:
2537         (+[EventSendingController isSelectorExcludedFromWebScript:]):
2538         (+[EventSendingController webScriptNameForSelector:]):
2539         (-[EventSendingController beginDragWithFilePromises:]):
2540
2541         Implement eventSender.beginDragWithFilePromises() by placing file UTIs on the pasteboard
2542         with type NSFilesPromisePboardType, creating a DumpRenderTreeFileDraggingSource with the
2543         file URLs, and creating a new DumpRenderTreeDraggingInfo and passing it to
2544         -[WebView draggingEntered:].
2545
2546 2018-03-05  Aakash Jain  <aakash_jain@apple.com>
2547
2548         [webkitpy] Bugzilla class should use NetworkTransaction for network operations
2549         https://bugs.webkit.org/show_bug.cgi?id=183222
2550
2551         Reviewed by Alexey Proskuryakov.
2552
2553         * Scripts/webkitpy/common/net/bugzilla/bugzilla.py:
2554         (Bugzilla.open_url): Method which uses NetworkTransaction for opening url.
2555         (Bugzilla.fetch_user): Used self.open_url instead of directly calling browser.open().
2556         (Bugzilla.add_user_to_groups): Ditto.
2557         (Bugzilla._fetch_bug_page): Ditto.
2558         (Bugzilla.fetch_attachment_contents): Ditto.
2559         (Bugzilla.get_bug_id_for_attachment_id): Ditto.
2560         (Bugzilla.authenticate): Ditto.
2561         (Bugzilla.add_attachment_to_bug): Ditto.
2562         (Bugzilla.add_patch_to_bug): Ditto.
2563         (Bugzilla.create_bug): Ditto.
2564         (Bugzilla.clear_attachment_flags): Ditto.
2565         (Bugzilla.set_flag_on_attachment): Ditto.
2566         (Bugzilla.obsolete_attachment): Ditto.
2567         (Bugzilla.add_cc_to_bug): Ditto.
2568         (Bugzilla.post_comment_to_bug): Ditto.
2569         (Bugzilla.close_bug_as_fixed): Ditto.
2570         (Bugzilla.reassign_bug): Ditto.
2571         (Bugzilla.reopen_bug): Ditto.
2572         (Bugzilla._fetch_bug_page_by_url): Deleted, not required anymore.
2573         * Scripts/webkitpy/common/net/networktransaction.py:
2574         (NetworkTransaction.run): Added a FIXME.
2575
2576 2018-03-05  Joseph Pecoraro  <pecoraro@apple.com>
2577
2578         dump-class-layout mishandles duplicates base classes and miscomputes padding
2579         https://bugs.webkit.org/show_bug.cgi?id=183311
2580
2581         Reviewed by Simon Fraser.
2582
2583         * Scripts/dump-class-layout:
2584         (verify_type):
2585         (verify_type_recursive):
2586         Keep a list of seen (offset, type) that we have output and don't re-output them.
2587         The Python types list the base classes as members multiple times as you iterate
2588         through the members, so just ignore them if we have seem them already at a
2589         specific offset.
2590
2591 2018-03-05  Carlos Alberto Lopez Perez  <clopez@igalia.com>
2592
2593         [GTK][Wayland] The GTK Wayland bot exits early because of assertions related with libsecret since r221925
2594         https://bugs.webkit.org/show_bug.cgi?id=183330
2595
2596         Reviewed by Michael Catanzaro.
2597
2598         Add libsecret to the JHBuild and build it only when the system version is
2599         less than 0.18.6 (unreleased as of writing this) in order to cherry pick
2600         a fix for a bug that causes crashes with layout tests.
2601
2602         * gtk/jhbuild.modules:
2603         * gtk/patches/libsecret-secret-methods-Don-t-unref-NULL-when-search-fails.patch: Added.
2604
2605 2018-03-05  Claudio Saavedra  <csaavedra@igalia.com>
2606
2607         [GTK] Implement WTR's PlatformWebView::setWindowIsKey()
2608         https://bugs.webkit.org/show_bug.cgi?id=183143
2609
2610         Reviewed by Carlos Garcia Campos.
2611
2612         Implement ::setWindowIsKey() by keeping a second window to be
2613         presented when the webview's window is to lose its key status.
2614
2615         * WebKitTestRunner/PlatformWebView.h:
2616         * WebKitTestRunner/gtk/PlatformWebViewGtk.cpp:
2617         (WTR::PlatformWebView::PlatformWebView):
2618         (WTR::PlatformWebView::~PlatformWebView):
2619         (WTR::PlatformWebView::setWindowIsKey):
2620
2621 2018-03-05  Yusuke Suzuki  <utatane.tea@gmail.com>
2622
2623         Unreviewed, attempt to fix Apple port build
2624
2625         * TestWebKitAPI/Tests/WebKitCocoa/PictureInPictureDelegate.mm:
2626
2627 2018-03-05  Yusuke Suzuki  <utatane.tea@gmail.com>
2628
2629         Unreviewed, attempt to fix WPE build
2630
2631         * WebKitTestRunner/InjectedBundle/wpe/TestRunnerWPE.cpp:
2632         (WTR::TestRunner::initializeWaitToDumpWatchdogTimerIfNeeded):
2633         * WebKitTestRunner/wpe/PlatformWebViewWPE.cpp:
2634         (WTR::PlatformWebView::windowSnapshotImage):
2635         * WebKitTestRunner/wpe/TestControllerWPE.cpp:
2636         (WTR::TestController::platformRunUntil):
2637
2638 2018-03-04  Yusuke Suzuki  <utatane.tea@gmail.com>
2639
2640         [WTF] Move currentCPUTime and sleep(Seconds) to CPUTime.h and Seconds.h respectively
2641         https://bugs.webkit.org/show_bug.cgi?id=183312
2642
2643         Reviewed by Mark Lam.
2644
2645         Remove wtf/CurrentTime.h include pragma.
2646
2647         * DumpRenderTree/TestNetscapePlugIn/PluginTest.cpp:
2648         * DumpRenderTree/TestNetscapePlugIn/Tests/EvaluateJSWithinNPP_New.cpp:
2649         * DumpRenderTree/TestNetscapePlugIn/Tests/InvokeDestroysPluginWithinNPP_New.cpp:
2650         * DumpRenderTree/TestNetscapePlugIn/Tests/SlowNPPNew.cpp:
2651         * TestWebKitAPI/Tests/WTF/Condition.cpp:
2652         * TestWebKitAPI/Tests/WTF/Signals.cpp:
2653         * TestWebKitAPI/Tests/WTF/ThreadGroup.cpp:
2654         * TestWebKitAPI/Tests/WTF/WorkQueue.cpp:
2655         * TestWebKitAPI/Tests/WebKitCocoa/PictureInPictureDelegate.mm:
2656         * TestWebKitAPI/Tests/ios/DataInteractionTests.mm:
2657         * TestWebKitAPI/jsconly/PlatformUtilitiesJSCOnly.cpp:
2658         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
2659
2660 2018-03-04  Tim Horton  <timothy_horton@apple.com>
2661
2662         Make !ENABLE(DATA_DETECTION) iOS build actually succeed
2663         https://bugs.webkit.org/show_bug.cgi?id=183283
2664         <rdar://problem/38062148>
2665
2666         Reviewed by Sam Weinig.
2667
2668         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
2669
2670 2018-03-02  Chris Dumez  <cdumez@apple.com>
2671
2672         Converting a load to a download does not work with async policy delegates
2673         https://bugs.webkit.org/show_bug.cgi?id=183254
2674         <rdar://problem/38035334>
2675
2676         Reviewed by Youenn Fablet.
2677
2678         Add layout test infrastructure for responding to the decidePolicyForNavigationResponse
2679         delegate asynchronously.
2680
2681         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
2682         * WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
2683         (WTR::InjectedBundlePage::decidePolicyForResponse):
2684         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
2685         (WTR::TestRunner::setShouldDecideResponsePolicyAfterDelay):
2686         * WebKitTestRunner/InjectedBundle/TestRunner.h:
2687         (WTR::TestRunner::shouldDecideResponsePolicyAfterDelay const):
2688         * WebKitTestRunner/TestController.cpp:
2689         (WTR::TestController::resetStateToConsistentValues):
2690         (WTR::TestController::decidePolicyForNavigationResponse):
2691         * WebKitTestRunner/TestController.h:
2692         (WTR::TestController::setShouldDecideResponsePolicyAfterDelay):
2693         * WebKitTestRunner/TestInvocation.cpp:
2694         (WTR::TestInvocation::didReceiveMessageFromInjectedBundle):
2695
2696 2018-03-01  Youenn Fablet  <youenn@apple.com>
2697
2698         Add API test to validate setting of service worker and cache storage directories
2699         https://bugs.webkit.org/show_bug.cgi?id=182543
2700
2701         Reviewed by Chris Dumez.
2702
2703         * TestWebKitAPI/Tests/WebKitCocoa/ServiceWorkerBasic.mm:
2704
2705 2018-03-01  Ross Kirsling  <ross.kirsling@sony.com>
2706
2707         [Win][DRT] Implement setSpatialNavigationEnabled.
2708         https://bugs.webkit.org/show_bug.cgi?id=183166
2709
2710         Reviewed by Per Arne Vollan.
2711
2712         * DumpRenderTree/TestRunner.cpp:
2713         (setSpatialNavigationEnabledCallback):
2714         * DumpRenderTree/win/DumpRenderTree.cpp:
2715         (resetWebPreferencesToConsistentValues):
2716         * DumpRenderTree/win/TestRunnerWin.cpp:
2717         (TestRunner::setSpatialNavigationEnabled):
2718
2719 2018-03-01  Basuke Suzuki  <Basuke.Suzuki@sony.com>
2720
2721         [webkitpy] Use shell=False to launch apache http server.
2722         https://bugs.webkit.org/show_bug.cgi?id=183191
2723
2724         Reviewed by Aakash Jain.
2725
2726         * Scripts/webkitpy/layout_tests/servers/apache_http_server.py:
2727         (LayoutTestApacheHttpd.__init__):
2728         (LayoutTestApacheHttpd._run):
2729
2730 2018-03-01  Chris Dumez  <cdumez@apple.com>
2731
2732         Unreviewed, update WebKit.CustomHeaderFields API test after r229133.
2733
2734         We no longer do policy checks for 'about:blank'.
2735
2736         * TestWebKitAPI/Tests/WebKitCocoa/WebsitePolicies.mm:
2737         (-[CustomHeaderFieldsDelegate webView:startURLSchemeTask:]):
2738         (TEST):
2739
2740 2018-02-28  Jonathan Bedard  <jbedard@apple.com>
2741
2742         [webkitpy] Remove concept of 'future' versions (Follow-up fix 2)
2743         https://bugs.webkit.org/show_bug.cgi?id=183184
2744         <rdar://problem/37958594>
2745
2746         Reviewed by Aakash Jain.
2747
2748         Unlisted Apple versions can't run webkitpy tests because they don't
2749         have specified port names.
2750
2751         * Scripts/webkitpy/port/apple.py:
2752         (ApplePort.determine_full_port_name): Return valid port name for unnamed
2753         versions.
2754         * Scripts/webkitpy/port/base.py:
2755         (Port.version_name): Check both public and internal version mapping
2756         when returning a version name.
2757         * Scripts/webkitpy/port/mac.py:
2758         (MacPort.__init__): If no os version is defined, use the current version.
2759
2760 2018-02-28  John Wilander  <wilander@apple.com>
2761
2762         Add a second tier of prevalence to facilitate telemetry on very prevalent domains
2763         https://bugs.webkit.org/show_bug.cgi?id=183218
2764         <rdar://problem/37992388>
2765
2766         Reviewed by Brent Fulgham.
2767
2768         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
2769             Added two new testRunner functions:
2770             - setStatisticsVeryPrevalentResource()
2771             - isStatisticsVeryPrevalentResource()
2772         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
2773         (WTR::TestRunner::setStatisticsVeryPrevalentResource):
2774         (WTR::TestRunner::isStatisticsVeryPrevalentResource):
2775         * WebKitTestRunner/InjectedBundle/TestRunner.h:
2776         * WebKitTestRunner/TestController.cpp:
2777         (WTR::TestController::setStatisticsVeryPrevalentResource):
2778         (WTR::TestController::isStatisticsVeryPrevalentResource):
2779         * WebKitTestRunner/TestController.h:
2780         * WebKitTestRunner/TestInvocation.cpp:
2781         (WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):
2782
2783 2018-02-28  Jonathan Bedard  <jbedard@apple.com>
2784
2785         [webkitpy] Remove concept of 'future' versions (Follow-up fix)
2786         https://bugs.webkit.org/show_bug.cgi?id=183184
2787         <rdar://problem/37958594>
2788
2789         Reviewed by David Kilzer.
2790
2791         The factory also relies on future in a non-obvious way.
2792
2793         * Scripts/webkitpy/common/system/platforminfo.py:
2794         (PlatformInfo.os_version_name): Check both public and internal version mapping
2795         when returning a version name.
2796         * Scripts/webkitpy/common/system/platforminfo_mock.py:
2797         (MockPlatformInfo.os_version_name): Ditto.
2798
2799 2018-02-28  Zan Dobersek  <zdobersek@igalia.com>
2800
2801         Unreviewed WPE fixup after r229080.
2802
2803         Add empty definitions for two AccessibilityUIElement methods,
2804         avoiding undefined symbols in the WKTR injected bundle.
2805
2806         * WebKitTestRunner/InjectedBundle/wpe/AccessibilityUIElementWPE.cpp:
2807         (WTR::AccessibilityUIElement::attributedStringForTextMarkerRange):
2808         (WTR::AccessibilityUIElement::attributedStringForTextMarkerRangeWithOptions):
2809
2810 2018-02-27  Jonathan Bedard  <jbedard@apple.com>
2811
2812         Remove concept of 'future'
2813         https://bugs.webkit.org/show_bug.cgi?id=183184
2814         <rdar://problem/37958594>
2815
2816         Reviewed by Aakash Jain.
2817
2818         Remove concept of 'future' from expectations and instead
2819         use a system of inheritance centered around the current version
2820         of an OS for Mac and iOS.
2821
2822         Inheritance works like so:
2823
2824         | ....
2825         V Future
2826         > High Sierra (mac)
2827         ^ mac-sierra
2828         | mac-elcapitan
2829         | ....
2830
2831         This does not change expectation inheritance for any currently running
2832         configurations, it generalizes the logic already used.
2833
2834         * Scripts/webkitpy/common/version_name_map.py:
2835         (VersionNameMap.__init__): Remove all future versions.
2836         (VersionNameMap.mapping_for_platform): Return empty dicts instead of
2837         asserting.
2838         * Scripts/webkitpy/port/apple.py:
2839         (ApplePort):
2840         (ApplePort._allowed_versions): Return all available versions.
2841         (ApplePort._generate_all_test_configurations): Instead of picking from a set
2842         of allowed versions, assume that every specified version is allowed.
2843         (ApplePort._port_name_with_version): Deleted.
2844         * Scripts/webkitpy/port/darwin.py: Add CURRENT_VERSION overridden by subclasses.
2845         (DarwinPort):
2846         * Scripts/webkitpy/port/ios.py:
2847         (IOSPort):
2848         (IOSPort.default_baseline_search_path): Use system of inheritance centered around
2849         the current version.
2850         * Scripts/webkitpy/port/mac.py:
2851         (MacPort):
2852         (MacPort.__init__): Use current version by default.
2853         (MacPort.default_baseline_search_path): Use system of inheritance centered around
2854         the current version.
2855         (MacPort.configuration_specifier_macros): Use the same set of version names
2856         supported in default_baseline_search_path.
2857         * Scripts/webkitpy/port/mac_unittest.py:
2858         (MacTest.test_versions): Remove 'future' tests.
2859
2860 2018-02-27  Michael Catanzaro  <mcatanzaro@igalia.com>
2861
2862         Unreviewed GTK test gardening
2863
2864         * TestWebKitAPI/glib/TestExpectations.json:
2865
2866 2018-02-27  Doug Russell  <doug@getitdownonpaper.com>
2867
2868         AX: Spell check and style attributes should be optional when fetching attributed string
2869         https://bugs.webkit.org/show_bug.cgi?id=160744
2870
2871         Reviewed by Chris Fleizach.
2872
2873         The overhead of fetching a spell checked attributed string via AX API is substantial. 
2874         In some cases on the order of 7/8 of the total time spent fetching the string.
2875
2876         This change introduces the new attribute AXAttributedStringForTextMarkerRangeWithOptions which accepts an NSDictionary as it's parameter with keys "AXTextMarkerRange" (AXTextMarkerRangeRef) and "AXSpellCheck" (NSNumber(BOOL)).
2877
2878         AXAttributedStringForTextMarkerRange will remain unchanged.
2879
2880         * DumpRenderTree/AccessibilityUIElement.cpp:
2881         (attributedStringForTextMarkerRangeCallback):
2882         (attributedStringForTextMarkerRangeWithOptionsCallback):
2883         (AccessibilityUIElement::attributedStringForTextMarkerRange):
2884         (AccessibilityUIElement::attributedStringForTextMarkerRangeWithOptions):
2885         (AccessibilityUIElement::getJSClass):
2886         * DumpRenderTree/AccessibilityUIElement.h:
2887         * DumpRenderTree/ios/AccessibilityUIElementIOS.mm:
2888         (AccessibilityUIElement::attributedStringForTextMarkerRange):
2889         (AccessibilityUIElement::attributedStringForTextMarkerRangeWithOptions):
2890         * DumpRenderTree/mac/AccessibilityUIElementMac.mm:
2891         (createJSStringRef):
2892         (AccessibilityUIElement::attributedStringForTextMarkerRange):
2893         (AccessibilityUIElement::attributedStringForTextMarkerRangeWithOptions):
2894         * WebKitTestRunner/InjectedBundle/AccessibilityUIElement.h:
2895         * WebKitTestRunner/InjectedBundle/Bindings/AccessibilityUIElement.idl:
2896         * WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
2897         (WTR::AccessibilityUIElement::attributedStringForTextMarkerRange):
2898         (WTR::AccessibilityUIElement::attributedStringForTextMarkerRangeWithOptions):
2899         * WebKitTestRunner/InjectedBundle/ios/AccessibilityUIElementIOS.mm:
2900         (WTR::AccessibilityUIElement::attributedStringForTextMarkerRange):
2901         (WTR::AccessibilityUIElement::attributedStringForTextMarkerRangeWithOptions):
2902         * WebKitTestRunner/InjectedBundle/mac/AccessibilityUIElementMac.mm:
2903         (WTR::createJSStringRef):
2904         (WTR::AccessibilityUIElement::attributedStringForTextMarkerRange):
2905         (WTR::AccessibilityUIElement::attributedStringForTextMarkerRangeWithOptions):
2906
2907 2018-02-27  Daniel Bates  <dabates@apple.com>
2908
2909         Standardize terminology for marked text
2910         https://bugs.webkit.org/show_bug.cgi?id=180999
2911
2912         Reviewed by Zalan Bujtas.
2913
2914         The name MarkerSubrange is a misnomer for a data structure that associates a text subrange with a type
2915         and optional document marker. In particular, a MarkerSubrange may not always correspond to a document
2916         marker. For instance, selected text is represented using a MarkerSubrange that does not have a
2917         corresponding document marker. Let's standardize on the phrase "marked text" as the canonical way to
2918         describe these tagged text subranges.
2919
2920         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
2921         * TestWebKitAPI/Tests/WebCore/MarkedText.cpp: Added.
2922         (WebCore::operator<<):
2923         (TestWebKitAPI::TEST):
2924         * TestWebKitAPI/Tests/WebCore/MarkerSubrange.cpp: Removed.
2925
2926 2018-02-27  Aakash Jain  <aakash_jain@apple.com>
2927
2928         webkitpy Bugzilla transactions should retry on URLError
2929         https://bugs.webkit.org/show_bug.cgi?id=183156
2930
2931         Reviewed by Alexey Proskuryakov.
2932
2933         * Scripts/webkitpy/common/net/bugzilla/bugzilla.py:
2934         (Bugzilla): Use NetworkTransaction.
2935         (Bugzilla._fetch_bug_page_by_url):
2936         (Bugzilla.bug_id_for_attachment_id):
2937         (Bugzilla.get_bug_id_for_attachment_id):
2938
2939 2018-02-27  Wenson Hsieh  <wenson_hsieh@apple.com>
2940
2941         [Extra zoom mode] Implement additional SPI for adjusting viewport shrink-to-fit behavior
2942         https://bugs.webkit.org/show_bug.cgi?id=183100
2943         <rdar://problem/37840987>
2944
2945         Reviewed by Tim Horton.
2946
2947         Add API tests that exercise -_setMinimumAllowedLayoutWidth: and -_setForceHorizontalViewportShrinkToFit:. See
2948         WebKit ChangeLog for more detail.
2949
2950         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
2951         * TestWebKitAPI/Tests/ios/ViewportSizingTests.mm: Added.
2952         (TestWebKitAPI::while):
2953         (viewportTestPageMarkup):
2954         (TestWebKitAPI::TEST):
2955
2956 2018-02-27  Yusuke Suzuki  <utatane.tea@gmail.com>
2957
2958         Unreviewed, skip FTL tests if FTL is disabled
2959         https://bugs.webkit.org/show_bug.cgi?id=183071
2960
2961         * Scripts/run-jsc-stress-tests:
2962
2963 2018-02-26  Don Olmstead  <don.olmstead@sony.com>
2964
2965         Fix WebCore includes within WebKitLegacy
2966         https://bugs.webkit.org/show_bug.cgi?id=183147
2967
2968         Reviewed by Tim Horton.
2969
2970         * MiniBrowser/win/ResourceLoadDelegate.cpp:
2971
2972 2018-02-26  Yousuke Kimoto  <yousuke.kimoto@sony.com>
2973
2974         [WinCairo] WebKit2_C.h should be included for TestWebKit
2975         https://bugs.webkit.org/show_bug.cgi?id=182682
2976
2977         Reviewed by Yusuke Suzuki.
2978
2979         * TestWebKitAPI/config.h:
2980
2981 2018-02-25  Fujii Hironori  <Hironori.Fujii@sony.com>
2982
2983         [WK2] http/tests/navigation/new-window-redirect-history.html crashes
2984         https://bugs.webkit.org/show_bug.cgi?id=127683
2985
2986         Reviewed by Dan Bernstein.
2987
2988         m_previousTestBackForwardListItem was null for the new window.
2989         m_previousTestBackForwardListItem is initialized only for the main
2990         window in InjectedBundlePage::prepare.
2991
2992         * WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
2993         (WTR::InjectedBundlePage::dumpBackForwardList):
2994         Do null-check of m_previousTestBackForwardListItem.
2995
2996 2018-02-25  Alexey Proskuryakov  <ap@apple.com>
2997
2998         Various crashes in WebKitTestRunner, especially when system is under heavy load
2999         https://bugs.webkit.org/show_bug.cgi?id=183109
3000
3001         Reviewed by Tim Horton.
3002
3003         WebKitTestRunner had many places where it sent messages to WebContent with a timeout,
3004         but it didn't handle the timeout when it did occur. Nearly all of those would result
3005         in logic errors and failing tests, and most would even result in stack corruption,
3006         as the response handler modified local variables.
3007
3008         There is only one timeout scenario that we actually mean to handle in WKTR. That's
3009         when a test freezes after it is done (e.g. an infinite loop in beforeunload) - we don't
3010         want to blame the next test for freezing, so we silently relaunch WebContent.
3011         Everything else is cargo cult code that never worked.
3012
3013         This patch addresses the crashes, and actually makes tests pass a lot more on an
3014         overloaded system.
3015
3016         * WebKitTestRunner/TestController.cpp:
3017         (WTR::TestController::resetStateToConsistentValues): Moved m_doneResetting assignment
3018         to where it's actually needed, for clarity.
3019         (WTR::TestController::reattachPageToWebProcess): This function used to always hit
3020         and ignore message timeout, as m_doneResetting is only updated by navigation callback
3021         when the state is Resetting. This change makes it faster.
3022         (WTR::TestController::platformResetStateToConsistentValues): Style fix.
3023         (WTR::TestController::clearServiceWorkerRegistrations): Timing out here wasn't
3024         handled in a meaningful manner, and would even corrupt the stack.
3025         (WTR::TestController::clearDOMCache): Ditto.
3026         (WTR::TestController::clearDOMCaches): Ditto.
3027         (WTR::TestController::hasDOMCache): Ditto.
3028         (WTR::TestController::domCacheSize): Ditto.
3029         (WTR::TestController::isStatisticsPrevalentResource): Ditto.
3030         (WTR::TestController::isStatisticsRegisteredAsSubFrameUnder): Ditto.
3031         (WTR::TestController::isStatisticsRegisteredAsRedirectingTo): Ditto.
3032         (WTR::TestController::isStatisticsHasHadUserInteraction): Ditto.
3033         (WTR::TestController::isStatisticsGrandfathered): Ditto.
3034         (WTR::TestController::statisticsUpdateCookiePartitioning): Ditto.
3035         (WTR::TestController::statisticsSetShouldPartitionCookiesForHost): Ditto.
3036         (WTR::TestController::statisticsClearInMemoryAndPersistentStore): Ditto.
3037         (WTR::TestController::statisticsClearInMemoryAndPersistentStoreModifiedSinceHours): Ditto.
3038         (WTR::TestController::statisticsClearThroughWebsiteDataRemoval): Ditto.
3039
3040         * WebKitTestRunner/TestInvocation.cpp:
3041         (WTR::TestInvocation::shortTimeout const): Made shortTimeout shorter (on a hunch).
3042         (WTR::TestInvocation::invoke): Removed a timeout waiting for initial response. There
3043         is never a logical reason for such a timeout, as we always have a new or responsive
3044         WebContent process here.
3045         (WTR::TestInvocation::dumpResults): Removed another timeout that we don't know how to
3046         properly handle.
3047         (WTR::TestInvocation::didReceiveMessageFromInjectedBundle): Removed assignment to
3048         m_errorMessage, which had no effect in this context.
3049
3050         * WebKitTestRunner/TestInvocation.h: Removed no longer used code.
3051
3052         * WebKitTestRunner/cocoa/TestControllerCocoa.mm:
3053         (WTR::TestController::cocoaResetStateToConsistentValues): Use a named constant for
3054         no timeout.
3055         
3056         * WebKitTestRunner/ios/TestControllerIOS.mm:
3057         (WTR::TestController::platformConfigureViewForTest): Removed a useless timeout.
3058         Not sure if timing out here would corrupt the stack or not, but there is no reason
3059         to impose arbitrary limits on individual steps of a test.
3060
3061         * WebKitTestRunner/mac/TestControllerMac.mm:
3062         (WTR::TestController::platformConfigureViewForTest): Use a named constant for
3063         no timeout.
3064
3065 2018-02-25  Ali Juma  <ajuma@chromium.org>
3066
3067         Unreviewed. Change my status to committer.
3068
3069         * Scripts/webkitpy/common/config/contributors.json:
3070
3071 2018-02-25  Chris Dumez  <cdumez@apple.com>
3072
3073         Service workers do not work well inside Web.app
3074         https://bugs.webkit.org/show_bug.cgi?id=183105
3075         <rdar://problem/37864140>
3076
3077         Reviewed by Youenn Fablet.
3078
3079         Add API test coverage.
3080
3081         * TestWebKitAPI/Tests/WebKitCocoa/ServiceWorkerBasic.mm:
3082
3083 2018-02-25  Aakash Jain  <aakash_jain@apple.com>
3084
3085         [build.webkit.org] unit-tests fail if buildbot 0.8.6p1 is not installed locally
3086         https://bugs.webkit.org/show_bug.cgi?id=183103
3087
3088         Reviewed by Alexey Proskuryakov.
3089
3090         * BuildSlaveSupport/build.webkit.org-config/steps_unittest.py: Removed extra imports.
3091
3092 2018-02-24  Wenson Hsieh  <wenson_hsieh@apple.com>
3093
3094         Unreviewed, fix the TestWebKitAPI build after r228825.
3095
3096         I removed a `>= iOS 11` check in r228825, but forgot that this was also neeed to guard against tvOS and watchOS
3097         builds. This fixes the build by restoring the compile-time guard and also makes it explicit for these platforms.
3098
3099         * TestWebKitAPI/Tests/ios/ActionSheetTests.mm:
3100
3101 2018-02-22  Yusuke Suzuki  <utatane.tea@gmail.com>
3102
3103         Remove currentTime() / currentTimeMS()
3104         https://bugs.webkit.org/show_bug.cgi?id=183052
3105
3106         Reviewed by Mark Lam.
3107
3108         * DumpRenderTree/TestRunner.cpp:
3109         (preciseTimeCallback):
3110         * DumpRenderTree/mac/TestRunnerMac.mm:
3111         (TestRunner::setMockGeolocationPosition):
3112         * TestWebKitAPI/Tests/WTF/Condition.cpp:
3113         * TestWebKitAPI/Tests/WTF/ThreadGroup.cpp:
3114         * TestWebKitAPI/Tests/WTF/WorkQueue.cpp:
3115         * WebKitTestRunner/GeolocationProviderMock.cpp:
3116         (WTR::GeolocationProviderMock::setPosition):
3117         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
3118         (WTR::TestRunner::preciseTime):
3119
3120 2018-02-22  Yusuke Suzuki  <utatane.tea@gmail.com>
3121
3122         Remove sleep(double) and sleepMS(double) interfaces
3123         https://bugs.webkit.org/show_bug.cgi?id=183038
3124
3125         Reviewed by Mark Lam.
3126
3127         * DumpRenderTree/TestNetscapePlugIn/PluginTest.cpp:
3128         (PluginTest::indicateTestFailure):
3129         * DumpRenderTree/TestNetscapePlugIn/Tests/EvaluateJSWithinNPP_New.cpp:
3130         (EvaluteJSWithinNPP_New::NPP_New):
3131         * DumpRenderTree/TestNetscapePlugIn/Tests/InvokeDestroysPluginWithinNPP_New.cpp:
3132         (InvokeDestroysPluginWithinNPP_New::NPP_New):
3133         * DumpRenderTree/TestNetscapePlugIn/Tests/SlowNPPNew.cpp:
3134         * TestWebKitAPI/Tests/WTF/Signals.cpp:
3135         (TEST):
3136         * TestWebKitAPI/Tests/WTF/ThreadGroup.cpp:
3137         (TestWebKitAPI::testThreadGroup):
3138         * TestWebKitAPI/Tests/WTF/WorkQueue.cpp:
3139         (TestWebKitAPI::TEST):
3140         * TestWebKitAPI/Tests/WebKitCocoa/PictureInPictureDelegate.mm:
3141         (TestWebKitAPI::TEST):
3142         * TestWebKitAPI/Tests/ios/DataInteractionTests.mm:
3143         (TestWebKitAPI::TEST):
3144         * TestWebKitAPI/jsconly/PlatformUtilitiesJSCOnly.cpp:
3145         (TestWebKitAPI::Util::sleep):
3146
3147 2018-02-21  Don Olmstead  <don.olmstead@sony.com>
3148
3149         [CMake][Win] Use cmakeconfig.h rather than config.h and Platform.h
3150         https://bugs.webkit.org/show_bug.cgi?id=182883
3151
3152         Reviewed by Per Arne Vollan.
3153
3154         * DumpRenderTree/config.h:
3155         * TestWebKitAPI/config.h:
3156
3157 2018-02-21  Michael Catanzaro  <mcatanzaro@igalia.com>
3158
3159         [GTK] Unsafe g_setenv use in MiniBrowser main
3160         https://bugs.webkit.org/show_bug.cgi?id=182978
3161
3162         Reviewed by Carlos Garcia Campos.
3163
3164         setenv (and g_setenv) will randomly crash if called too late.
3165
3166         * MiniBrowser/gtk/main.c:
3167         (main):
3168
3169 2018-02-21  Aakash Jain  <aakash_jain@apple.com>
3170
3171         webkitpy NetworkTransaction should retry on URLError
3172         https://bugs.webkit.org/show_bug.cgi?id=182987
3173
3174         Reviewed by Alexey Proskuryakov.
3175
3176         * Scripts/webkitpy/common/net/networktransaction.py:
3177         (NetworkTransaction.run): Retry on urllib2.URLError.
3178
3179 2018-02-21  Ms2ger  <Ms2ger@igalia.com>
3180
3181         [WTR][WPE] Correct the process names in TestController.
3182         https://bugs.webkit.org/show_bug.cgi?id=178700
3183
3184         Reviewed by Michael Catanzaro.
3185
3186         Similar to r228731 for GTK.
3187
3188         * Scripts/webkitpy/port/wpe.py:
3189         (WPEPort._get_crash_log): removed the code to convert WebProcess name.
3190         * WebKitTestRunner/TestController.cpp: return the correct process names for WPE.
3191         (WTR::TestController::webProcessName):
3192         (WTR::TestController::networkProcessName):
3193         (WTR::TestController::databaseProcessName):
3194
3195 2018-02-21  Ms2ger  <Ms2ger@igalia.com>
3196
3197         [ATK] Remove attributeSet variable from AccessibilityUIElement::attributedStringForRange().
3198         https://bugs.webkit.org/show_bug.cgi?id=183000
3199
3200         Reviewed by Joanmarie Diggs.
3201
3202         It is never initialized, but is passed to atk_attribute_set_free.
3203         This caused a crash in accessibility/content-editable-as-textarea.html on the debug bots.
3204
3205         * WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
3206         (WTR::AccessibilityUIElement::attributedStringForRange):
3207
3208 2018-02-21  Myles C. Maxfield  <mmaxfield@apple.com>
3209
3210         [Cocoa] Make system-ui obey the user-installed-font policy
3211         https://bugs.webkit.org/show_bug.cgi?id=182860
3212         <rdar://problem/36158249>
3213
3214         Reviewed by Antti Koivisto.
3215
3216         Create a font, FakeHelvetica-ArmenianCharacter.ttf, which supports a particular Armenian
3217         character which isn't isn't supported by any other font on the system.
3218
3219         * WebKitTestRunner/FakeHelvetica-ArmenianCharacter.ttf:
3220         * WebKitTestRunner/WebKitTestRunner.xcodeproj/project.pbxproj:
3221
3222 2018-02-20  Timothy Horton  <timothy_horton@apple.com>
3223
3224         Try to fix the 32-bit build after r228857
3225
3226         * WebKitTestRunner/mac/UIScriptControllerMac.mm:
3227         (WTR::UIScriptController::firstResponderSuppressionForWebView):
3228
3229 2018-02-20  Nan Wang  <n_wang@apple.com>
3230
3231         AX: Keyboard focus not following VoiceOver cursor into web content or within web content.
3232         https://bugs.webkit.org/show_bug.cgi?id=182752
3233         <rdar://problem/37518233>
3234
3235         Reviewed by Ryosuke Niwa.
3236
3237         * DumpRenderTree/mac/UIScriptControllerMac.mm:
3238         (WTR::UIScriptController::firstResponderSuppressionForWebView):
3239         (WTR::UIScriptController::makeWindowContentViewFirstResponder):
3240         (WTR::UIScriptController::isWindowContentViewFirstResponder const):
3241         * TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
3242         * TestRunnerShared/UIScriptContext/UIScriptController.cpp:
3243         (WTR::UIScriptController::firstResponderSuppressionForWebView):
3244         (WTR::UIScriptController::makeWindowContentViewFirstResponder):
3245         (WTR::UIScriptController::isWindowContentViewFirstResponder const):
3246         * TestRunnerShared/UIScriptContext/UIScriptController.h:
3247         * WebKitTestRunner/mac/UIScriptControllerMac.mm:
3248         (WTR::UIScriptController::firstResponderSuppressionForWebView):
3249         (WTR::UIScriptController::makeWindowContentViewFirstResponder):
3250         (WTR::UIScriptController::isWindowContentViewFirstResponder const):
3251
3252 2018-02-20  Fujii Hironori  <Hironori.Fujii@sony.com>
3253
3254         [GTK] jhbuild: Remove gtk-doc
3255         https://bugs.webkit.org/show_bug.cgi?id=182956
3256
3257         Reviewed by Michael Catanzaro.
3258
3259         jhbuild doesn't need to build gtk-doc because major LTS Linux
3260         distributions have gtk-doc v1.25, and
3261         Tools/gtk/install-dependencies installs gtk-doc.
3262
3263         * gtk/jhbuild.modules: Removed gtk-doc.
3264
3265 2018-02-20  Tim Horton  <timothy_horton@apple.com>
3266
3267         Introduce HAVE(IOSURFACE_ACCELERATOR)
3268         https://bugs.webkit.org/show_bug.cgi?id=182955
3269         <rdar://problem/37699510>
3270
3271         Reviewed by Sam Weinig.
3272
3273         * DumpRenderTree/ios/PixelDumpSupportIOS.mm:
3274         (createBitmapContextFromWebView):
3275         * WebKitTestRunner/ios/PlatformWebViewIOS.mm:
3276         (WTR::PlatformWebView::windowSnapshotImage):
3277
3278 2018-02-20  Chris Dumez  <cdumez@apple.com>
3279
3280         Provisional load may get committed before receiving the decidePolicyForNavigationResponse response
3281         https://bugs.webkit.org/show_bug.cgi?id=182720
3282         <rdar://problem/37515204>
3283
3284         Reviewed by Alex Christensen.
3285
3286         Add API test coverage.
3287
3288         * TestWebKitAPI/Tests/WebKitCocoa/AsyncPolicyForNavigationResponse.mm:
3289         (-[TestAsyncNavigationDelegate webView:decidePolicyForNavigationResponse:decisionHandler:]):
3290         (TestWebKitAPI::TEST):
3291
3292 2018-02-20  Nan Wang  <n_wang@apple.com>
3293
3294         AX: AOM: Dispatch accessibleclick event
3295         https://bugs.webkit.org/show_bug.cgi?id=180898
3296         <rdar://problem/36086710>
3297
3298         Reviewed by Ryosuke Niwa.
3299
3300         * WebKitTestRunner/InjectedBundle/AccessibilityUIElement.h:
3301         (WTR::AccessibilityUIElement::syncPress):
3302         * WebKitTestRunner/InjectedBundle/Bindings/AccessibilityUIElement.idl:
3303         * WebKitTestRunner/InjectedBundle/mac/AccessibilityUIElementMac.mm:
3304         (WTR::AccessibilityUIElement::syncPress):
3305
3306 2018-02-20  Wenson Hsieh  <wenson_hsieh@apple.com>
3307
3308         [iOS 11.3 Beta] Can't copy a URL from Safari and paste it into the Gmail app
3309         https://bugs.webkit.org/show_bug.cgi?id=182952
3310         <rdar://problem/37636190>
3311
3312         Reviewed by Tim Horton.
3313
3314         Adds a new iOS copy/paste test that copies an anchor element via action sheet, and checks that upon pasting,
3315         both "text/plain" and "text/uri-list" are provided. Additionally tweaks an existing iOS drag and drop test to
3316         check for the same behavior.
3317
3318         * TestWebKitAPI/Tests/ios/ActionSheetTests.mm:
3319         (TestWebKitAPI::TEST):
3320         * TestWebKitAPI/Tests/ios/DataInteractionTests.mm:
3321         (TestWebKitAPI::TEST):
3322
3323 2018-02-20  Philippe Normand  <pnormand@igalia.com>
3324
3325         [GStreamer][MiniBrowser] Honor GStreamer command line parameters in MiniBrowser
3326         https://bugs.webkit.org/show_bug.cgi?id=173655
3327
3328         Reviewed by Xabier Rodriguez-Calvar.
3329
3330         The FIXME in GStreamerUtilities.cpp asks to pass the command line
3331         parameters to the GStreamer initialization function.
3332
3333         Based on initial patch by: Vanessa Chipirrás Navalón  <vchipirras@igalia.com>
3334
3335         * MiniBrowser/gtk/main.c:
3336         (main): Add the group containing the Gstreamer options that the console displays.
3337
3338 2018-02-19  Fujii Hironori  <Hironori.Fujii@sony.com>
3339
3340         [WTR][GTK] crash log backtrace doesn't show symbol names for DatabaseProcess and NetworkProcess
3341         https://bugs.webkit.org/show_bug.cgi?id=182953
3342
3343         Reviewed by Carlos Garcia Campos.
3344
3345         * Scripts/webkitpy/port/gtk.py:
3346         (GtkPort._get_crash_log): Removed the code to convert WebProcess name.
3347         * WebKitTestRunner/TestController.cpp:
3348         (WTR::TestController::webProcessName): Return the correct program name for GTK+ port.
3349         (WTR::TestController::networkProcessName): Ditto.
3350         (WTR::TestController::databaseProcessName): Ditto.
3351
3352 2018-02-19  Ryan Haddad  <ryanhaddad@apple.com>
3353
3354         Unreviewed, rolling out r228696.
3355
3356         The API test added with this change is timing out on macOS.
3357
3358         Reverted changeset:
3359
3360         "Null pointer dereference in
3361         WebPageProxy::urlSchemeHandlerForScheme()"
3362         https://bugs.webkit.org/show_bug.cgi?id=182905
3363         https://trac.webkit.org/changeset/228696
3364
3365 2018-02-16  Ryosuke Niwa  <rniwa@webkit.org>
3366
3367         Add an entitlement check for service worker on iOS
3368         https://bugs.webkit.org/show_bug.cgi?id=182865
3369         <rdar://problem/37505903>
3370
3371         Reviewed by Brady Eidson.
3372
3373         Added the service worker entitlements to WebKitTestRunner and TestWebKitAPI on iOS.
3374
3375         * TestWebKitAPI/Configurations/TestWebKitAPI-iOS.entitlements:
3376         * WebKitTestRunner/Configurations/WebKitTestRunnerApp-iOS.entitlements:
3377         * WebKitTestRunner/Configurations/WebKitTestRunnerApp.xcconfig:
3378         * WebKitTestRunner/WebKitTestRunner.xcodeproj/project.pbxproj:
3379
3380 2018-02-16  Youenn Fablet  <youenn@apple.com>
3381
3382         Allow specifying which plug-ins are supported
3383         https://bugs.webkit.org/show_bug.cgi?id=182748
3384
3385         Reviewed by Chris Dumez.
3386
3387         Add support for a test runner API to specificy supported plug-ins.
3388
3389         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
3390         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
3391         (WTR::TestRunner::setPluginsAsUnsupported):
3392         * WebKitTestRunner/InjectedBundle/TestRunner.h:
3393         * WebKitTestRunner/TestController.cpp:
3394         (WTR::TestController::resetStateToConsistentValues):
3395         (WTR::TestController::setPluginsAsUnsupported):
3396         * WebKitTestRunner/TestController.h:
3397         * WebKitTestRunner/TestInvocation.cpp:
3398         (WTR::TestInvocation::didReceiveMessageFromInjectedBundle):
3399
3400 2018-02-16  Per Arne Vollan  <pvollan@apple.com>
3401
3402         Implement stopping of run loop in the WebContent process when using NSRunLoop.
3403         https://bugs.webkit.org/show_bug.cgi?id=182499
3404         <rdar://problem/37247424>
3405
3406         Reviewed by Brent Fulgham.
3407
3408         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
3409         * TestWebKitAPI/Tests/WebKitCocoa/WebProcessTerminate.mm: Added.
3410         (TEST):
3411
3412 2018-02-15  Alexey Proskuryakov  <ap@apple.com>
3413
3414         Speed up dSYM generation on build.webkit.org with -gline-tables-only
3415         https://bugs.webkit.org/show_bug.cgi?id=182841
3416         rdar://problem/34579649
3417
3418         Reviewed by Aakash Jain.
3419
3420         Build speed and binary size improvements are so substantial that I'm willing to make
3421         CI builds less suitable for debugging, which is not a common scenario anyway.
3422         Crash logs will still have line numbers in them.
3423
3424         * BuildSlaveSupport/build.webkit.org-config/steps.py: (CompileWebKit.start):
3425
3426 2018-02-15  Don Olmstead  <don.olmstead@sony.com>
3427
3428         WebCore headers should not be included relatively within dependent projects
3429         https://bugs.webkit.org/show_bug.cgi?id=182805
3430
3431         Reviewed by Chris Dumez.
3432
3433         * TestWebKitAPI/win/TestWebCoreStubs.cpp:
3434         * WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
3435         * WebKitTestRunner/InjectedBundle/wpe/AccessibilityControllerWPE.cpp:
3436         * WebKitTestRunner/InjectedBundle/wpe/AccessibilityUIElementWPE.cpp:
3437         * WebKitTestRunner/gtk/EventSenderProxyGtk.cpp:
3438         * WebKitTestRunner/wpe/EventSenderProxyWPE.cpp:
3439
3440 2018-02-15  Tomas Popela  <tpopela@redhat.com>
3441
3442         run-jsc-stress-tests - skip a test if any of the run commands evals to skip
3443         https://bugs.webkit.org/show_bug.cgi?id=182729
3444
3445         If multiple run commands are specified and one of them evals to skip,
3446         then the test is not skipped, because the run is scheduled while
3447         evaluating other commands.
3448
3449         Remember if the test is going to be skipped - if yes, just stop
3450         evaluating the other run commands.
3451
3452         Reviewed by Saam Barati.
3453
3454         * Scripts/run-jsc-stress-tests:
3455
3456 2018-02-14  Charlie Turner  <cturner@igalia.com>
3457
3458         Get Garden-O-Matic running again.
3459         https://bugs.webkit.org/show_bug.cgi?id=179089
3460
3461         Reviewed by Carlos Alberto Lopez Perez.
3462
3463         * BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/Trac.js:
3464         (parseCommitData): Author field is not always spelled 'author' these days.
3465         * BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/config.js:
3466         No longer have a 32-bit builder.
3467         * BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/scripts/ui/perf.js:
3468         (ui.perf.View.base.init): createElement has a required parameter these days.
3469         * Scripts/webkitpy/tool/commands/gardenomatic.py:
3470         (GardenOMatic): Override use_globs so that platform lookup in config.js works.
3471
3472 2018-02-14  Don Olmstead  <don.olmstead@sony.com>
3473
3474         Remove unused ForwardingHeaders directories from Tools
3475         https://bugs.webkit.org/show_bug.cgi?id=182813
3476
3477         Reviewed by Konstantin Tokarev.
3478
3479         * DumpRenderTree/ForwardingHeaders/runtime/ArrayBufferView.h: Removed.
3480         * DumpRenderTree/ForwardingHeaders/runtime/JSArrayBufferView.h: Removed.
3481         * DumpRenderTree/ForwardingHeaders/runtime/JSExportMacros.h: Removed.
3482         * DumpRenderTree/ForwardingHeaders/runtime/TypedArrayInlines.h: Removed.
3483         * TestWebKitAPI/ForwardingHeaders/WebCore/LayoutUnit.h: Removed.
3484
3485 2018-02-14  Daniel Bates  <dabates@apple.com>
3486
3487         Disallow cross-origin subresources from asking for credentials
3488         https://bugs.webkit.org/show_bug.cgi?id=182579
3489         <rdar://problem/36162271>
3490
3491         Reviewed by Andy Estes.
3492
3493         Add test option allowCrossOriginSubresourcesToAskForCredential (defaults to false)
3494         so that tests can toggle between the old behavior and new behavior.
3495
3496         * DumpRenderTree/TestOptions.h:
3497         * DumpRenderTree/TestOptions.mm:
3498         (TestOptions::TestOptions):
3499         * DumpRenderTree/mac/DumpRenderTree.mm:
3500         (setWebPreferencesForTestOptions):
3501         * WebKitTestRunner/TestController.cpp:
3502         (WTR::TestController::resetPreferencesToConsistentValues):
3503         (WTR::updateTestOptionsFromTestHeader):
3504         * WebKitTestRunner/TestOptions.h:
3505         (WTR::TestOptions::hasSameInitializationOptions const):
3506
3507 2018-02-12  Ryosuke Niwa  <rniwa@webkit.org>
3508
3509         REGRESSION (r223440): Copying & pasting a list from Microsoft Word to TinyMCE fails
3510         https://bugs.webkit.org/show_bug.cgi?id=182564
3511
3512         Reviewed by Wenson Hsieh.
3513
3514         Updated assertions to make sure the trailing "}" of @list rules is includd in the style, the "style" element
3515         is wrapped by "head" element (not present in the pasted markup since the fragment parsing algorithm strips away),
3516         and the style content is enclosed in "<!--" and "-->".
3517
3518         Also use execCommand('insertHTML', ~) to insert the HTML obtained via dataTransfer.getData instead of innerHTML
3519         to make sure our pasting code preserves the special style element for MSO list quirks.
3520
3521         Finally, added two more test cases for pasting content from Microsoft Word's compatibility mode.
3522
3523         * TestWebKitAPI/Tests/WebKitCocoa/PasteHTML.mm:
3524         (TEST):
3525         * TestWebKitAPI/Tests/WebKitCocoa/PasteWebArchive.mm:
3526         (TEST):
3527
3528 2018-02-14  Ross Kirsling  <ross.kirsling@sony.com>
3529
3530         [Tools] --wincairo should imply --64-bit by default.
3531         https://bugs.webkit.org/show_bug.cgi?id=182753
3532
3533         Reviewed by Daniel Bates.
3534
3535         WinCairo does not currently support 32-bit and `--wincairo` itself should refer to a working platform.
3536         This patch ensures x64 is determined correctly for `build-webkit --no-ninja` and `run-webkit-tests`.
3537
3538         * Scripts/webkitdirs.pm:
3539         (determinePassedArchitecture):
3540         (shouldBuild32Bit):
3541         (determineShouldBuild32Bit):
3542         (determineIsWin64):
3543         * Scripts/webkitpy/common/config/ports.py:
3544         (WinCairoPort.build_webkit_command):
3545         * Scripts/webkitpy/common/config/ports_unittest.py:
3546         (DeprecatedPortTest.test_wincairo_port):
3547         * Scripts/webkitpy/port/win.py:
3548         (WinCairoPort):
3549
3550 2018-02-13  Commit Queue  <commit-queue@webkit.org>
3551
3552         Unreviewed, rolling out r228431.
3553         https://bugs.webkit.org/show_bug.cgi?id=182766
3554
3555         Regressed CMake build stability (Requested by dolmstead on
3556         #webkit).
3557
3558         Reverted changeset:
3559
3560         "[CMake] Make WebCore headers copies"
3561         https://bugs.webkit.org/show_bug.cgi?id=182512
3562         https://trac.webkit.org/changeset/228431
3563
3564 2018-02-13  Don Olmstead  <don.olmstead@sony.com>
3565
3566         [CMake] Make WebCore headers copies
3567         https://bugs.webkit.org/show_bug.cgi?id=182512
3568
3569         Reviewed by Keith Miller.
3570
3571         * DumpRenderTree/CMakeLists.txt:
3572         * DumpRenderTree/TestNetscapePlugIn/CMakeLists.txt:
3573         * DumpRenderTree/TestNetscapePlugIn/ForwardingHeaders/WebKit/npapi.h:
3574         * DumpRenderTree/TestNetscapePlugIn/ForwardingHeaders/WebKit/npfunctions.h:
3575         * DumpRenderTree/TestNetscapePlugIn/ForwardingHeaders/WebKit/npruntime.h:
3576         * TestWebKitAPI/PlatformGTK.cmake:
3577         * TestWebKitAPI/PlatformWPE.cmake:
3578         * TestWebKitAPI/PlatformWin.cmake:
3579         * TestWebKitAPI/win/TestWebCoreStubs.cpp:
3580         (loadResourceIntoBuffer):
3581         * WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
3582         * WebKitTestRunner/InjectedBundle/wpe/AccessibilityControllerWPE.cpp:
3583         * WebKitTestRunner/InjectedBundle/wpe/AccessibilityUIElementWPE.cpp:
3584         * WebKitTestRunner/gtk/EventSenderProxyGtk.cpp:
3585         * WebKitTestRunner/wpe/EventSenderProxyWPE.cpp:
3586
3587 2018-02-13  Chris Dumez  <cdumez@apple.com>
3588
3589         REGRESSION (r228299): Broke reader mode in Safari
3590         https://bugs.webkit.org/show_bug.cgi?id=182697
3591         <rdar://problem/37399012>
3592
3593         Reviewed by Ryosuke Niwa.
3594
3595         Add API test coverage for responding asynchronously to the decidePolicyForNavigationResponse
3596         delegate.
3597
3598         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
3599         * TestWebKitAPI/Tests/WebKitCocoa/AsyncPolicyForNavigationResponse.mm: Added.
3600         (-[TestAsyncNavigationDelegate webView:didFinishNavigation:]):
3601         (-[TestAsyncNavigationDelegate webView:didFailNavigation:withError:]):
3602         (-[TestAsyncNavigationDelegate webView:didFailProvisionalNavigation:withError:]):
3603         (-[TestAsyncNavigationDelegate webView:decidePolicyForNavigationAction:decisionHandler:]):
3604         (-[TestAsyncNavigationDelegate webView:decidePolicyForNavigationResponse:decisionHandler:]):
3605         (TestWebKitAPI::TEST):
3606