webkitpy: Use correct config for --iphone-simulator and --ipad-simulator
[WebKit-https.git] / Tools / ChangeLog
1 2019-01-23  Jonathan Bedard  <jbedard@apple.com>
2
3         webkitpy: Use correct config for --iphone-simulator and --ipad-simulator
4         https://bugs.webkit.org/show_bug.cgi?id=193722
5         <rdar://problem/47481475>
6
7         Reviewed by Lucas Forschler.
8
9         iPhone and iPad ports should both use the iOS config.
10
11         * Scripts/webkitpy/port/ios_simulator.py:
12         (IPhoneSimulatorPort.__init__):
13         (IPadSimulatorPort.__init__):
14
15 2019-01-23  Rob Buis  <rbuis@igalia.com>
16
17         Update MIME type parser
18         https://bugs.webkit.org/show_bug.cgi?id=180526
19
20         Reviewed by Frédéric Wang.
21
22         Add unit tests for both parse modes of ParsedContentType.
23
24         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
25         * TestWebKitAPI/Tests/WebCore/ParsedContentType.cpp: Added.
26         (TestWebKitAPI::TEST):
27
28 2019-01-22  Aakash Jain  <aakash_jain@apple.com>
29
30         [ews-app] fetch loop should not stop on network issues
31         https://bugs.webkit.org/show_bug.cgi?id=193666
32
33         Reviewed by Lucas Forschler.
34
35         * BuildSlaveSupport/ews-app/ews/fetcher.py:
36         (FetchLoop.run): Ensure that fetch loop doesn't exit on any exception.
37
38 2019-01-22  Wenson Hsieh  <wenson_hsieh@apple.com>
39
40         [iOS] Multiple WKWebViewAutofillTests are flaky failures
41         https://bugs.webkit.org/show_bug.cgi?id=189165
42         <rdar://problem/47433765>
43
44         Reviewed by Tim Horton.
45
46         These tests are currently flaky because they expect an invocation of "Element.blur()" in the web process to
47         immediately dispatch an IPC message to notify the UI process that the element has been blurred. In particular,
48         the -textInputHasAutofillContext helper assumes that waiting for the next remote layer tree commit in the UI
49         process in sufficient to ensure that any previous action that blurred the focused element in the web process
50         would make its way to the UI process by the time the layer tree commit is finished.
51
52         However, WebPage::elementDidBlur sends its IPC message to the UI process asynchronously, using callOnMainThread.
53         This means that if a layer tree flush was already scheduled in the web process before the element was blurred,
54         the element blur IPC message to the UI process will lose the race against the layer tree commit, and the test
55         will fail because it asks for -_autofillContext too early.
56
57         To fix this, we tweak these tests to actually wait until the intended input session change triggered by script
58         is handled in the UI process.
59
60         * TestWebKitAPI/Tests/ios/WKWebViewAutofillTests.mm:
61
62         Tweak some of these tests to wait for input session changes before checking for the presence of an autofill
63         context. The only exception is an existing test that doesn't allow programmatic focus to begin input sessions
64         by default; to fix this test, we simply wait for _WKInputDelegate to be invoked, instead of waiting for a new
65         input session.
66
67         (-[AutofillTestView textInputHasAutofillContext]):
68
69         Remove the incorrect presentation update here. This helper now assumes that the UI process is up to date.
70
71         * TestWebKitAPI/cocoa/TestWKWebView.h:
72         * TestWebKitAPI/cocoa/TestWKWebView.mm:
73         (nextInputSessionChangeCount):
74
75         Monotonically increasing identifier that's incremented whenever an input session is started in the UI process.
76         This includes changing the focused element from one to another.
77
78         (-[TestWKWebView initWithFrame:configuration:addToWindow:]):
79         (-[TestWKWebView didStartFormControlInteraction]):
80         (-[TestWKWebView didEndFormControlInteraction]):
81         (-[TestWKWebView evaluateJavaScriptAndWaitForInputSessionToChange:]):
82
83         Add a helper to evaluate JavaScript and wait for this script to cause some change in the input session. This
84         handles three cases: (1) changing focus from an element that doesn't require an input session to one that does,
85         (2) changing focus between elements that require input sessions, and (3) changing focus from an input session
86         that doesn't require an input session to one that doesn't.
87
88 2019-01-22  David Kilzer  <ddkilzer@apple.com>
89
90         check-webkit-style reports false-positive whitespace/init warning in C++ initialization parameters
91         <https://webkit.org/b/193676>
92
93         Reviewed by Alexey Proskuryakov.
94
95         * Scripts/webkitpy/style/checkers/cpp.py:
96         (check_member_initialization_list):
97         - Don't report missing whitespace around colon if the colon at
98           the start of the line is formatted correctly.
99         * Scripts/webkitpy/style/checkers/cpp_unittest.py:
100         (WebKitStyleTest.test_member_initialization_list):
101         - Add a test for a missing permutation of existing tests.
102         - Add a test this false-positive.
103         - Add blank lines between subtests to make them easier to read.
104
105 2019-01-22  Aakash Jain  <aakash_jain@apple.com>
106
107         [build.webkit.org] Unit-test failure after r237113
108         https://bugs.webkit.org/show_bug.cgi?id=193669
109
110         Reviewed by Michael Catanzaro.
111
112         * BuildSlaveSupport/build.webkit.org-config/factories.py:
113         (Factory.__init__): Properly check for --no-experimental-features flag when additionalArguments has 
114         multiple or zero flags.
115
116 2019-01-22  Tadeu Zagallo  <tzagallo@apple.com>
117
118         Cache bytecode to disk
119         https://bugs.webkit.org/show_bug.cgi?id=192782
120         <rdar://problem/46084932>
121
122         Reviewed by Keith Miller.
123
124         Add test helper to execute bytecode-cache tests: it executes each test
125         twice, the first with JSC_diskCachePath set to a temporary directory
126         and second with JSC_forceDiskCache=true (in addition to the cache path)
127         to guarantee that only the disk cache is being used and no new
128         UnlinkedCodeBlocks are being created.
129
130         * Scripts/jsc-stress-test-helpers/bytecode-cache-test-helper.sh: Added.
131         * Scripts/run-jsc-stress-tests:
132
133 2019-01-22  Oriol Brufau  <obrufau@igalia.com>
134
135         [css-logical] Implement flow-relative margin, padding and border shorthands
136         https://bugs.webkit.org/show_bug.cgi?id=188697
137
138         Reviewed by Simon Fraser and Antti Koivisto.
139
140         * DumpRenderTree/TestOptions.cpp:
141         (TestOptions::TestOptions):
142         * DumpRenderTree/TestOptions.h:
143         * DumpRenderTree/mac/DumpRenderTree.mm:
144         (setWebPreferencesForTestOptions):
145         Allow tests to enable the CSSLogicalEnabled flag in WK1.
146
147         * Scripts/webkitpy/style/checkers/jsonchecker.py:
148         (JSONCSSPropertiesChecker.check_codegen_properties):
149         Allow CSS property definitions to have a 'runtime-flag' parameter which
150         disables the property when the specified runtime flag is disabled.
151
152 2019-01-21  Fujii Hironori  <Hironori.Fujii@sony.com>
153
154         [GTK][WPE] libgcrypt-1.7.6 can't be compiled on Ubuntu 18.10
155         https://bugs.webkit.org/show_bug.cgi?id=193643
156
157         Reviewed by Michael Catanzaro.
158
159         * gtk/jhbuild.modules: Bumped to libgcrypt-1.8.4.
160         * wpe/jhbuild.modules: Ditto.
161
162 2019-01-21  Zalan Bujtas  <zalan@apple.com>
163
164         [LFC][Floats] Take float top position into account when computing containing block height.
165         https://bugs.webkit.org/show_bug.cgi?id=193655
166
167         Reviewed by Antti Koivisto.
168
169         * LayoutReloaded/misc/LFC-passing-tests.txt:
170
171 2019-01-21  David Kilzer  <ddkilzer@apple.com>
172
173         Switch remaining VideoToolbox soft-linking in WebCore over to VideoToolboxSoftLink.{cpp,h}
174         <https://webkit.org/b/193645>
175         <rdar://problem/47421574>
176
177         Reviewed by Alex Christensen.
178
179         - Now checks for local soft-linking of all frameworks that have
180           their own *SoftLinking.{cpp,h,mm} files.
181         - Changes softlink/uikit warning to softlink/framework.
182
183         * Scripts/webkitpy/style/checkers/cpp.py:
184         (check_language):
185         (CppChecker):
186         * Scripts/webkitpy/style/checkers/cpp_unittest.py:
187         (CppStyleTest):
188
189 2019-01-20  Saam Barati  <sbarati@apple.com>
190
191         Rollout r240210: It broke tests on iOS
192         https://bugs.webkit.org/show_bug.cgi?id=193640
193
194         Unreviewed.
195
196         * Scripts/jsc-stress-test-helpers/bytecode-cache-test-helper:
197         * Scripts/run-jsc-stress-tests:
198
199 2019-01-20  chris fleizach  <cfleizach@apple.com>
200
201         AX: Support returning relative frames for accessibility
202         https://bugs.webkit.org/show_bug.cgi?id=193414
203         <rdar://problem/47268501>
204
205         Reviewed by Zalan Bujtas.
206
207         * WebKitTestRunner/InjectedBundle/AccessibilityUIElement.h:
208         * WebKitTestRunner/InjectedBundle/Bindings/AccessibilityUIElement.idl:
209         * WebKitTestRunner/InjectedBundle/ios/AccessibilityUIElementIOS.mm:
210         (WTR::AccessibilityUIElement::stringDescriptionOfAttributeValue):
211         * WebKitTestRunner/InjectedBundle/mac/AccessibilityUIElementMac.mm:
212         (WTR::attributesOfElement):
213         (WTR::AccessibilityUIElement::stringDescriptionOfAttributeValue):
214
215 2019-01-20  Yusuke Suzuki  <ysuzuki@apple.com>
216
217         Unreviewed, add my new email address
218
219         * Scripts/webkitpy/common/config/contributors.json:
220
221 2019-01-19  Zalan Bujtas  <zalan@apple.com>
222
223         [LFC][BFC] <body>'s overflow property value is propagated to viewport
224         https://bugs.webkit.org/show_bug.cgi?id=193617
225
226         Reviewed by Antti Koivisto.
227
228         * LayoutReloaded/misc/LFC-passing-tests.txt:
229
230 2019-01-20  Michael Catanzaro  <mcatanzaro@igalia.com>
231
232         Unreviewed, rolling out r240209.
233
234         Broke GTK/WPE injected bundle
235
236         Reverted changeset:
237
238         "AX: Support returning relative frames for accessibility"
239         https://bugs.webkit.org/show_bug.cgi?id=193414
240         https://trac.webkit.org/changeset/240209
241
242 2019-01-12  Dan Bernstein  <mitz@apple.com>
243
244         [Cocoa] Avoid importing directly from subumbrella frameworks
245         https://bugs.webkit.org/show_bug.cgi?id=186016
246         <rdar://problem/40591038>
247
248         Reviewed by Sam Weinig.
249
250         * DumpRenderTree/cg/PixelDumpSupportCG.cpp: Include CoreServices.h instead of a
251           LaunchServices header.
252         * DumpRenderTree/mac/Configurations/BaseTarget.xcconfig: Removed -iframework options from
253           OTHER_CFLAGS and OTHER_CPLUSPLUSFLAGS.
254         * DumpRenderTree/mac/LayoutTestHelper.m: Import ApplicationServices.h instead of ColorSync.h
255           when using SDKs earlier than 10.13.
256         * TestWebKitAPI/Configurations/Base.xcconfig: Removed -iframework options from OTHER_CFLAGS
257           and OTHER_CPLUSPLUSFLAGS.
258         * WebKitTestRunner/Configurations/BaseTarget.xcconfig: Removed -iframework options from
259           OTHER_CFLAGS and OTHER_CPLUSPLUSFLAGS.
260         * WebKitTestRunner/cg/TestInvocationCG.cpp: Include CoreServices.h instead of a
261           LaunchServices header.
262
263 2019-01-20  Tadeu Zagallo  <tzagallo@apple.com>
264
265         Cache bytecode to disk
266         https://bugs.webkit.org/show_bug.cgi?id=192782
267         <rdar://problem/46084932>
268
269         Reviewed by Keith Miller.
270
271         Add test helper to execute bytecode-cache tests: it executes each test
272         twice, the first with JSC_diskCachePath set to a temporary directory
273         and second with JSC_forceDiskCache=true (in addition to the cache path)
274         to guarantee that only the disk cache is being used and no new
275         UnlinkedCodeBlocks are being created.
276
277         * Scripts/jsc-stress-test-helpers/bytecode-cache-test-helper: Added.
278         * Scripts/run-jsc-stress-tests:
279
280 2019-01-20  chris fleizach  <cfleizach@apple.com>
281
282         AX: Support returning relative frames for accessibility
283         https://bugs.webkit.org/show_bug.cgi?id=193414
284         <rdar://problem/47268501>
285
286         Reviewed by Zalan Bujtas.
287
288         * WebKitTestRunner/InjectedBundle/AccessibilityUIElement.h:
289         * WebKitTestRunner/InjectedBundle/Bindings/AccessibilityUIElement.idl:
290         * WebKitTestRunner/InjectedBundle/ios/AccessibilityUIElementIOS.mm:
291         (WTR::AccessibilityUIElement::stringDescriptionOfAttributeValue):
292         * WebKitTestRunner/InjectedBundle/mac/AccessibilityUIElementMac.mm:
293         (WTR::attributesOfElement):
294         (WTR::AccessibilityUIElement::stringDescriptionOfAttributeValue):
295
296 2019-01-20  Antoine Quint  <graouts@apple.com>
297
298         Add a POINTER_EVENTS feature flag
299         https://bugs.webkit.org/show_bug.cgi?id=193577
300         <rdar://problem/47408511>
301
302         Unreviewed. Also enable Pointer Events for iosmac.
303
304         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
305
306 2019-01-19  Zalan Bujtas  <zalan@apple.com>
307
308         [LFC][Floats] Ensure that floats in FloatingContext::m_floats are always horizontally ordered.
309         https://bugs.webkit.org/show_bug.cgi?id=193613
310
311         Reviewed by Antti Koivisto.
312
313         * LayoutReloaded/misc/LFC-passing-tests.txt:
314
315 2019-01-19  Antoine Quint  <graouts@apple.com>
316
317         Add a POINTER_EVENTS feature flag
318         https://bugs.webkit.org/show_bug.cgi?id=193577
319
320         Reviewed by Dean Jackson.
321
322         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
323
324 2019-01-18  Zhifei FANG  <zhifei_fang@apple.com>
325
326         Disable the run-jsc-stress-test remote host key check [second round].
327         https://bugs.webkit.org/show_bug.cgi?id=192988
328
329         Reviewed by Dewei Zhu.
330
331         * Scripts/run-jsc-stress-tests:
332
333 2019-01-18  Aakash Jain  <aakash_jain@apple.com>
334
335         [build.webkit.org] unit-test failure Builder GTK Linux 32-bit Release doesn't exist
336         https://bugs.webkit.org/show_bug.cgi?id=193597
337
338         Reviewed by Lucas Forschler.
339
340         * BuildSlaveSupport/build.webkit.org-config/steps_unittest.py:
341
342 2019-01-18  Aakash Jain  <aakash_jain@apple.com>
343
344         [build.webkit.org] api tests failures are incorrectly named as unit test failures
345         https://bugs.webkit.org/show_bug.cgi?id=193595
346
347         Reviewed by Lucas Forschler.
348
349         * BuildSlaveSupport/build.webkit.org-config/factories.py: Renamed RunUnitTests to RunAPITests.
350         * BuildSlaveSupport/build.webkit.org-config/steps.py: Ditto.
351         * BuildSlaveSupport/build.webkit.org-config/steps_unittest.py: Ditto.
352
353 2019-01-18  Chris Dumez  <cdumez@apple.com>
354
355         Regression(PSON) Content blockers are sometimes lost on back navigation cross-site
356         https://bugs.webkit.org/show_bug.cgi?id=193588
357         <rdar://problem/47131566>
358
359         Reviewed by Alex Christensen.
360
361         Add layout test coverage.
362
363         * TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
364
365 2019-01-18  Jer Noble  <jer.noble@apple.com>
366
367         SDK_VARIANT build destinations should be separate from non-SDK_VARIANT builds
368         https://bugs.webkit.org/show_bug.cgi?id=189553
369
370         Reviewed by Tim Horton.
371
372         Add a check-webkit-style check that ensures all SDKVariant.xcconfig files match.
373
374         * ContentExtensionTester/Configurations/Base.xcconfig:
375         * ContentExtensionTester/Configurations/SDKVariant.xcconfig: Added.
376         * DumpRenderTree/mac/Configurations/Base.xcconfig:
377         * DumpRenderTree/mac/Configurations/SDKVariant.xcconfig: Added.
378         * ImageDiff/cg/Configurations/Base.xcconfig:
379         * ImageDiff/cg/Configurations/SDKVariant.xcconfig: Added.
380         * MiniBrowser/Configurations/Base.xcconfig:
381         * MiniBrowser/Configurations/SDKVariant.xcconfig: Added.
382         * MobileMiniBrowser/Configurations/Base.xcconfig:
383         * MobileMiniBrowser/Configurations/SDKVariant.xcconfig: Added.
384         * Scripts/webkitpy/style/checker.py:
385         (_all_categories):
386         (FileType):
387         (CheckerDispatcher._file_type):
388         (CheckerDispatcher._create_checker):
389         * Scripts/webkitpy/style/checkers/sdkvariant.py: Added.
390         (SDKVariantChecker):
391         (SDKVariantChecker.__init__):
392         (SDKVariantChecker.check):
393         * TestWebKitAPI/Configurations/Base.xcconfig:
394         * TestWebKitAPI/Configurations/SDKVariant.xcconfig: Added.
395         * WebEditingTester/Configurations/Base.xcconfig:
396         * WebEditingTester/Configurations/SDKVariant.xcconfig: Added.
397         * WebKitLauncher/Configurations/SDKVariant.xcconfig: Added.
398         * WebKitTestRunner/Configurations/Base.xcconfig:
399         * WebKitTestRunner/Configurations/SDKVariant.xcconfig: Added.
400         * lldb/lldbWebKitTester/Configurations/Base.xcconfig:
401         * lldb/lldbWebKitTester/Configurations/SDKVariant.xcconfig: Added.
402
403 2019-01-18  David Kilzer  <ddkilzer@apple.com>
404
405         Switch remaining UIKit soft-linking in WebCore, WebKitLegacy over to UIKitSoftLink.{cpp,h}
406         <https://webkit.org/b/193568>
407         <rdar://problem/47381130>
408
409         Reviewed by Alex Christensen.
410
411         Make sure no one re-introduces UIKit soft-linking by adding a
412         style rule.
413
414         * Scripts/webkitpy/style/checkers/cpp.py:
415         (check_language): Add softlink/uikit check.
416         (CppChecker): Enable softlink/uikit check.
417         * Scripts/webkitpy/style/checkers/cpp_unittest.py:
418         (CppStyleTest): Add test for softlink/uikit.
419
420 2019-01-18  Joanmarie Diggs  <jdiggs@igalia.com>
421
422         [GTK] install-dependencies tool looks for libunistring-dev for dnf
423         https://bugs.webkit.org/show_bug.cgi?id=193584
424
425         Change "-dev" to "-devel".
426
427         Reviewed by Michael Catanzaro.
428
429         * gtk/install-dependencies:
430
431 2019-01-18  Jonathan Bedard  <jbedard@apple.com>
432
433         webkitpy: Add iPhone and iPad ports
434         https://bugs.webkit.org/show_bug.cgi?id=193537
435         <rdar://problem/47353390>
436
437         Reviewed by Lucas Forschler.
438
439         Add --iphone-simulator and --ipad-simulator commands to run-webkit-tests which separate iPhone and iPad into separate
440         ports. Note that this separation is optional, the --ios-simulator command remains.
441
442         * Scripts/webkitpy/layout_tests/run_webkit_tests_integrationtest.py:
443         (RunTest.test_device_type_test_division): Drive-by fix.
444         (RunTest.test_device_type_specific_listing): Ditto.
445         (RunTest.test_ipad_test_division):
446         (RunTest):
447         (RunTest.test_ipad_listing):
448         * Scripts/webkitpy/port/factory.py:
449         (platform_options): Add --iphone-simulator and --ipad-simulator flags.
450         (PortFactory):
451         * Scripts/webkitpy/port/ios_simulator.py:
452         (IPhoneSimulatorPort):
453         (IPadSimulatorPort):
454
455 2019-01-18  Chris Dumez  <cdumez@apple.com>
456
457         Regression(PSON) Scroll position is not always restored properly when navigating back
458         https://bugs.webkit.org/show_bug.cgi?id=193578
459         <rdar://problem/47386331>
460
461         Reviewed by Tim Horton.
462
463         Add API test coverage.
464
465         * TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
466
467 2019-01-18  Youenn Fablet  <youenn@apple.com>
468
469         Add a new SPI to request for cache storage quota increase
470         https://bugs.webkit.org/show_bug.cgi?id=193323
471
472         Reviewed by Alex Christensen.
473
474         Implement WebsiteDataStore quota delegate to handle quota requests.
475         By default, do not update quota.
476         Update quota if test calls the new testRunner.allowCacheStorageQuotaIncrease method.
477
478         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
479         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
480         (WTR::TestRunner::allowCacheStorageQuotaIncrease):
481         * WebKitTestRunner/InjectedBundle/TestRunner.h:
482         * WebKitTestRunner/TestController.cpp:
483         (WTR::TestController::allowCacheStorageQuotaIncrease):
484         * WebKitTestRunner/TestController.h:
485         * WebKitTestRunner/TestInvocation.cpp:
486         (WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):
487         * WebKitTestRunner/cocoa/TestControllerCocoa.mm:
488         (-[CacheStorageQuotaManager init]):
489         (-[CacheStorageQuotaManager _requestCacheStorageSpace:frameOrigin:quota:currentSize:spaceRequired:decisionHandler:]):
490         (WTR::initializeWebViewConfiguration):
491         (WTR::TestController::cocoaResetStateToConsistentValues):
492         (WTR::TestController::allowCacheStorageQuotaIncrease):
493
494 2019-01-18  Aakash Jain  <aakash_jain@apple.com>
495
496         [ews-build] Pass owner to the triggered builds
497         https://bugs.webkit.org/show_bug.cgi?id=193574
498
499         Reviewed by Lucas Forschler.
500
501         * BuildSlaveSupport/ews-build/factories.py:
502         (BuildFactory.propertiesToPassToTriggers):
503
504 2019-01-18  Aakash Jain  <aakash_jain@apple.com>
505
506         [ews-app] Send patch author as a build property
507         https://bugs.webkit.org/show_bug.cgi?id=193560
508
509         Reviewed by Lucas Forschler.
510
511         * BuildSlaveSupport/ews-app/ews/fetcher.py:
512         (BugzillaPatchFetcher.fetch):
513
514 2019-01-18  Jonathan Bedard  <jbedard@apple.com>
515
516         webkitpy: Implement device type specific expected results (Follow-up fix)
517         https://bugs.webkit.org/show_bug.cgi?id=192162
518         <rdar://problem/46345449>
519
520         Unreviewed infrastructure fix.
521
522         * Scripts/webkitpy/layout_tests/controllers/manager.py:
523         (Manager.run): Don't boot a device if no tests are available to run on it.
524
525 2019-01-18  Jonathan Bedard  <jbedard@apple.com>
526
527         webkitpy: Implement device type specific expected results (Follow-up fix)
528         https://bugs.webkit.org/show_bug.cgi?id=192162
529         <rdar://problem/46345449>
530
531         Unreviewed infrastructure fix.
532
533         * Scripts/webkitpy/api_tests/manager.py:
534         (Manager._initialize_devices): Use DEVICE_TYPE when running API tests.
535
536 2019-01-18  Jonathan Bedard  <jbedard@apple.com>
537
538         webkitpy: Implement device type specific expected results (Part 2)
539         https://bugs.webkit.org/show_bug.cgi?id=192162
540         <rdar://problem/46345449>
541
542         Rubber-stamped by Aakash Jain.
543
544         This change uses device_type to select a different set of TestExpectation files based on the type of device running
545         tests. This requires multiple baseline search paths to be used in a single instantiation of run-webkit-tests. Note
546         that while multiple baseline search paths are used, any single test will only ever be run on a single device type.
547
548         * Scripts/webkitpy/layout_tests/controllers/layout_test_finder.py:
549         (LayoutTestFinder.find_tests): Pass device_type through.
550         * Scripts/webkitpy/layout_tests/controllers/layout_test_finder_unittest.py:
551         (LayoutTestFinderTests.test_touched_but_skipped_test): Allow device_type to be passed in.
552         * Scripts/webkitpy/layout_tests/controllers/manager.py:
553         (Manager.__init__): Make _expectations an OrderedDict indexed by device_type, add current_device_type.
554         (Manager._collect_tests): Pass device type to test finder.
555         (Manager._needs_web_platform_test):
556         (Manager._prepare_lists): Index _expectations by device type.
557         (Manager._test_input_for_file):
558         (Manager._test_is_slow): Ditto.
559         (Manager._test_should_dump_jsconsolelog_in_stderr):
560         (Manager._test_should_dump_jsconsolelog_in_stderr): Ditto.
561         (Manager._get_test_inputs):
562         (Manager._update_worker_count):
563         (Manager._set_up_run): Use current_device_type instead of passing device_type in.
564         (Manager.run): Re-write function to gather and parse expectations from multiple baseline search paths. In the event
565         that a test can be run on multiple device types, the first device in the device type list which is eligible will be
566         the one which runs the test.
567         (Manager._run_test_subset):
568         (Manager._run_tests): Index _expectations by current_device_type.
569         (Manager._print_expectation_line_for_test): Ditto.
570         (Manager._print_expectations_for_subset): Ditto.
571         (Manager.print_expectations): Re-write function to gather and parse expectations from multiple baseline search paths.
572         Unlike run, this function will behave the same regardless of what devices are available.
573         (Manager._custom_device_for_test): Deleted.
574         * Scripts/webkitpy/layout_tests/controllers/manager_unittest.py:
575         (ManagerTest.test_uses_custom_device): Deleted.
576         (ManagerTest.test_uses_custom_device.get_manager): Deleted.
577         * Scripts/webkitpy/layout_tests/layout_package/json_layout_results_generator.py:
578         (JSONLayoutResultsGenerator.__init__): Pass expectations as a dictionary indexed by device type.
579         (JSONLayoutResultsGenerator._insert_failure_summaries): The number of fixable tests must take into consideration
580         all of the expectations.
581         * Scripts/webkitpy/layout_tests/lint_test_expectations_unittest.py:
582         (FakePort.skipped_layout_tests): Allow device_type to be passed in.
583         * Scripts/webkitpy/layout_tests/models/test_expectations.py:
584         (TestExpectations.__init__): Allow device_type to be passed through.
585         (TestExpectations.parse_all_expectations): Pick expectations_dict by device type.
586         * Scripts/webkitpy/layout_tests/models/test_expectations_unittest.py: Allow device_type to be passed in.
587         * Scripts/webkitpy/layout_tests/models/test_run_results.py:
588         (summarize_results):
589         * Scripts/webkitpy/layout_tests/models/test_run_results_unittest.py:
590         (summarized_results): Expectations are stored in a dictionary indexed by device_type. When determining the expectation
591         a test ran with, one must check all expectations to find the first non-skip expectation.
592         * Scripts/webkitpy/layout_tests/run_webkit_tests_integrationtest.py:
593         (RunTest.test_device_type_test_division):
594         (RunTest):
595         (RunTest.test_device_type_specific_listing):
596         * Scripts/webkitpy/port/base.py:
597         (Port): Add default values for DEVICE_TYPE and DEFAULT_DEVICE_TYPES.
598         (Port.supported_device_types): The result of this function will change based on what devices are available.
599         * Scripts/webkitpy/port/device_port.py:
600         (DevicePort._device_type_with_version): Replace DEFAULT_DEVICE_TYPE with DEVICE_TYPE.
601         (DevicePort.default_child_processes): DEVICE_TYPE is a general type, so the built-in comparison of the DeviceType object
602         can be used.
603         (DevicePort.supported_device_types): Generates a list of device types determined by the available devices, if there are
604         any, or the DEFAULT_DEVICE_TYPES of the port.
605         * Scripts/webkitpy/port/ios.py:
606         (IOSPort): Change DEFAULT_DEVICE_TYPE to DEVICE_TYPE.
607         * Scripts/webkitpy/port/ios_simulator.py:
608         (IOSSimulatorPort): Set the DEFAULT_DEVICE_TYPES to the devices currently used to run layout tests.
609         * Scripts/webkitpy/port/watch.py:
610         (WatchPort): Change DEFAULT_DEVICE_TYPE to DEVICE_TYPE.
611         * Scripts/webkitpy/port/watch_simulator.py:
612         (WatchSimulatorPort): Set the DEFAULT_DEVICE_TYPES to the device currently used to run layout tests.
613         * Scripts/webkitpy/xcode/device_type.py:
614         (DeviceType):
615         (DeviceType.__hash__): Allow DeviceType to be used as a dictionary index.
616
617 2019-01-18  Philippe Normand  <pnormand@igalia.com>
618
619         [WPE] run-qt-wpe-minibrowser needlessly expects a --wpe argument
620         https://bugs.webkit.org/show_bug.cgi?id=193575
621
622         Reviewed by Michael Catanzaro.
623
624         Allow the script to run without explicit port argument because
625         it's specific to the WPE port anyway.
626
627         * Scripts/run-qt-wpe-minibrowser: Manually insert --wpe in argv
628         and simplify the rest of the code accordingly.
629
630 2019-01-18  Charlie Turner  <cturner@igalia.com>
631
632         [GStreamer][EME][ClearKey] Request keys from CDMInstance rather than passing via bus messages
633         https://bugs.webkit.org/show_bug.cgi?id=192229
634
635         Reviewed by Xabier Rodriguez-Calvar.
636
637         * MiniBrowser/wpe/main.cpp:
638         (main): Enable encrypted-media by default.
639
640 2019-01-18  Philippe Normand  <pnormand@igalia.com>
641
642         [Flatpak] Missing KeyboardInterrupt exception handler
643         https://bugs.webkit.org/show_bug.cgi?id=193570
644
645         Reviewed by Michael Catanzaro.
646
647         * flatpak/flatpakutils.py:
648         (WebkitFlatpak.run_in_sandbox): Basic KeyboardInterrupt handling.
649
650 2019-01-18  Zalan Bujtas  <zalan@apple.com>
651
652         [LFC][BFC][MarginCollapsing] Collapsing through should not ignore floats.
653         https://bugs.webkit.org/show_bug.cgi?id=193564
654
655         Reviewed by Antti Koivisto.
656
657         * LayoutReloaded/misc/LFC-passing-tests.txt:
658
659 2019-01-18  Zalan Bujtas  <zalan@apple.com>
660
661         [LFC] Do not skip float boxes that are not part of the current formatting context when computing bottom.
662         https://bugs.webkit.org/show_bug.cgi?id=193562
663
664         Reviewed by Antti Koivisto.
665
666         * LayoutReloaded/misc/LFC-passing-tests.txt:
667
668 2019-01-18  Zalan Bujtas  <zalan@apple.com>
669
670         [LFC][BFC] Check for inflow children while computing height for block formatting context roots.
671         https://bugs.webkit.org/show_bug.cgi?id=193555
672
673         Reviewed by Antti Koivisto.
674
675         * LayoutReloaded/misc/LFC-passing-tests.txt:
676
677 2019-01-18  Philippe Normand  <pnormand@igalia.com>
678
679         [WPE] Add Qt extension
680         https://bugs.webkit.org/show_bug.cgi?id=191464
681
682         Reviewed by Carlos Garcia Campos.
683
684         MiniBrowser and API tests for the WPE Qt API. To run the
685         MiniBrowser a new script is introduced. Example invocation:
686
687         $ run-qt-wpe-minibrowser -platform wayland https://webkit.org
688
689         Also note-worthy is the introduction of the python2-subprocess32
690         dependency to run the GLib API tests.
691
692         * MiniBrowser/wpe/CMakeLists.txt:
693         * MiniBrowser/wpe/qt/CMakeLists.txt: Added.
694         * MiniBrowser/wpe/qt/main.cpp: Added.
695         (main):
696         * MiniBrowser/wpe/qt/main.qml: Added.
697         * MiniBrowser/wpe/qt/qml.qrc: Added.
698         * Scripts/run-gtk-tests:
699         (GtkTestRunner.is_google_test):
700         (GtkTestRunner):
701         (GtkTestRunner.is_qt_test):
702         * Scripts/run-qt-wpe-minibrowser: Added.
703         * Scripts/run-wpe-tests:
704         (WPETestRunner):
705         (WPETestRunner.is_google_test):
706         (WPETestRunner.is_qt_test):
707         * TestWebKitAPI/Tests/WPEQt/TestLoad.cpp: Added.
708         (TestLoad::main):
709         * TestWebKitAPI/Tests/WPEQt/TestLoadHtml.cpp: Added.
710         (TestLoadHtml::main):
711         * TestWebKitAPI/Tests/WPEQt/TestLoadRequest.cpp: Added.
712         (TestLoadRequest::main):
713         * TestWebKitAPI/Tests/WPEQt/TestRunJavaScript.cpp: Added.
714         (TestRunJavaScript::main):
715         * TestWebKitAPI/Tests/WPEQt/WPEQtTest.cpp: Added.
716         (waitForSignal):
717         * TestWebKitAPI/Tests/WPEQt/WPEQtTest.h: Added.
718         (LoadSpy::LoadSpy):
719         (LoadSpy::~LoadSpy):
720         (LoadSpy::onLoadingChanged):
721         (LoadStartedCatcher::LoadStartedCatcher):
722         (LoadStartedCatcher::~LoadStartedCatcher):
723         (LoadStartedCatcher::onLoadingChanged):
724         (waitForLoadSucceeded):
725         (waitForLoadFailed):
726         * TestWebKitAPI/glib/CMakeLists.txt:
727         * flatpak/flatpakutils.py:
728         (WebkitFlatpak.load_from_args):
729         (WebkitFlatpak.__init__):
730         (WebkitFlatpak.clean_args):
731         (WebkitFlatpak.run_in_sandbox):
732         * flatpak/org.webkit.CommonModules.yaml:
733         * flatpak/org.webkit.WPE.yaml:
734         * flatpak/org.webkit.WPEModules.yaml:
735         * flatpak/org.webkit.WPEQT.yaml: Copied from Tools/flatpak/org.webkit.WebKit.yaml.
736         * flatpak/org.webkit.WebKit.yaml:
737         * glib/api_test_runner.py:
738         (TestRunner._run_test_qt):
739         (TestRunner.is_qt_test):
740         (TestRunner._run_test):
741
742 2019-01-17  Wenson Hsieh  <wenson_hsieh@apple.com>
743
744         [iOS] Content offset jumps erratically when autoscrolling near scroll view content inset areas
745         https://bugs.webkit.org/show_bug.cgi?id=193494
746         <rdar://problem/46859627>
747
748         Reviewed by Simon Fraser and Tim Horton.
749
750         Add a new test option to add a top content inset to the test runner's WKWebView's scroll view, and automatically
751         scroll to reveal this top content inset area when beginning the test (i.e., scroll to (0, -topContentInset)).
752
753         * DumpRenderTree/ios/UIScriptControllerIOS.mm:
754         (WTR::UIScriptController::contentOffsetX const):
755         (WTR::UIScriptController::contentOffsetY const):
756         * TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
757         * TestRunnerShared/UIScriptContext/UIScriptController.cpp:
758         (WTR::UIScriptController::contentOffsetX const):
759         (WTR::UIScriptController::contentOffsetY const):
760         * TestRunnerShared/UIScriptContext/UIScriptController.h:
761
762         Also add new UIScriptController methods to ask for the content offset of the platform scroll view.
763
764         * WebKitTestRunner/TestController.cpp:
765         (WTR::updateTestOptionsFromTestHeader):
766         * WebKitTestRunner/TestOptions.h:
767         (WTR::TestOptions::hasSameInitializationOptions const):
768         * WebKitTestRunner/ios/TestControllerIOS.mm:
769         (WTR::TestController::platformResetStateToConsistentValues):
770         * WebKitTestRunner/ios/UIScriptControllerIOS.mm:
771         (WTR::UIScriptController::contentOffsetX const):
772         (WTR::UIScriptController::contentOffsetY const):
773
774 2019-01-17  Truitt Savell  <tsavell@apple.com>
775
776         Unreviewed, rolling out r240124.
777
778         This commit broke an internal build.
779
780         Reverted changeset:
781
782         "SDK_VARIANT build destinations should be separate from non-
783         SDK_VARIANT builds"
784         https://bugs.webkit.org/show_bug.cgi?id=189553
785         https://trac.webkit.org/changeset/240124
786
787 2019-01-17  Alex Christensen  <achristensen@webkit.org>
788
789         Fix string concatenation API test after r239920
790         https://bugs.webkit.org/show_bug.cgi?id=193551
791         <rdar://problem/47359304>
792
793         Reviewed by Youenn Fablet.
794
795         * TestWebKitAPI/Tests/WTF/StringConcatenate.cpp:
796         (TestWebKitAPI::TEST):
797         Cocoa platforms' interpretation of UChar/unsigned short equality is not affected by ICU's recent change of UChar's type
798         in WebKit's build configuration like it apparently is on Linux.
799
800 2019-01-17  Aakash Jain  <aakash_jain@apple.com>
801
802         [ews-build] validate-patch should handle the case when bug_id is None
803         https://bugs.webkit.org/show_bug.cgi?id=193547
804
805         Reviewed by Lucas Forschler.
806
807         * BuildSlaveSupport/ews-build/steps.py:
808         (ValidatePatch._is_bug_closed): Gracefully handle the case when bug_id is None.
809         (ValidatePatch.start): If bug_id is set as None in build properties, fetch it from the patch.
810
811 2019-01-17  Aakash Jain  <aakash_jain@apple.com>
812
813         [ews-build] Add patch author information in build
814         https://bugs.webkit.org/show_bug.cgi?id=193465
815
816         Reviewed by Lucas Forschler.
817
818         * BuildSlaveSupport/ews-build/steps.py:
819         (ValidatePatch._is_patch_obsolete):
820
821 2019-01-17  Aakash Jain  <aakash_jain@apple.com>
822
823         [ews-build] Pass bug_id to the triggered builds
824         https://bugs.webkit.org/show_bug.cgi?id=193548
825
826         Reviewed by Lucas Forschler.
827
828         * BuildSlaveSupport/ews-build/factories.py:
829         (BuildFactory.propertiesToPassToTriggers):
830
831 2019-01-17  Jer Noble  <jer.noble@apple.com>
832
833         SDK_VARIANT build destinations should be separate from non-SDK_VARIANT builds
834         https://bugs.webkit.org/show_bug.cgi?id=189553
835
836         Reviewed by Tim Horton.
837
838         Add a check-webkit-style check that ensures all SDKVariant.xcconfig files match.
839
840         * ContentExtensionTester/Configurations/Base.xcconfig:
841         * ContentExtensionTester/Configurations/SDKVariant.xcconfig: Added.
842         * DumpRenderTree/mac/Configurations/Base.xcconfig:
843         * DumpRenderTree/mac/Configurations/SDKVariant.xcconfig: Added.
844         * ImageDiff/cg/Configurations/Base.xcconfig:
845         * ImageDiff/cg/Configurations/SDKVariant.xcconfig: Added.
846         * MiniBrowser/Configurations/Base.xcconfig:
847         * MiniBrowser/Configurations/SDKVariant.xcconfig: Added.
848         * MobileMiniBrowser/Configurations/Base.xcconfig:
849         * MobileMiniBrowser/Configurations/SDKVariant.xcconfig: Added.
850         * Scripts/webkitpy/style/checker.py:
851         (_all_categories):
852         (FileType):
853         (CheckerDispatcher._file_type):
854         (CheckerDispatcher._create_checker):
855         * Scripts/webkitpy/style/checkers/sdkvariant.py: Added.
856         (SDKVariantChecker):
857         (SDKVariantChecker.__init__):
858         (SDKVariantChecker.check):
859         * TestWebKitAPI/Configurations/Base.xcconfig:
860         * TestWebKitAPI/Configurations/SDKVariant.xcconfig: Added.
861         * WebEditingTester/Configurations/Base.xcconfig:
862         * WebEditingTester/Configurations/SDKVariant.xcconfig: Added.
863         * WebKitLauncher/Configurations/SDKVariant.xcconfig: Added.
864         * WebKitTestRunner/Configurations/Base.xcconfig:
865         * WebKitTestRunner/Configurations/SDKVariant.xcconfig: Added.
866         * lldb/lldbWebKitTester/Configurations/Base.xcconfig:
867         * lldb/lldbWebKitTester/Configurations/SDKVariant.xcconfig: Added.
868
869 2019-01-17  Zalan Bujtas  <zalan@apple.com>
870
871         [LFC][BFC] An element with transform is a containing block for positioned descendants.
872         https://bugs.webkit.org/show_bug.cgi?id=193534
873
874         Reviewed by Antti Koivisto.
875
876         * LayoutReloaded/misc/LFC-passing-tests.txt:
877
878 2019-01-17  Zalan Bujtas  <zalan@apple.com>
879
880         [LFC][BFC][Quirk] Take body padding and border into account when stretching height.
881         https://bugs.webkit.org/show_bug.cgi?id=193528
882
883         Reviewed by Antti Koivisto.
884
885         * LayoutReloaded/misc/LFC-passing-tests.txt:
886
887 2019-01-17  Zalan Bujtas  <zalan@apple.com>
888
889         [LFC][BFC] For height computation, the bottom edge of the last line box value should include top border/padding
890         https://bugs.webkit.org/show_bug.cgi?id=193520
891
892         Reviewed by Antti Koivisto.
893
894         * LayoutReloaded/misc/LFC-passing-tests.txt:
895
896 2019-01-17  Aakash Jain  <aakash_jain@apple.com>
897
898         [ews-build] unapply-patch step should not update source
899         https://bugs.webkit.org/show_bug.cgi?id=193234
900
901         Reviewed by Lucas Forschler.
902
903         * BuildSlaveSupport/ews-build/steps.py:
904         (CleanWorkingDirectory): Use clean-webkit script to clean the working directory.
905         (UnApplyPatchIfRequired): Use CleanWorkingDirectory as base class.
906
907 2019-01-16  Youenn Fablet  <youenn@apple.com>
908
909         Add a new SPI for controlling getUserMedia
910         https://bugs.webkit.org/show_bug.cgi?id=192793
911
912         Reviewed by Eric Carlson.
913
914         * MiniBrowser/mac/WK2BrowserWindowController.m:
915         (-[WK2BrowserWindowController _webView:requestUserMediaAuthorizationForFrame:devices:decisionHandler:]):
916         (-[WK2BrowserWindowController _webView:isMediaCaptureAuthorizedForFrame:decisionHandler:]):
917         * TestWebKitAPI/Tests/WebKit/GetUserMediaNavigation.mm:
918         (-[NavigationWhileGetUserMediaPromptDisplayedUIDelegate _webView:requestMediaCaptureAuthorizationForFrame:devices:decisionHandler:]):
919         * TestWebKitAPI/Tests/WebKit/GetUserMediaReprompt.mm:
920         (-[GetUserMediaRepromptUIDelegate _webView:requestMediaCaptureAuthorizationForFrame:devices:decisionHandler:]):
921         * TestWebKitAPI/Tests/WebKit/MediaStreamTrackDetached.mm:
922         (-[MediaStreamTrackDetachedUIDelegate _webView:requestMediaCaptureAuthorizationForFrame:devices:decisionHandler:]):
923         * TestWebKitAPI/Tests/WebKitCocoa/UserMediaDisabled.mm:
924         (-[UserMediaUIDelegate _webView:requestMediaCaptureAuthorizationForFrame:devices:decisionHandler:]):
925         (-[UserMediaUIDelegate _webView:isMediaCaptureAuthorizedForFrame:decisionHandler:]):
926         * TestWebKitAPI/Tests/WebKitCocoa/UserMediaSimulateFailedSandbox.mm:
927         (-[SimulateFailedSandboxUIDelegate _webView:requestMediaCaptureAuthorizationForFrame:devices:decisionHandler:]):
928         (-[SimulateFailedSandboxUIDelegate _webView:isMediaCaptureAuthorizedForFrame:decisionHandler:]):
929
930 2019-01-16  Zalan Bujtas  <zalan@apple.com>
931
932         [LFC][BFC] Inflow non-replaced used width should not be negative.
933         https://bugs.webkit.org/show_bug.cgi?id=193495
934
935         Reviewed by Antti Koivisto.
936
937         * LayoutReloaded/misc/LFC-passing-tests.txt:
938
939 2019-01-16  Chris Dumez  <cdumez@apple.com>
940
941         Regression(PSON) View becomes blank after click a cross-site download link
942         https://bugs.webkit.org/show_bug.cgi?id=193361
943         <rdar://problem/47099573>
944
945         Reviewed by Geoffrey Garen.
946
947         Add API test coverage.
948
949         * TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
950         (-[PSONNavigationDelegate webView:decidePolicyForNavigationResponse:decisionHandler:]):
951
952 2019-01-16  Zalan Bujtas  <zalan@apple.com>
953
954         [LFC][Out-of-flow] Set used vertical margin values when top/height/bottom are non-auto.
955         https://bugs.webkit.org/show_bug.cgi?id=193470
956
957         Reviewed by Antti Koivisto.
958
959         * LayoutReloaded/misc/LFC-passing-tests.txt:
960
961 2019-01-16  Zalan Bujtas  <zalan@apple.com>
962
963         [LFC] Adjust margin box verification.
964         https://bugs.webkit.org/show_bug.cgi?id=193482
965
966         Reviewed by Antti Koivisto.
967
968         * LayoutReloaded/misc/LFC-passing-tests.txt:
969
970 2019-01-15  Sihui Liu  <sihui_liu@apple.com>
971
972         Fix API test WebKit.WebsiteDataStoreCustomPathsWithoutPrewarming after 193354
973         https://bugs.webkit.org/show_bug.cgi?id=193451
974
975         Reviewed by Geoffrey Garen.
976
977         * TestWebKitAPI/Tests/WebKitCocoa/DuplicateCompletionHandlerCalls.mm:
978         (TEST):
979         * TestWebKitAPI/Tests/WebKitCocoa/WebsiteDataStoreCustomPaths.mm:
980         (runWebsiteDataStoreCustomPaths):
981
982 2019-01-15  Jonathan Bedard  <jbedard@apple.com>
983
984         webkitpy: Support boolean simctl isAvailable
985         https://bugs.webkit.org/show_bug.cgi?id=193472
986         <rdar://problem/47296150>
987
988         Reviewed by Ryosuke Niwa.
989
990         * Scripts/webkitpy/xcode/simulated_device.py:
991         (SimulatedDeviceManager._create_runtimes):
992         (SimulatedDeviceManager._create_device_with_runtime):
993
994 2019-01-15  Chris Dumez  <cdumez@apple.com>
995
996         Unreviewed, rolling out r239993, r239995, r239997, and
997         r239999.
998
999         Caused assertions under
1000         ViewGestureController::disconnectFromProcess()
1001
1002         Reverted changesets:
1003
1004         "Regression(PSON) View becomes blank after click a cross-site
1005         download link"
1006         https://bugs.webkit.org/show_bug.cgi?id=193361
1007         https://trac.webkit.org/changeset/239993
1008
1009         "Unreviewed iOS build fix after r239993."
1010         https://trac.webkit.org/changeset/239995
1011
1012         "Fix iOS build after r239993"
1013         https://bugs.webkit.org/show_bug.cgi?id=193361
1014         https://trac.webkit.org/changeset/239997
1015
1016         "Unreviewed, revert part of r239997 as it is not needed to fix
1017         the build."
1018         https://trac.webkit.org/changeset/239999
1019
1020 2019-01-15  Tim Horton  <timothy_horton@apple.com>
1021
1022         Cannot tab out of WKWebView on macOS
1023         https://bugs.webkit.org/show_bug.cgi?id=161448
1024         <rdar://problem/28100085>
1025
1026         Reviewed by Dean Jackson.
1027
1028         Add a test that tabbing into and out of WKWebView works correctly.
1029
1030         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
1031         * TestWebKitAPI/Tests/WebKitCocoa/CommandBackForward.mm:
1032         (WebKit2_CommandBackForwardTest::SetUp):
1033         (-[CommandBackForwardOffscreenWindow isKeyWindow]): Deleted.
1034         (-[CommandBackForwardOffscreenWindow isVisible]): Deleted.
1035         * TestWebKitAPI/Tests/WebKitCocoa/TabOutOfWebView.mm: Added.
1036         (-[FocusableView canBecomeKeyView]):
1037         (TEST):
1038         * TestWebKitAPI/mac/OffscreenWindow.h: Added.
1039         * TestWebKitAPI/mac/OffscreenWindow.mm: Added.
1040         (-[OffscreenWindow initWithSize:]):
1041         (-[OffscreenWindow isKeyWindow]):
1042         (-[OffscreenWindow isVisible]):
1043         * TestWebKitAPI/mac/PlatformWebViewMac.mm:
1044         (TestWebKitAPI::PlatformWebView::initialize):
1045         (-[ActiveOffscreenWindow isKeyWindow]): Deleted.
1046         (-[ActiveOffscreenWindow isVisible]): Deleted.
1047         Factor ActiveOffscreenWindow out into OffscreenWindow and share it.
1048
1049 2019-01-15  Ryan Haddad  <ryanhaddad@apple.com>
1050
1051         Adjust the arguments passed to run-javascriptcore-tests for the 32-bit JSC bot
1052         https://bugs.webkit.org/show_bug.cgi?id=193459
1053
1054         Reviewed by Mark Lam.
1055
1056         * BuildSlaveSupport/build.webkit.org-config/steps.py:
1057         (Run32bitJSCTests): This queue should not run JIT, testair, testb3, or testmasm.
1058
1059 2019-01-15  Chris Dumez  <cdumez@apple.com>
1060
1061         Regression(PSON) View becomes blank after click a cross-site download link
1062         https://bugs.webkit.org/show_bug.cgi?id=193361
1063         <rdar://problem/47099573>
1064
1065         Reviewed by Geoff Garen.
1066
1067         Add API test coverage.
1068
1069         * TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
1070         (-[PSONNavigationDelegate webView:decidePolicyForNavigationResponse:decisionHandler:]):
1071
1072 2019-01-15  Zalan Bujtas  <zalan@apple.com>
1073
1074         [LFC][Out-of-flow] Ignore bottom when the vertical values are over-constrained
1075         https://bugs.webkit.org/show_bug.cgi?id=193448
1076
1077         Reviewed by Antti Koivisto.
1078
1079         * LayoutReloaded/misc/LFC-passing-tests.txt:
1080
1081 2019-01-15  Jonathan Bedard  <jbedard@apple.com>
1082
1083         webkitpy: Implement device type specific expected results (Part 1)
1084         https://bugs.webkit.org/show_bug.cgi?id=192162
1085
1086         Reviewed by Lucas Forschler.
1087
1088         Device type specific expected results covers two related ideas. The first (covered by this change)
1089         is where to search for -expected.* files. The second is which tests to run based on the
1090         TestExpectations.txt file.
1091
1092         After this change, the baseline search path will be determined by the type of device running a
1093         test. Device type will be passed into any function which picks a file based on the baseline search
1094         path.
1095
1096         * Scripts/webkitpy/layout_tests/controllers/layout_test_runner.py:
1097         (Worker._update_test_input): Pass device_type to self._port.reference_files(...).
1098         * Scripts/webkitpy/layout_tests/controllers/manager.py:
1099         (Manager.run): Print baseline search path for each round of devices.
1100         * Scripts/webkitpy/layout_tests/controllers/single_test_runner.py:
1101         (SingleTestRunner.__init__): Pass device_type into expected_*(...).
1102         (SingleTestRunner._expected_driver_output): Ditto.
1103         (SingleTestRunner._driver_input): Ditto.
1104         * Scripts/webkitpy/layout_tests/views/printing.py:
1105         (Printer.print_config): Move printing of baseline search path to a separate function.
1106         (Printer.print_baseline_search_path): Moved from Printer.print_config.
1107         * Scripts/webkitpy/layout_tests/views/printing_unittest.py:
1108         (Testprinter.test_print_config):
1109         (Testprinter.test_print_baseline_search_path):
1110         * Scripts/webkitpy/port/base.py:
1111         (Port.baseline_search_path): Pass device_type through.
1112         (Port._expected_baselines_for_suffixes): Ditto.
1113         (Port.expected_baselines): Ditto.
1114         (Port.expected_filename): Ditto.
1115         (Port.expected_checksum): Ditto.
1116         (Port.expected_image): Ditto.
1117         (Port.expected_audio): Ditto.
1118         (Port.expected_text): Ditto.
1119         (Port.reference_files): Ditto.
1120         (Port.tests): Ditto.
1121         (Port._expanded_paths): Ditto.
1122         (Port.skipped_layout_tests): Ditto.
1123         (Port.expectations_dict): Ditto.
1124         (Port._port_specific_expectations_files): Ditto.
1125         (Port.expectations_files): Ditto.
1126         (Port.test_search_path): Ditto.
1127         (Port._tests_for_other_platforms): Ditto.
1128         * Scripts/webkitpy/port/base_unittest.py:
1129         (PortTest.test_additional_platform_directory): Accept, but do not use, device_type.
1130         (PortTest.test_nonexistant_expectations): Ditto.
1131         (test_ref_tests_platform_directory): Ditto.
1132         * Scripts/webkitpy/port/darwin.py:
1133         (DarwinPort._port_specific_expectations_files): Accept device_type.
1134         * Scripts/webkitpy/port/driver.py:
1135         (DriverProxy):
1136         (DriverProxy.host): Expose _target_host for device_type information.
1137         * Scripts/webkitpy/port/gtk.py:
1138         (GtkPort._port_specific_expectations_files): Accept, but do not use, device_type.
1139         * Scripts/webkitpy/port/ios.py:
1140         (IOSPort. default_baseline_search_path): Remove memoized, since it does not accept **kwargs.
1141         * Scripts/webkitpy/port/mac.py:
1142         (MacPort. default_baseline_search_path): Ditto.
1143         * Scripts/webkitpy/port/port_testcase.py:
1144         (TestWebKitPort._tests_for_other_platforms): Accept, but do not use, device_type.
1145         * Scripts/webkitpy/port/test.py:
1146         * Scripts/webkitpy/port/watch.py:
1147         (WatchPort. default_baseline_search_path): Remove memoized, since it does not accept **kwargs.
1148         * Scripts/webkitpy/port/win.py:
1149         (WinPort.test_search_path): Accept, but do not use, device_type.
1150         * Scripts/webkitpy/port/wpe.py:
1151         (WPEPort._port_specific_expectations_files): Ditto.
1152         * Scripts/webkitpy/tool/servers/rebaselineserver.py:
1153         (get_test_baselines.AllPlatformsPort.baseline_search_path): Ditto.
1154
1155 2019-01-15  Zalan Bujtas  <zalan@apple.com>
1156
1157         [LFC] Use the containing block's padding box to position out-of-flow elements.
1158         https://bugs.webkit.org/show_bug.cgi?id=193431
1159
1160         Reviewed by Antti Koivisto.
1161
1162         * LayoutReloaded/misc/LFC-passing-tests.txt:
1163
1164 2019-01-14  Tim Horton  <timothy_horton@apple.com>
1165
1166         Move a test implementation file that got misplaced in the Xcode project
1167
1168         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
1169
1170 2019-01-14  Commit Queue  <commit-queue@webkit.org>
1171
1172         Unreviewed, rolling out r239901, r239909, r239910, r239912,
1173         r239913, and r239914.
1174         https://bugs.webkit.org/show_bug.cgi?id=193407
1175
1176         These revisions caused an internal failure (Requested by
1177         Truitt on #webkit).
1178
1179         Reverted changesets:
1180
1181         "[Cocoa] Avoid importing directly from subumbrella frameworks"
1182         https://bugs.webkit.org/show_bug.cgi?id=186016
1183         https://trac.webkit.org/changeset/239901
1184
1185         "Tried to fix USE(APPLE_INTERNAL_SDK) builds after r239901."
1186         https://trac.webkit.org/changeset/239909
1187
1188         "Tried to fix the build."
1189         https://trac.webkit.org/changeset/239910
1190
1191         "Fixed iOS builds after r239910."
1192         https://trac.webkit.org/changeset/239912
1193
1194         "More build fixing."
1195         https://trac.webkit.org/changeset/239913
1196
1197         "Tried to fix USE(APPLE_INTERNAL_SDK) 32-bit builds."
1198         https://trac.webkit.org/changeset/239914
1199
1200 2019-01-14  Mark Lam  <mark.lam@apple.com>
1201
1202         Re-enable ability to build --cloop builds.
1203         https://bugs.webkit.org/show_bug.cgi?id=192955
1204         <rdar://problem/46882363>
1205
1206         Reviewed by Saam barati and Keith Miller.
1207
1208         The --cloop build option was being ignored this whole time since r236381.
1209         This patch makes it possible to build CLoop builds again.
1210
1211         * Scripts/build-jsc:
1212         * Scripts/webkitperl/FeatureList.pm:
1213         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
1214
1215 2019-01-14  Jonathan Bedard  <jbedard@apple.com>
1216
1217         webkitpy: Expose device_type from host-like objects
1218         https://bugs.webkit.org/show_bug.cgi?id=193406
1219         <rdar://problem/47262305>
1220
1221         Reviewed by Lucas Forschler.
1222
1223         Devices should expose device_type. As a result, all host objects should
1224         provide a device_type property, even if they do not yet define a device_type.
1225
1226         * Scripts/webkitpy/common/system/systemhost.py:
1227         (SystemHost):
1228         (SystemHost.device_type):
1229         * Scripts/webkitpy/common/system/systemhost_mock.py:
1230         (MockSystemHost):
1231         (MockSystemHost.device_type):
1232         * Scripts/webkitpy/port/device.py:
1233         (Device):
1234         (Device.device_type):
1235         * Scripts/webkitpy/xcode/simulated_device.py:
1236         (SimulatedDeviceManager._find_exisiting_device_for_request):
1237         (SimulatedDeviceManager._disambiguate_device_type):
1238         (SimulatedDeviceManager._does_fulfill_request):
1239         (SimulatedDeviceManager.device_count_for_type):
1240         (SimulatedDeviceManager.initialize_devices):
1241         * Scripts/webkitpy/xcode/simulated_device_unittest.py:
1242         (test_available_devices):
1243         (test_swapping_devices):
1244
1245 2019-01-14  Jonathan Bedard  <jbedard@apple.com>
1246
1247         webkitpy: Support alternate simctl device list output (Follow-up fix)
1248         https://bugs.webkit.org/show_bug.cgi?id=193362
1249         <rdar://problem/47122965>
1250
1251         Rubber-stamped by Lucas Forschler.
1252
1253         * Scripts/webkitpy/xcode/simulated_device.py:
1254         (SimulatedDeviceManager.populate_available_devices):
1255
1256 2019-01-14  Wenson Hsieh  <wenson_hsieh@apple.com>
1257
1258         [iOS] Expose SPI to access the current sentence boundary and selection state
1259         https://bugs.webkit.org/show_bug.cgi?id=193398
1260         <rdar://problem/45893108>
1261
1262         Reviewed by Dean Jackson.
1263
1264         Add an API test to verify that an SPI client can observe changes in the `@"_selectionAttributes"` key path on
1265         WKWebView, and that inserting text, deleting, and changing the selection cause selection attributes to change as
1266         expected.
1267
1268         * TestWebKitAPI/EditingTestHarness.h:
1269         * TestWebKitAPI/EditingTestHarness.mm:
1270         (-[EditingTestHarness moveBackward]):
1271         (-[EditingTestHarness moveForward]):
1272         (-[EditingTestHarness moveForwardAndExpectEditorStateWith:]):
1273
1274         Add a couple of new helper methods on EditingTestHarness.
1275
1276         * TestWebKitAPI/Tests/WebKitCocoa/EditorStateTests.mm:
1277         (-[SelectionChangeObserver initWithWebView:]):
1278         (-[SelectionChangeObserver webView]):
1279         (-[SelectionChangeObserver observeValueForKeyPath:ofObject:change:context:]):
1280         (-[SelectionChangeObserver currentSelectionAttributes]):
1281
1282 2019-01-14  Zalan Bujtas  <zalan@apple.com>
1283
1284         [LFC][BFC] Add basic box-sizing support.
1285         https://bugs.webkit.org/show_bug.cgi?id=193392
1286
1287         Reviewed by Antti Koivisto.
1288
1289         * LayoutReloaded/misc/LFC-passing-tests.txt:
1290
1291 2019-01-14  Charlie Turner  <cturner@igalia.com>
1292
1293         [WPE] API test gardening
1294         https://bugs.webkit.org/show_bug.cgi?id=193319
1295
1296         Reviewed by Michael Catanzaro.
1297
1298         * TestWebKitAPI/glib/TestExpectations.json: Remove some now
1299         passing tests.
1300
1301 2019-01-14  Charlie Turner  <cturner@igalia.com>
1302
1303         [GStreamer] Add sharedBuffer utility to GstMappedBuffer, and a testsuite
1304         https://bugs.webkit.org/show_bug.cgi?id=192977
1305
1306         Reviewed by Carlos Garcia Campos.
1307
1308         * TestWebKitAPI/PlatformGTK.cmake: Build the new GStreamer test harness
1309         * TestWebKitAPI/PlatformWPE.cmake: Ditto.
1310         * TestWebKitAPI/Tests/WebCore/gstreamer/GStreamerTest.cpp: Added.
1311         (TestWebKitAPI::GStreamerTest::SetUp):
1312         (TestWebKitAPI::GStreamerTest::TearDown):
1313         * TestWebKitAPI/Tests/WebCore/gstreamer/GStreamerTest.h: Added.
1314         * TestWebKitAPI/Tests/WebCore/gstreamer/GstMappedBuffer.cpp: Added.
1315         (TestWebKitAPI::TEST_F):
1316
1317 2019-01-14  Charlie Turner  <cturner@igalia.com>
1318
1319         [WPE] Workaround for incorrect template specialization being selected when UChar=char16_t
1320         https://bugs.webkit.org/show_bug.cgi?id=193332
1321
1322         Reviewed by Michael Catanzaro.
1323
1324         * TestWebKitAPI/Tests/WTF/StringConcatenate.cpp: When UChar is
1325         defined as a char16_t, which changed in ICU 59, the
1326         StringTypeAdapter<UnsignedInt, ...> overload catches casts to
1327         unsigned short. This test is relying on the behaviour that
1328         UChar=unsigned short, which doesn't hold across platforms and ICU
1329         library versions. The full fix would be a special syntax for
1330         literal characters so that these ambiguities do not arise. That
1331         work is proposed in https://bugs.webkit.org/show_bug.cgi?id=193101.
1332         (TestWebKitAPI::TEST):
1333
1334 2019-01-14  Carlos Garcia Campos  <cgarcia@igalia.com>
1335
1336         Unreviewed. [GTK][WPE] Run distcheck with gtkdoc and MiniBrowser enabled
1337
1338         * Scripts/make-dist:
1339         (Distcheck.configure):
1340
1341 2019-01-13  Aakash Jain  <aakash_jain@apple.com>
1342
1343         [ews-build] Update macOS queue configurations
1344         https://bugs.webkit.org/show_bug.cgi?id=193365
1345         <rdar://problem/47221073>
1346
1347         Unreviewed, renamed mac-high-sierra to mac-highsierra to match with build.webkit.org configuration.
1348
1349         * BuildSlaveSupport/ews-build/config.json:
1350
1351 2019-01-13  Zalan Bujtas  <zalan@apple.com>
1352
1353         [LFC] Adjust assert for statically positioned fixed elements
1354         https://bugs.webkit.org/show_bug.cgi?id=193385
1355
1356         Reviewed by Antti Koivisto.
1357
1358         * LayoutReloaded/misc/LFC-passing-tests.txt:
1359
1360 2019-01-13  Philippe Normand  <pnormand@igalia.com>
1361
1362         [WPE][MiniBrowser] Ephemeral WebContext leaks in automation mode
1363         https://bugs.webkit.org/show_bug.cgi?id=193387
1364
1365         Reviewed by Carlos Garcia Campos.
1366
1367         * MiniBrowser/wpe/main.cpp:
1368         (main):
1369
1370 2019-01-12  Timothy Hatcher  <timothy@apple.com>
1371
1372         Have prefers-color-scheme: light always match on macOS versions before Mojave.
1373         https://bugs.webkit.org/show_bug.cgi?id=191655
1374         rdar://problem/46074680
1375
1376         Reviewed by Megan Gardner.
1377
1378         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig: ENABLE_DARK_MODE_CSS_macosx for all OS versions.
1379         * TestWebKitAPI/Tests/WebKit/mac/ForceLightAppearanceInBundle.mm:
1380
1381 2019-01-12  Dan Bernstein  <mitz@apple.com>
1382
1383         [Cocoa] Avoid importing directly from subumbrella frameworks
1384         https://bugs.webkit.org/show_bug.cgi?id=186016
1385         <rdar://problem/40591038>
1386
1387         Reviewed by Sam Weinig.
1388
1389         * DumpRenderTree/cg/PixelDumpSupportCG.cpp: Include CoreServices.h instead of a
1390           LaunchServices header.
1391         * DumpRenderTree/mac/Configurations/BaseTarget.xcconfig: Removed -iframework options from
1392           OTHER_CFLAGS and OTHER_CPLUSPLUSFLAGS.
1393         * DumpRenderTree/mac/LayoutTestHelper.m: Import ApplicationServices.h instead of ColorSync.h
1394           when using SDKs earlier than 10.13.
1395         * TestWebKitAPI/Configurations/Base.xcconfig: Removed -iframework options from OTHER_CFLAGS
1396           and OTHER_CPLUSPLUSFLAGS.
1397         * WebKitTestRunner/Configurations/BaseTarget.xcconfig: Removed -iframework options from
1398           OTHER_CFLAGS and OTHER_CPLUSPLUSFLAGS.
1399         * WebKitTestRunner/cg/TestInvocationCG.cpp: Include CoreServices.h instead of a
1400           LaunchServices header.
1401
1402 2019-01-11  John Wilander  <wilander@apple.com>
1403
1404         Compile out Web API Statistics Collection
1405         https://bugs.webkit.org/show_bug.cgi?id=193370
1406         <rdar://problem/45388584>
1407
1408         Reviewed by Brent Fulgham.
1409
1410         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
1411             Defined ENABLE_WEB_API_STATISTICS, off by default.
1412
1413 2019-01-11  Carlos Eduardo Ramalho  <cadubentzen@gmail.com>
1414
1415         [WPE] Add gtk-doc
1416         https://bugs.webkit.org/show_bug.cgi?id=178900
1417
1418         Reviewed by Michael Catanzaro.
1419
1420         Add Tools/gtkdoc to manifest.txt.in files.
1421         This should have been done in r238853 and caused failure in building WebKitGTK+ unstable release 2.23.2.
1422
1423         * gtk/manifest.txt.in: Add Tools/gtkdoc directory.
1424         * wpe/manifest.txt.in: Add Tools/gtkdoc directory and uncomment lines to move documentation artifacts.
1425
1426 2019-01-11  Wenson Hsieh  <wenson_hsieh@apple.com>
1427
1428         [iOS] Precision drop state thrashes when dragging near the top edge of an editable element
1429         https://bugs.webkit.org/show_bug.cgi?id=193364
1430         <rdar://problem/47214117>
1431
1432         Reviewed by Tim Horton.
1433
1434         Add a test to verify that dragging near the top of a textarea element does not flag the drop proposal as
1435         precise, whereas dragging near the middle of the textarea does.
1436
1437         * TestWebKitAPI/Tests/ios/DragAndDropTestsIOS.mm:
1438         (TestWebKitAPI::TEST):
1439
1440 2019-01-11  Jonathan Bedard  <jbedard@apple.com>
1441
1442         webkitpy: Support alternate simctl device list output
1443         https://bugs.webkit.org/show_bug.cgi?id=193362
1444         <rdar://problem/47122965>
1445
1446         Reviewed by Lucas Forschler.
1447
1448         * Scripts/webkitpy/xcode/simulated_device.py:
1449         (SimulatedDeviceManager.populate_available_devices):
1450
1451 2019-01-11  Aakash Jain  <aakash_jain@apple.com>
1452
1453         [ews-build] Update macOS queue configurations
1454         https://bugs.webkit.org/show_bug.cgi?id=193365
1455
1456         Reviewed by Lucas Forschler.
1457
1458         * BuildSlaveSupport/ews-build/config.json:
1459
1460 2019-01-11  Jonathan Bedard  <jbedard@apple.com>
1461
1462         webkitpy: Incorporate device type into baseline search path
1463         https://bugs.webkit.org/show_bug.cgi?id=193356
1464         <rdar://problem/47215515>
1465
1466         Reviewed by Lucas Forschler.
1467
1468         We need a way to include device type in the baseline search path for iOS to support device specific test expectations.
1469
1470         * Scripts/webkitpy/port/base.py:
1471         (Port.default_baseline_search_path): Allow device type to be passed in.
1472         * Scripts/webkitpy/port/gtk.py:
1473         (GtkPort.default_baseline_search_path): Ignore device type.
1474         * Scripts/webkitpy/port/ios.py:
1475         (IOSPort.default_baseline_search_path): Optionally allow device type to be incorporated into the baseline search path.
1476         (IOSPort.test_expectations_file_position): Update index for the additional device-type specific baseline search path.
1477         * Scripts/webkitpy/port/ios_device_unittest.py:
1478         (IOSDeviceTest):
1479         * Scripts/webkitpy/port/ios_simulator_unittest.py:
1480         (IOSSimulatorTest):
1481         * Scripts/webkitpy/port/mac.py:
1482         (MacPort.default_baseline_search_path): Ignore device type.
1483         * Scripts/webkitpy/port/watch.py:
1484         (WatchPort.default_baseline_search_path): Ditto.
1485         * Scripts/webkitpy/port/win.py:
1486         (WinPort.default_baseline_search_path): Ditto.
1487         (WinCairoPort.default_baseline_search_path): Ditto.
1488         * Scripts/webkitpy/port/wpe.py:
1489         (WPEPort.default_baseline_search_path): Ditto.
1490
1491 2019-01-11  Jonathan Bedard  <jbedard@apple.com>
1492
1493         webkitpy: Print abbreviated baseline search path that includes only folders that exist
1494         https://bugs.webkit.org/show_bug.cgi?id=193352
1495         <rdar://problem/47210736>
1496
1497         Reviewed by Lucas Forschler.
1498
1499         * Scripts/webkitpy/layout_tests/views/printing.py:
1500         (Printer.print_config): Print list on only baseline search paths which exist. 
1501         * Scripts/webkitpy/layout_tests/views/printing_unittest.py:
1502         (Testprinter.test_print_config):
1503
1504 2019-01-11  Joseph Pecoraro  <pecoraro@apple.com>
1505
1506         Cleanup possible WK*Copy/Create leaks in WebKitTestRunner
1507         https://bugs.webkit.org/show_bug.cgi?id=193340
1508
1509         Reviewed by David Kilzer.
1510
1511         * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
1512         (WTR::InjectedBundle::didReceiveMessageToPage):
1513         Pull the strings out into a WKRetainPtr.
1514
1515         * WebKitTestRunner/WebNotificationProvider.cpp:
1516         (WTR::WebNotificationProvider::closeWebNotification):
1517         Adopt the created value into the WKRetainPtr.
1518
1519         * WebKitTestRunner/mac/TestControllerMac.mm:
1520         (WTR::generateWhitelist):
1521         Immediately adopt a created value to avoid potential mistakes.
1522
1523 2019-01-11  Dominik Infuehr  <dinfuehr@igalia.com>
1524
1525         Enable DFG on ARM/Linux again
1526         https://bugs.webkit.org/show_bug.cgi?id=192496
1527
1528         Reviewed by Yusuke Suzuki.
1529
1530         After changing the bytecode format DFG was disabled on all 32-bit
1531         architectures. Enable DFG now again on ARM/Linux. Run again JIT-tests
1532         on ARM by default.
1533
1534         * Scripts/run-jsc-stress-tests:
1535
1536 2019-01-11  Timothy Hatcher  <timothy@apple.com>
1537
1538         Unreviewed, fix #ifdef in API test added in r239851.
1539         https://bugs.webkit.org/show_bug.cgi?id=193327
1540         rdar://problem/47093222
1541
1542         * TestWebKitAPI/Tests/WebKit/mac/ForceLightAppearanceInBundle_Bundle.mm:
1543
1544 2019-01-11  Wenson Hsieh  <wenson_hsieh@apple.com>
1545
1546         Introduce IDL files for runtime-enabled UndoManager and UndoItem JavaScript API
1547         https://bugs.webkit.org/show_bug.cgi?id=193109
1548         <rdar://problem/44807048>
1549
1550         Reviewed by Ryosuke Niwa.
1551
1552         Introduce and respect a test option to enable the UndoManager API.
1553
1554         * WebKitTestRunner/TestController.cpp:
1555         (WTR::updateTestOptionsFromTestHeader):
1556         * WebKitTestRunner/TestOptions.h:
1557         (WTR::TestOptions::hasSameInitializationOptions const):
1558         * WebKitTestRunner/cocoa/TestControllerCocoa.mm:
1559         (WTR::TestController::platformCreateWebView):
1560
1561 2019-01-11  Zalan Bujtas  <zalan@apple.com>
1562
1563         [LFC][BFC][MarginCollapsing] Adjust vertical position when box margin collapses through.
1564         https://bugs.webkit.org/show_bug.cgi?id=193346
1565
1566         Reviewed by Antti Koivisto.
1567
1568         * LayoutReloaded/misc/LFC-passing-tests.txt:
1569
1570 2019-01-10  Ryan Haddad  <ryanhaddad@apple.com>
1571
1572         Unreviewed, fix typo that breaks dashboard link.
1573
1574         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/WebKitBuildbot.js:
1575         (WebKitBuildbot):
1576
1577 2019-01-10  Ryan Haddad  <ryanhaddad@apple.com>
1578
1579         Update macOS queue configurations
1580         https://bugs.webkit.org/show_bug.cgi?id=193329
1581
1582         Reviewed by Alexey Proskuryakov.
1583
1584         * BuildSlaveSupport/build.webkit.org-config/config.json:
1585         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BubbleQueueServer.js:
1586         (BubbleQueueServer):
1587         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/Dashboard.js:
1588         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/WebKitBuildbot.js:
1589         (WebKitBuildbot):
1590         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Styles/Main.css:
1591         (table.queue-grid tr.platform.macos-sierra img.logo): Deleted.
1592         * BuildSlaveSupport/build.webkit.org-config/steps_unittest.py:
1593
1594 2019-01-10  Joseph Pecoraro  <pecoraro@apple.com>
1595
1596         MiniBrowser should be able to navigate to about:blank
1597         https://bugs.webkit.org/show_bug.cgi?id=193345
1598
1599         Reviewed by Simon Fraser.
1600
1601         * MiniBrowser/mac/BrowserWindowController.m:
1602         (-[BrowserWindowController addProtocolIfNecessary:]):
1603         Don't prepend "http://" to "about:" prefixed URLs like "about:blank".
1604
1605         * MiniBrowser/mac/WK1BrowserWindowController.m:
1606         (-[WK1BrowserWindowController fetch:]):
1607         * MiniBrowser/mac/WK2BrowserWindowController.m:
1608         (-[WK2BrowserWindowController fetch:]):
1609         Clean up the code that uses this to match style.
1610
1611 2019-01-10  Joseph Pecoraro  <pecoraro@apple.com>
1612
1613         Remove MiniBrowser custom "Process Swap" menu item which does not work
1614         https://bugs.webkit.org/show_bug.cgi?id=193344
1615
1616         Reviewed by Simon Fraser.
1617
1618         There is a menu item under the Experimental menu that does work.
1619
1620         * MiniBrowser/mac/AppDelegate.m:
1621         (defaultConfiguration):
1622         * MiniBrowser/mac/SettingsController.h:
1623         * MiniBrowser/mac/SettingsController.m:
1624         (-[SettingsController _populateMenu]):
1625         (-[SettingsController validateMenuItem:]):
1626         (-[SettingsController processSwapOnNavigationEnabled]): Deleted.
1627         (-[SettingsController toggleProcessSwapOnNavigation:]): Deleted.
1628
1629 2019-01-10  Timothy Hatcher  <timothy@apple.com>
1630
1631         Add WKBundlePage SPI to temporarily force light or dark appearance on a page.
1632         https://bugs.webkit.org/show_bug.cgi?id=193327
1633         rdar://problem/47093222
1634
1635         Reviewed by Tim Horton.
1636
1637         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
1638         * TestWebKitAPI/Tests/WebKit/mac/ForceLightAppearanceInBundle.mm: Added.
1639         (TestWebKitAPI::didFinishNavigation):
1640         (TestWebKitAPI::didReceiveMessageFromInjectedBundle):
1641         (TestWebKitAPI::TEST):
1642         * TestWebKitAPI/Tests/WebKit/mac/ForceLightAppearanceInBundle_Bundle.mm: Added.
1643         (TestWebKitAPI::ForceLightAppearanceInBundleTest::ForceLightAppearanceInBundleTest):
1644         (TestWebKitAPI::ForceLightAppearanceInBundleTest::didCreatePage):
1645         (TestWebKitAPI::ForceLightAppearanceInBundleTest::didReceiveMessage):
1646         * TestWebKitAPI/Tests/WebKit/mac/dark-mode.html: Added.
1647
1648 2019-01-10  Joseph Pecoraro  <pecoraro@apple.com>
1649
1650         Leak of WKWebProcessPlugInHitTestResult (160 bytes) in com.apple.WebKit.WebContent running layout tests
1651         https://bugs.webkit.org/show_bug.cgi?id=193338
1652         <rdar://problem/46664774>
1653
1654         Reviewed by David Kilzer.
1655
1656         * WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
1657         (WTR::InjectedBundlePage::decidePolicyForNavigationAction):
1658
1659 2019-01-10  Commit Queue  <commit-queue@webkit.org>
1660
1661         Unreviewed, rolling out r239825.
1662         https://bugs.webkit.org/show_bug.cgi?id=193330
1663
1664         Broke tests on armv7/linux bots (Requested by guijemont on
1665         #webkit).
1666
1667         Reverted changeset:
1668
1669         "Enable DFG on ARM/Linux again"
1670         https://bugs.webkit.org/show_bug.cgi?id=192496
1671         https://trac.webkit.org/changeset/239825
1672
1673 2019-01-10  Zhifei Fang  <zhifei_fang@apple.com>
1674
1675         Disable the run-jsc-stress-test remote host key check.
1676         https://bugs.webkit.org/show_bug.cgi?id=192988
1677
1678         Reviewed by Alexey Proskuryakov.
1679
1680         * Scripts/run-jsc-stress-tests:
1681
1682 2019-01-10  John Wilander  <wilander@apple.com>
1683
1684         Override the session configuration for cookieAcceptPolicy
1685         https://bugs.webkit.org/show_bug.cgi?id=190925
1686         <rdar://problem/45497382>
1687
1688         Reviewed by Alexey Proskuryakov and Alex Christensen.
1689
1690         Test infrastructure for setting a first-party-only cookie policy.
1691
1692         * DumpRenderTree/TestRunner.cpp:
1693         (setOnlyAcceptFirstPartyCookiesCallback):
1694         (TestRunner::staticFunctions):
1695         * DumpRenderTree/TestRunner.h:
1696         * DumpRenderTree/mac/TestRunnerMac.mm:
1697         (TestRunner::setOnlyAcceptFirstPartyCookies):
1698         * DumpRenderTree/win/TestRunnerWin.cpp:
1699         (TestRunner::setOnlyAcceptFirstPartyCookies):
1700         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
1701         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
1702         (WTR::TestRunner::setOnlyAcceptFirstPartyCookies):
1703         * WebKitTestRunner/InjectedBundle/TestRunner.h:
1704         * WebKitTestRunner/TestInvocation.cpp:
1705         (WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):
1706
1707 2019-01-09  Matt Rajca  <mrajca@apple.com>
1708
1709         Put per-document autoplay behavior behind runtime website policies quirk instead of a compile time flag
1710         https://bugs.webkit.org/show_bug.cgi?id=193301
1711
1712         Reviewed by Jer Noble.
1713         
1714         Added API tests.
1715
1716         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
1717         * TestWebKitAPI/Tests/WebKitCocoa/WebsitePolicies.mm:
1718         (TEST):
1719         * TestWebKitAPI/Tests/WebKitCocoa/autoplaying-multiple-media-elements.html: Added.
1720
1721 2019-01-10  Zalan Bujtas  <zalan@apple.com>
1722
1723         [LFC][BFC][MarginCollapsing] Take collapsed through siblings into account when computing vertical position
1724         https://bugs.webkit.org/show_bug.cgi?id=193310
1725
1726         Reviewed by Antti Koivisto.
1727
1728         * LayoutReloaded/misc/LFC-passing-tests.txt:
1729
1730 2019-01-10  Dominik Infuehr  <dinfuehr@igalia.com>
1731
1732         Enable DFG on ARM/Linux again
1733         https://bugs.webkit.org/show_bug.cgi?id=192496
1734
1735         Reviewed by Yusuke Suzuki.
1736
1737         After changing the bytecode format DFG was disabled on all 32-bit
1738         architectures. Enable DFG now again on ARM/Linux. Run again JIT-tests
1739         on ARM by default.
1740
1741         * Scripts/run-jsc-stress-tests:
1742
1743 2019-01-09  Fujii Hironori  <Hironori.Fujii@sony.com>
1744
1745         [Win][MiniBrowser] wchar_t strings shouldn't be treated as BSTR
1746         https://bugs.webkit.org/show_bug.cgi?id=193271
1747
1748         Reviewed by Brent Fulgham.
1749
1750         BSTR is a special data structure created by SysAllocString, not a
1751         wchar_t null-terminated string.
1752
1753         * DumpRenderTree/win/TestRunnerWin.cpp:
1754         (TestRunner::setDatabaseQuota): Use L"" instead of "" for _bstr_t.
1755         * MiniBrowser/win/MiniBrowserWebHost.cpp:
1756         (MiniBrowserWebHost::didFinishLoadForFrame): Use _bstr_t to create
1757         BSTR from wide string literals.
1758
1759 2019-01-09  Alexey Proskuryakov  <ap@apple.com>
1760
1761         Tweak wording for build/version_check style checker error
1762         https://bugs.webkit.org/show_bug.cgi?id=193256
1763
1764         Reviewed by Tim Horton.
1765
1766         * Scripts/webkitpy/style/checkers/cpp.py:
1767         (check_os_version_checks):
1768         * Scripts/webkitpy/style/checkers/cpp_unittest.py:
1769         (WebKitStyleTest.test_os_version_checks):
1770
1771 2019-01-09  Aakash Jain  <aakash_jain@apple.com>
1772
1773         [ews-build] Add link to bug along with bug title
1774         https://bugs.webkit.org/show_bug.cgi?id=193293
1775
1776         Reviewed by Lucas Forschler.
1777
1778         * BuildSlaveSupport/ews-build/steps.py:
1779         (ValidatePatch._is_bug_closed): Fetch bug title from Bugzilla and add it to the build.
1780         (ConfigureBuild.add_bug_id_url): Deleted.
1781         (ConfigureBuild.getBugURL): Deleted.
1782
1783 2019-01-09  Aakash Jain  <aakash_jain@apple.com>
1784
1785         [ews-build] Use https for ews-build server
1786         https://bugs.webkit.org/show_bug.cgi?id=193193
1787
1788         Reviewed by Lucas Forschler.
1789
1790         * BuildSlaveSupport/ews-build/steps.py:
1791
1792 2019-01-09  Aakash Jain  <aakash_jain@apple.com>
1793
1794         [ews-build] Parse and display number of style failures
1795         https://bugs.webkit.org/show_bug.cgi?id=193280
1796
1797         Reviewed by Lucas Forschler.
1798
1799         * BuildSlaveSupport/ews-build/steps.py:
1800         (CheckStyle): Use TestWithFailureCount as base class.
1801         (CheckStyle.countFailures): Count the number of style failures.
1802
1803 2019-01-09  Aakash Jain  <aakash_jain@apple.com>
1804
1805         [ews-build] use patch_id instead of ewspatchid
1806         https://bugs.webkit.org/show_bug.cgi?id=193235
1807
1808         Reviewed by Lucas Forschler.
1809
1810         * BuildSlaveSupport/ews-build/factories.py: Replaced ewspatchid with patch_id.
1811         * BuildSlaveSupport/ews-build/steps.py: Ditto.
1812         * BuildSlaveSupport/ews-build/steps_unittest.py: Ditto.
1813
1814 2019-01-09  Zalan Bujtas  <zalan@apple.com>
1815
1816         [LFC][BFC][MarginCollapsing] Add support for peculiar cases.
1817         https://bugs.webkit.org/show_bug.cgi?id=192625
1818
1819         Reviewed by Antti Koivisto.
1820
1821         * LayoutReloaded/misc/LFC-passing-tests.txt:
1822
1823 2019-01-09  Michael Catanzaro  <mcatanzaro@igalia.com>
1824
1825         [WPE][GTK] Purge use of g_assert() under TestWebKitAPI
1826         https://bugs.webkit.org/show_bug.cgi?id=192841
1827
1828         Reviewed by Carlos Garcia Campos.
1829
1830         There are separate g_assert_*() macros for use in tests, which we use inconsistently
1831         currently. Use them always. We'll get nicer error messages now when tests fail, and the
1832         assertions will now run during tests even if G_DISABLE_ASSERT is used when building.
1833
1834         Note that the documentation of g_assert() says that it is not to be used when writing tests.
1835
1836         * TestWebKitAPI/Tests/JavaScriptCore/glib/TestJSC.cpp:
1837         * TestWebKitAPI/Tests/WebKitGLib/EditorTest.cpp:
1838         (WebKitWebEditorTest::testSelectionChanged):
1839         * TestWebKitAPI/Tests/WebKitGLib/FrameTest.cpp:
1840         (WebKitFrameTest::testMainFrame):
1841         (WebKitFrameTest::testURI):
1842         (WebKitFrameTest::testJavaScriptContext):
1843         (WebKitFrameTest::testJavaScriptValues):
1844         * TestWebKitAPI/Tests/WebKitGLib/TestAuthentication.cpp:
1845         (testWebViewAuthenticationRequest):
1846         (testWebViewAuthenticationLoadCancelled):
1847         (testWebViewAuthenticationFailure):
1848         (testWebViewAuthenticationStorage):
1849         (ProxyAuthenticationTest::ProxyAuthenticationTest):
1850         (testWebViewAuthenticationProxy):
1851         (testWebViewAuthenticationProxyHTTPS):
1852         * TestWebKitAPI/Tests/WebKitGLib/TestAutomationSession.cpp:
1853         (testAutomationSessionRequestSession):
1854         * TestWebKitAPI/Tests/WebKitGLib/TestBackForwardList.cpp:
1855         (testBackForwardListNavigation):
1856         (testWebKitWebViewSessionState):
1857         (testWebKitWebViewSessionStateWithFormData):
1858         * TestWebKitAPI/Tests/WebKitGLib/TestConsoleMessage.cpp:
1859         (ConsoleMessageTest::consoleMessageReceivedCallback):
1860         (testWebKitConsoleMessageConsoleAPI):
1861         (testWebKitConsoleMessageJavaScriptException):
1862         (testWebKitConsoleMessageNetworkError):
1863         (testWebKitConsoleMessageSecurityError):
1864         * TestWebKitAPI/Tests/WebKitGLib/TestCookieManager.cpp:
1865         (testCookieManagerAcceptPolicy):
1866         (testCookieManagerCookiesChanged):
1867         (testCookieManagerPersistentStorage):
1868         (testCookieManagerPersistentStorageDeleteAll):
1869         (testCookieManagerEphemeral):
1870         * TestWebKitAPI/Tests/WebKitGLib/TestDOMElement.cpp:
1871         (testWebKitDOMElementAutoFill):
1872         * TestWebKitAPI/Tests/WebKitGLib/TestDownloads.cpp:
1873         (downloadLocalFileSuccessfully):
1874         (createFileAtDestination):
1875         (testDownloadOverwriteDestinationDisallowed):
1876         (testDownloadLocalFileError):
1877         (testDownloadRemoteFile):
1878         (testDownloadRemoteFileError):
1879         (testWebViewDownloadURI):
1880         (testPolicyResponseDownload):
1881         (testPolicyResponseDownloadCancel):
1882         (testDownloadMIMEType):
1883         (contextMenuCallback):
1884         (testContextMenuDownloadActions):
1885         (testBlobDownload):
1886         * TestWebKitAPI/Tests/WebKitGLib/TestEditor.cpp:
1887         (testWebKitWebEditorSelectionChanged):
1888         * TestWebKitAPI/Tests/WebKitGLib/TestFrame.cpp:
1889         (testWebKitFrameMainFrame):
1890         (testWebKitFrameURI):
1891         (testWebKitFrameJavaScriptContext):
1892         (testWebKitFrameJavaScriptValues):
1893         * TestWebKitAPI/Tests/WebKitGLib/TestLoaderClient.cpp:
1894         (LoadStopTrackingTest::loadFailed):
1895         (testWebViewTitle):
1896         (testURIRequestHTTPHeaders):
1897         (testURIRequestHTTPMethod):
1898         (testURIResponseHTTPHeaders):
1899         (testRedirectToDataURI):
1900         * TestWebKitAPI/Tests/WebKitGLib/TestMultiprocess.cpp:
1901         (testProcessPerWebView):
1902         (testWebProcessLimit):
1903         * TestWebKitAPI/Tests/WebKitGLib/TestResources.cpp:
1904         (testWebViewResources):
1905         (testWebResourceLoading):
1906         (testWebResourceSuggestedFilename):
1907         (testWebResourceGetData):
1908         (testWebResourceGetDataError):
1909         (testWebViewResourcesHistoryCache):
1910         (testWebResourceSendRequest):
1911         * TestWebKitAPI/Tests/WebKitGLib/TestSSL.cpp:
1912         (testSSL):
1913         (testInsecureContent):
1914         (testTLSErrorsPolicy):
1915         (testTLSErrorsRedirect):
1916         (testTLSErrorsHTTPAuth):
1917         (testLoadFailedWithTLSErrors):
1918         (testSubresourceLoadFailedWithTLSErrors):
1919         (httpsServerCallback):
1920         * TestWebKitAPI/Tests/WebKitGLib/TestUIClient.cpp:
1921         (testWebViewCreateNavigationData):
1922         (testWebViewJavaScriptDialogs):
1923         (testWebViewWindowProperties):
1924         (testWebViewMouseTarget):
1925         (testWebViewFileChooserRequest):
1926         (testWebViewColorChooserRequest):
1927         * TestWebKitAPI/Tests/WebKitGLib/TestWebExtensions.cpp:
1928         (testWebExtensionGetTitle):
1929         (testDocumentLoadedSignal):
1930         (testWebKitWebViewProcessCrashed):
1931         (testWebExtensionWindowObjectCleared):
1932         (testWebExtensionIsolatedWorld):
1933         (permissionRequestCallback):
1934         (didAssociateFormControlsCallback):
1935         (testWebExtensionFormControlsAssociated):
1936         (FormSubmissionTest::FormSubmissionTest):
1937         (FormSubmissionTest::testFormSubmissionResult):
1938         (testWebExtensionFormSubmissionSteps):
1939         * TestWebKitAPI/Tests/WebKitGLib/TestWebKitFaviconDatabase.cpp:
1940         (testNotInitialized):
1941         (testClearDatabase):
1942         (testPrivateBrowsing):
1943         (testGetFavicon):
1944         (testWebViewFavicon):
1945         * TestWebKitAPI/Tests/WebKitGLib/TestWebKitFindController.cpp:
1946         (testFindControllerTextFound):
1947         (testFindControllerTextNotFound):
1948         (testFindControllerMatchCount):
1949         (testFindControllerMaxMatchCount):
1950         (testFindControllerNext):
1951         (testFindControllerPrevious):
1952         (testFindControllerCountedMatches):
1953         (testFindControllerOptions):
1954         (testFindControllerHide):
1955         (testFindControllerInstance):
1956         (testFindControllerGetters):
1957         * TestWebKitAPI/Tests/WebKitGLib/TestWebKitPolicyClient.cpp:
1958         (testNavigationPolicy):
1959         (testResponsePolicy):
1960         (testNewWindowPolicy):
1961         * TestWebKitAPI/Tests/WebKitGLib/TestWebKitSecurityOrigin.cpp:
1962         (testSecurityOriginBasicConstructor):
1963         (testSecurityOriginURIConstructor):
1964         (testSecurityOriginDefaultPort):
1965         (testSecurityOriginFileURI):
1966         (testOpaqueSecurityOrigin):
1967         * TestWebKitAPI/Tests/WebKitGLib/TestWebKitSettings.cpp:
1968         (testWebKitSettings):
1969         (testWebKitSettingsNewWithSettings):
1970         (testWebKitSettingsUserAgent):
1971         * TestWebKitAPI/Tests/WebKitGLib/TestWebKitUserContentManager.cpp:
1972         (testWebViewNewWithUserContentManager):
1973         (isStyleSheetInjectedForURLAtPath):
1974         (isScriptInjectedForURLAtPath):
1975         (testUserContentManagerInjectedStyleSheet):
1976         (testUserContentManagerInjectedScript):
1977         (UserScriptMessageTest::scriptMessageReceived):
1978         (UserScriptMessageTest::waitUntilMessageReceived):
1979         (UserScriptMessageTest::runJavaScriptFinished):
1980         (testUserContentManagerScriptMessageReceived):
1981         (testUserContentManagerScriptMessageInWorldReceived):
1982         (testUserContentManagerScriptMessageFromDOMBindings):
1983         * TestWebKitAPI/Tests/WebKitGLib/TestWebKitWebContext.cpp:
1984         (testWebContextDefault):
1985         (testWebContextEphemeral):
1986         (testWebContextGetPlugins):
1987         (testWebContextURIScheme):
1988         (testWebContextSpellChecker):
1989         (testWebContextLanguages):
1990         (consoleMessageReceivedCallback):
1991         (testWebContextSecurityFileXHR):
1992         (ProxyTest::ProxyTest):
1993         (testWebContextProxySettings):
1994         * TestWebKitAPI/Tests/WebKitGLib/TestWebKitWebView.cpp:
1995         (testWebViewWebContext):
1996         (testWebViewWebBackend):
1997         (testWebViewEphemeral):
1998         (testWebViewCustomCharset):
1999         (testWebViewSettings):
2000         (testWebViewRunJavaScript):
2001         (testWebViewCanShowMIMEType):
2002         (testWebViewSubmitForm):
2003         (testWebViewSave):
2004         (testWebViewPageVisibility):
2005         (testWebViewSnapshot):
2006         (testWebViewNotification):
2007         (testWebViewNotificationInitialPermissionAllowed):
2008         (testWebViewNotificationInitialPermissionDisallowed):
2009         (testWebViewIsPlayingAudio):
2010         * TestWebKitAPI/Tests/WebKitGLib/TestWebsiteData.cpp:
2011         (WebsiteDataTest::WebsiteDataTest):
2012         (WebsiteDataTest::remove):
2013         (WebsiteDataTest::clear):
2014         (testWebsiteDataConfiguration):
2015         (testWebsiteDataEphemeral):
2016         (testWebsiteDataCache):
2017         (testWebsiteDataStorage):
2018         (testWebsiteDataDatabases):
2019         (testWebsiteDataAppcache):
2020         (testWebsiteDataCookies):
2021         (testWebsiteDataDeviceIdHashSalt):
2022         * TestWebKitAPI/Tests/WebKitGLib/WebExtensionTest.cpp:
2023         (emitDocumentLoaded):
2024         (emitURIChanged):
2025         (sendRequestCallback):
2026         (contextMenuCallback):
2027         (consoleMessageSentCallback):
2028         (emitFormControlsAssociated):
2029         (formControlsAssociatedCallback):
2030         (emitFormSubmissionEvent):
2031         (willSubmitFormCallback):
2032         (windowObjectCleared):
2033         (methodCallCallback):
2034         (registerGResource):
2035         (webkit_web_extension_initialize_with_user_data):
2036         * TestWebKitAPI/Tests/WebKitGLib/WebProcessTest.cpp:
2037         (checkLeaks):
2038         (WebProcessTest::create):
2039         (runTest):
2040         * TestWebKitAPI/Tests/WebKitGtk/AutocleanupsTest.cpp:
2041         (AutocleanupsTest::testWebProcessAutocleanups):
2042         * TestWebKitAPI/Tests/WebKitGtk/DOMClientRectTest.cpp:
2043         (WebKitDOMClientRectTest::testDivBoundingClientRectPosition):
2044         (WebKitDOMClientRectTest::testDivClientRectsPositionAndLength):
2045         * TestWebKitAPI/Tests/WebKitGtk/DOMDOMWindowTest.cpp:
2046         (WebKitDOMDOMWindowTest::testSignals):
2047         (WebKitDOMDOMWindowTest::testDispatchEvent):
2048         (WebKitDOMDOMWindowTest::testGetComputedStyle):
2049         * TestWebKitAPI/Tests/WebKitGtk/DOMNodeFilterTest.cpp:
2050         (WebKitDOMNodeFilterTest::testTreeWalker):
2051         (WebKitDOMNodeFilterTest::testNodeIterator):
2052         * TestWebKitAPI/Tests/WebKitGtk/DOMNodeTest.cpp:
2053         (WebKitDOMNodeTest::testHierarchyNavigation):
2054         (WebKitDOMNodeTest::testInsertion):
2055         (WebKitDOMNodeTest::testTagNamesNodeList):
2056         (WebKitDOMNodeTest::testTagNamesHTMLCollection):
2057         (WebKitDOMNodeTest::testDOMCache):
2058         * TestWebKitAPI/Tests/WebKitGtk/DOMXPathNSResolverTest.cpp:
2059         (WebKitDOMXPathNSResolverTest::evaluateFooChildTextAndCheckResult):
2060         (WebKitDOMXPathNSResolverTest::testXPathNSResolverNative):
2061         (WebKitDOMXPathNSResolverTest::testXPathNSResolverCustom):
2062         * TestWebKitAPI/Tests/WebKitGtk/TestAutocleanups.cpp:
2063         (testUIProcessAutocleanups):
2064         (testWebProcessAutocleanups):
2065         * TestWebKitAPI/Tests/WebKitGtk/TestContextMenu.cpp:
2066         (testContextMenuPopulateMenu):
2067         (testContextMenuDismissed):
2068         * TestWebKitAPI/Tests/WebKitGtk/TestDOMClientRect.cpp:
2069         (testWebKitDOMClientRectDivBoundingClientRectPosition):
2070         (testWebKitDOMClientRectDivClientRectsPositionAndLength):
2071         * TestWebKitAPI/Tests/WebKitGtk/TestDOMDOMWindow.cpp:
2072         (testWebKitDOMDOMWindowSignals):
2073         (testWebKitDOMDOMWindowDispatchEvent):
2074         (testWebKitDOMDOMWindowGetComputedStyle):
2075         * TestWebKitAPI/Tests/WebKitGtk/TestDOMNode.cpp:
2076         (testWebKitDOMNodeHierarchyNavigation):
2077         (testWebKitDOMNodeInsertion):
2078         (testWebKitDOMNodeTagNamesNodeList):
2079         (testWebKitDOMNodeTagNamesHTMLCollection):
2080         (testWebKitDOMObjectCache):
2081         * TestWebKitAPI/Tests/WebKitGtk/TestDOMNodeFilter.cpp:
2082         (testWebKitDOMNodeFilterTreeWalker):
2083         (testWebKitDOMNodeFilterNodeIterator):
2084         * TestWebKitAPI/Tests/WebKitGtk/TestDOMXPathNSResolver.cpp:
2085         (testWebKitDOMXPathNSResolverNative):
2086         (testWebKitDOMXPathNSResolverCustom):
2087         * TestWebKitAPI/Tests/WebKitGtk/TestInspector.cpp:
2088         (testInspectorDefault):
2089         (testInspectorManualAttachDetach):
2090         (testInspectorCustomContainerDestroyed):
2091         * TestWebKitAPI/Tests/WebKitGtk/TestInspectorServer.cpp:
2092         (startTestServer):
2093         (testInspectorServerPageList):
2094         * TestWebKitAPI/Tests/WebKitGtk/TestOptionMenu.cpp:
2095         (OptionMenuTest::showOptionMenuCallback):
2096         (OptionMenuTest::menuCloseCallback):
2097         (OptionMenuTest::close):
2098         (OptionMenuTest::activateItem):
2099         (OptionMenuTest::selectItem):
2100         (testOptionMenuSimple):
2101         (testOptionMenuGroups):
2102         (testOptionMenuActivate):
2103         (testOptionMenuSelect):
2104         * TestWebKitAPI/Tests/WebKitGtk/TestPrinting.cpp:
2105         (testPrintOperationPrintSettings):
2106         (webViewPrintCallback):
2107         (testPrintOperationPrint):
2108         (testPrintCustomWidget):
2109         * TestWebKitAPI/Tests/WebKitGtk/TestWebKitAccessibility.cpp:
2110         (checkAtspiAccessible):
2111         (testAtspiBasicHierarchy):
2112         * TestWebKitAPI/Tests/WebKitGtk/TestWebKitVersion.cpp:
2113         (testWebKitCheckVersion):
2114         * TestWebKitAPI/Tests/WebKitGtk/TestWebViewEditor.cpp:
2115         (testWebViewEditorCutCopyPasteNonEditable):
2116         (testWebViewEditorCutCopyPasteEditable):
2117         (testWebViewEditorSelectAllNonEditable):
2118         (testWebViewEditorSelectAllEditable):
2119         (loadContentsAndTryToCutSelection):
2120         (testWebViewEditorNonEditable):
2121         (testWebViewEditorEditable):
2122         (testWebViewEditorEditorStateTypingAttributes):
2123         (testWebViewEditorInsertImage):
2124         (testWebViewEditorCreateLink):
2125         * TestWebKitAPI/glib/WebKitGLib/LoadTrackingTest.cpp:
2126         (loadChangedCallback):
2127         (loadFailedCallback):
2128         (loadFailedWithTLSErrorsCallback):
2129         (LoadTrackingTest::LoadTrackingTest):
2130         * TestWebKitAPI/glib/WebKitGLib/TestMain.cpp:
2131         (registerGResource):
2132         (removeNonEmptyDirectory):
2133         * TestWebKitAPI/glib/WebKitGLib/TestMain.h:
2134         (Test::adoptView):
2135         (Test::~Test):
2136         * TestWebKitAPI/glib/WebKitGLib/WebKitTestBus.cpp:
2137         (WebKitTestBus::getOrCreateConnection):
2138         (WebKitTestBus::createProxy):
2139         * TestWebKitAPI/glib/WebKitGLib/WebKitTestServer.cpp:
2140         (WebKitTestServer::getWebSocketURIForPath const):
2141         * TestWebKitAPI/glib/WebKitGLib/WebViewTest.cpp:
2142         (WebViewTest::initializeWebView):
2143         (WebViewTest::loadURI):
2144         (WebViewTest::loadHtml):
2145         (WebViewTest::loadPlainText):
2146         (WebViewTest::loadBytes):
2147         (WebViewTest::loadRequest):
2148         (WebViewTest::loadAlternateHTML):
2149         (WebViewTest::goBack):
2150         (WebViewTest::goForward):
2151         (WebViewTest::goToBackForwardListItem):
2152         (resourceGetDataCallback):
2153         (WebViewTest::mainResourceData):
2154         (WebViewTest::javascriptResultToCString):
2155         (WebViewTest::javascriptResultToNumber):
2156         (WebViewTest::javascriptResultToBoolean):
2157         (WebViewTest::javascriptResultIsNull):
2158         (WebViewTest::javascriptResultIsUndefined):
2159         (onSnapshotReady):
2160         (WebViewTest::runWebProcessTest):
2161         * TestWebKitAPI/glib/WebKitGLib/gtk/WebViewTestGtk.cpp:
2162         (WebViewTest::platformInitializeWebView):
2163         (WebViewTest::showInWindow):
2164         (WebViewTest::showInWindowAndWaitUntilMapped):
2165         (WebViewTest::mouseMoveTo):
2166         (WebViewTest::emitPopupMenuSignal):
2167         (WebViewTest::keyStroke):
2168         (WebViewTest::doMouseButtonEvent):
2169
2170 2019-01-09  Philippe Normand  <pnormand@igalia.com>
2171
2172         [WPE] API tests can't run in flatpak environment
2173         https://bugs.webkit.org/show_bug.cgi?id=193242
2174
2175         Reviewed by Michael Catanzaro.
2176
2177         * Scripts/run-wpe-tests: Add --wpe to arguments passed to
2178         flatpakutils so that it knows which port it's dealing with.
2179         * glib/common.py: Remove build_dir globals so that subsequent
2180         calls actually take args into account.
2181         (library_build_path):
2182         (binary_build_path):
2183
2184 2019-01-08  Dean Jackson  <dino@apple.com>
2185
2186         Blob references for System Previews don't get a correct file extension
2187         https://bugs.webkit.org/show_bug.cgi?id=193268
2188         <rdar://problem/47133037>
2189
2190         Reviewed by Tim Horton.
2191
2192         New test that a Blob download of a USDZ file gets named correctly.
2193
2194         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
2195         * TestWebKitAPI/Tests/WebKitCocoa/Download.mm:
2196         (-[BlobWithUSDZExtensionDownloadDelegate _download:decideDestinationWithSuggestedFilename:completionHandler:]):
2197         (-[BlobWithUSDZExtensionDownloadDelegate _downloadDidFinish:]):
2198         (TEST):
2199         * TestWebKitAPI/Tests/WebKitCocoa/SystemPreviewBlobNaming.html: Added.
2200
2201 2019-01-08  Jiewen Tan  <jiewen_tan@apple.com>
2202
2203         [WebAuthN] Support U2F HID Authenticators on macOS
2204         https://bugs.webkit.org/show_bug.cgi?id=191535
2205         <rdar://problem/47102027>
2206
2207         Reviewed by Brent Fulgham.
2208
2209         This patch:
2210         1) adds support for U2F mocking mechanism;
2211         2) updates tests to reflect U2fCommandConstructor changes.
2212
2213         * TestWebKitAPI/Tests/WebCore/CtapResponseTest.cpp:
2214         (TestWebKitAPI::TEST):
2215         * TestWebKitAPI/Tests/WebCore/FidoTestData.h:
2216         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
2217         (WTR::TestRunner::setWebAuthenticationMockConfiguration):
2218
2219 2019-01-08  Wenson Hsieh  <wenson_hsieh@apple.com>
2220
2221         [iOS] Dispatch a synthetic mousedown event prior to starting drags
2222         https://bugs.webkit.org/show_bug.cgi?id=193229
2223         <rdar://problem/46717097>
2224
2225         Reviewed by Tim Horton.
2226
2227         Add a cross-platform drag and drop test to verify that calling `preventDefault()` on the mousedown event
2228         prevents a drag from starting.
2229
2230         * TestWebKitAPI/Tests/WebKitCocoa/DragAndDropTests.mm:
2231         * TestWebKitAPI/Tests/WebKitCocoa/link-and-target-div.html:
2232
2233         Tweak this test to make it robust when dragging the link to the target element multiple times in a single test.
2234
2235 2019-01-08  Zhifei Fang  <zhifei_fang@apple.com>
2236   
2237         Layout test will generate a perf metric file to results dir.
2238         https://bugs.webkit.org/show_bug.cgi?id=192030
2239         <rdar://problem/32779516>
2240
2241         Reviewed by Aakash Jain.
2242
2243         Layout test running time will be collected to a perf metric file.
2244         For now, instead of outputing running time of all tests (which is huge),
2245         we aggregate them by test directories which are at most two level deep. 
2246
2247         * Scripts/webkitpy/layout_tests/controllers/manager.py:
2248         (Manager._end_test_run):
2249         (Manager._output_perf_metrics):
2250         (Manager._print_expectation_line_for_test):
2251         * Scripts/webkitpy/layout_tests/layout_package/json_results_generator.py:
2252         (add_test_perf_metric):
2253         (test_perf_metrics):
2254         * Scripts/webkitpy/layout_tests/layout_package/json_results_generator_unittest.py:
2255         (JSONGeneratorTest.test_test_timings_trie):
2256         (JSONGeneratorTest):
2257         (JSONGeneratorTest.test_test_perf_metrics):
2258         * Scripts/webkitpy/layout_tests/run_webkit_tests_integrationtest.py:
2259         (RebaselineTest.test_reset_results):
2260         (RebaselineTest.test_missing_results):
2261         (RebaselineTest.test_new_baseline):
2262
2263 2019-01-08  Patrick Griffis  <pgriffis@igalia.com>
2264
2265         [WPE][GTK] Add php-json to install-dependencies
2266         https://bugs.webkit.org/show_bug.cgi?id=193233
2267
2268         Reviewed by Michael Catanzaro.
2269
2270         * gtk/install-dependencies:
2271         * wpe/install-dependencies:
2272
2273 2019-01-08  Chris Dumez  <cdumez@apple.com>
2274
2275         Regression(PSON-r239182): Blank view when navigating back and forth between google.com and stack overflow
2276         https://bugs.webkit.org/show_bug.cgi?id=193224
2277         <rdar://problem/47097726>
2278
2279         Reviewed by Alex Christensen.
2280
2281         Add API test coverage.
2282
2283         * TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
2284
2285 2019-01-07  David Kilzer  <ddkilzer@apple.com>
2286
2287         Leak of ScrollCompletionCallbackData (16 bytes) in com.apple.WebKit.WebContent running WebKit layout tests
2288         <https://webkit.org/b/193222>
2289         <rdar://problem/46862309>
2290
2291         Reviewed by Joseph Pecoraro.
2292
2293         * WebKitTestRunner/InjectedBundle/EventSendingController.cpp:
2294         (WTR::executeCallback): Fix camel case of variable name.
2295         (WTR::EventSendingController::callAfterScrollingCompletes): If
2296         WKBundlePageRegisterScrollOperationCompletionCallback() returns
2297         false, make sure to release the ScrollCompletionCallbackData
2298         object.  This fixes the leak.
2299
2300 2019-01-07  Fujii Hironori  <Hironori.Fujii@sony.com>
2301
2302         [Win] EWS: wincairo-ews cannot apply a patch with *.png
2303         https://bugs.webkit.org/show_bug.cgi?id=193044
2304
2305         Reviewed by Daniel Bates.
2306
2307         WinCairo EWS bots are using Windows Perl. Binary files should be
2308         opened as binary mode.
2309
2310         * Scripts/svn-apply:
2311         (handleGitBinaryChange): Use 'binmode' for binary file handles.
2312
2313 2019-01-07  Don Olmstead  <don.olmstead@sony.com>
2314
2315         [CMake] Add ENABLE_CSS_TYPED_OM option
2316         https://bugs.webkit.org/show_bug.cgi?id=193216
2317
2318         Reviewed by Michael Catanzaro.
2319
2320         * Scripts/webkitperl/FeatureList.pm:
2321
2322 2019-01-07  David Kilzer  <ddkilzer@apple.com>
2323
2324         Prefer RetainPtr<NSObject> to RetainPtr<NSObject *>
2325         <https://webkit.org/b/193056>
2326
2327         Reviewed by Alex Christensen.
2328
2329         * Scripts/webkitpy/style/checker.py:
2330         - Ignore use of new runtime/retainptr check in
2331           Tools/TestWebKitAPI/Tests/WTF/ns/RetainPtr.mm since it
2332           contains tests to ensure RetainPtr<NSObject *> is compatible
2333           with RetainPtr<NSObject>.
2334
2335         * Scripts/webkitpy/style/checkers/cpp.py:
2336         (check_language):
2337         (CppChecker):
2338         - Add checker for use of '*' in RetainPtr<> type.  A for loop
2339           was used instead of a single regex so that angle brackets
2340           could be matched up when checking the type contained within
2341           the RetainPtr<> type.
2342
2343         * Scripts/webkitpy/style/checkers/cpp_unittest.py:
2344         (CppStyleTest):
2345         - Add unit test for new runtime/retainptr check.
2346
2347         * TestRunnerShared/EventSerialization/mac/EventSerializerMac.h:
2348         * TestWebKitAPI/EditingTestHarness.h:
2349         - Remove '*' from RetainPtr<> type.
2350
2351         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
2352         - Add cf/RetainPtr.cpp back to TestWTFLibrary target!  This
2353           regressed in r201938.
2354
2355         * TestWebKitAPI/Tests/WTF/cf/RetainPtr.cpp:
2356         (TestWebKitAPI::TEST):
2357         - Update tests to match RetainPtr.mm tests (except for the
2358           `*SimilarNSType` tests since there is no CF equivalent of
2359           RetainPtr<NSString> and RetainPtr<NSString *>).
2360
2361         * TestWebKitAPI/Tests/WTF/ns/RetainPtr.mm:
2362         (TestWebKitAPI::TEST):
2363         - Update tests to:
2364           - Not conflict by name with equivalent CF tests in
2365             RetainPtr.cpp.
2366           - Add test cases for RetainPtr<NSObject>,
2367             RetainPtr<NSObject *> and RetainPtr<id> were appropriate.
2368           - Add `*SimilarNSType` tests for converting between
2369             RetainPtr<NSObject> and RetainPtr<NSObject *>.
2370           - Change `0` to `nil` as appropriate.
2371           - Re-alphabetize the tests by name.
2372           - Add Optional<RetainPtr<>> tests.
2373           - Add retainPtr() tests.
2374
2375         * TestWebKitAPI/Tests/WebKitCocoa/DownloadProgress.mm:
2376         (-[DownloadProgressTestRunner _download:decideDestinationWithSuggestedFilename:completionHandler:]):
2377         * TestWebKitAPI/Tests/WebKitCocoa/IconLoadingDelegate.mm:
2378         (TEST):
2379         - Remove '*' from RetainPtr<> type.
2380
2381         * TestWebKitAPI/Tests/WebKitCocoa/JITEnabled.mm:
2382         (TEST(WebKit, JITEnabled)):
2383         - Add missing WTFMove().  Apparently a temporary was being
2384           created before in the argument list due to mismatched
2385           RetainPtr<> types.
2386
2387         * TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
2388         * TestWebKitAPI/Tests/WebKitCocoa/VideoControlsManager.mm:
2389         (TestWebKitAPI::setUpWebViewForTestingVideoControlsManager):
2390         (TestWebKitAPI::TEST):
2391         * TestWebKitAPI/Tests/WebKitCocoa/WebsitePolicies.mm:
2392         * TestWebKitAPI/ios/DragAndDropSimulatorIOS.mm:
2393         * WebKitTestRunner/InjectedBundle/cocoa/ActivateFontsCocoa.mm:
2394         (WTR::resourcesDirectoryURL):
2395         * WebKitTestRunner/InjectedBundle/ios/InjectedBundleIOS.mm:
2396         (WTR::InjectedBundle::platformInitialize):
2397         * WebKitTestRunner/cocoa/TestRunnerWKWebView.mm:
2398         - Remove '*' from RetainPtr<> type.
2399
2400 2019-01-07  Eric Carlson  <eric.carlson@apple.com>
2401
2402         A MediaTime timescale must never be zero
2403         https://bugs.webkit.org/show_bug.cgi?id=193156
2404         <rdar://problem/32504501>
2405
2406         Reviewed by Jer Noble.
2407
2408         * TestWebKitAPI/Tests/WTF/MediaTime.cpp:
2409         (TestWebKitAPI::TEST): Add tests for zero timescale.
2410
2411 2019-01-07  Youenn Fablet  <youenn@apple.com>
2412
2413         API test broken: TestWebKitAPI.WebKit.CustomDataStorePathsVersusCompletionHandlers
2414         https://bugs.webkit.org/show_bug.cgi?id=193175
2415
2416         Reviewed by Chris Dumez.
2417
2418         Updated API test as we bumped the SW schema to version 4.
2419
2420         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
2421         * TestWebKitAPI/Tests/WebKitCocoa/SimpleServiceWorkerRegistrations-4.sqlite3: Renamed from Tools/TestWebKitAPI/Tests/WebKitCocoa/SimpleServiceWorkerRegistrations-3.sqlite3.
2422         * TestWebKitAPI/Tests/WebKitCocoa/WebsiteDataStoreCustomPaths.mm:
2423         (TEST):
2424
2425 2019-01-06  Fujii Hironori  <Hironori.Fujii@sony.com>
2426
2427         [Win][Clang] Fix compilation warnings of MiniBrowser
2428         https://bugs.webkit.org/show_bug.cgi?id=193029
2429
2430         Reviewed by Ross Kirsling.
2431
2432         * MiniBrowser/win/MiniBrowserWebHost.h: Removed unused m_oldFont
2433         and m_URLBarFont. Reorder member variables to fix -Wreorder
2434         warning.
2435         * MiniBrowser/win/PageLoadTestClient.cpp:
2436         (PageLoadTestClient::PageLoadTestClient): Reorder the member initializer list.
2437         * MiniBrowser/win/PageLoadTestClient.h: Removed 'virtual' of
2438         pageLoadStartedAtTime and pageLoadEndedAtTime. Removed unused
2439         m_currentURLIndex.
2440         * MiniBrowser/win/WebKitBrowserWindow.cpp:
2441         (WebKitBrowserWindow::WebKitBrowserWindow): Initialize
2442         navigationClient with '{ }' to fix the missing field warning.
2443         * MiniBrowser/win/WebKitLegacyBrowserWindow.cpp:
2444         (initDocStruct): Changed the argument type docname to const.
2445
2446 2019-01-06  Jiewen Tan  <jiewen_tan@apple.com>
2447
2448         [WebAuthN] Import U2F command/response converters from Chromium
2449         https://bugs.webkit.org/show_bug.cgi?id=193150
2450         <rdar://problem/47054028>
2451
2452         Reviewed by Brent Fulgham.
2453
2454         Adds API tests.
2455
2456         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
2457         * TestWebKitAPI/Tests/WebCore/CtapResponseTest.cpp:
2458         (TestWebKitAPI::getTestAttestedCredentialDataBytes):
2459         (TestWebKitAPI::getTestAuthenticatorDataBytes):
2460         (TestWebKitAPI::getTestAttestationObjectBytes):
2461         (TestWebKitAPI::getTestSignResponse):
2462         (TestWebKitAPI::getTestU2fRegisterResponse):
2463         (TestWebKitAPI::TEST):
2464         (TestWebKitAPI::convertToVector): Deleted.
2465         * TestWebKitAPI/Tests/WebCore/FidoTestData.h:
2466         * TestWebKitAPI/Tests/WebCore/U2fCommandConstructorTest.cpp: Added.
2467         (TestWebKitAPI::constructMakeCredentialRequest):
2468         (TestWebKitAPI::constructGetAssertionRequest):
2469         (TestWebKitAPI::TEST):
2470
2471 2019-01-05  Oriol Brufau  <obrufau@igalia.com>
2472
2473         [GTK] Add python3-setuptools, libunistring-dev, bison and flex dependencies
2474         https://bugs.webkit.org/show_bug.cgi?id=193136
2475
2476         Reviewed by Michael Catanzaro.
2477
2478         * gtk/install-dependencies:
2479         Add python3-setuptools, libunistring-dev, bison and flex to install-dependencies,
2480         they are needed by update-webkitgtk-libs.
2481
2482 2019-01-05  Aakash Jain  <aakash_jain@apple.com>
2483
2484         Unreviewed follow-up fix to r239650
2485         https://bugs.webkit.org/show_bug.cgi?id=193140
2486         <rdar://problem/47063037>
2487
2488         Typecast patch_id to string.
2489
2490         * BuildSlaveSupport/ews-build/steps.py:
2491         (ValidatePatch._is_patch_obsolete):
2492
2493 2019-01-04  Daniel Bates  <dabates@apple.com>
2494
2495         [lldb-webkit]: Add support for pretty-printing raw bitmask types
2496         https://bugs.webkit.org/show_bug.cgi?id=193024
2497
2498         Reviewed by Jer Noble.
2499
2500         Add support infrastructure to pretty-print a raw bitmask type. Included is a pretty-printer
2501         for the bitmask type WebEventFlags as an example.
2502
2503         Exposed a new function lldb_webkit.addSummaryAndSyntheticFormattersForRawBitmaskType()
2504         that can be used to register summary and synthetic child formatters for a bitmask type.
2505         For example, consider the following enum and bitmask typedefs:
2506
2507         typedef enum {
2508             A = 1 << 0,
2509             B = 1 << 1,
2510             C = 1 << 2,
2511         } SpecialFlagValues;
2512         typedef unsigned SpecialFlags;
2513
2514         To teach lldb-webkit how to pretty print SpecialFlags types, add the following code inside
2515         __lldb_init_module():
2516
2517             addSummaryAndSyntheticFormattersForRawBitmaskType(debugger, "SpecialFlags", {
2518                     1 << 0: "A",
2519                     1 << 1: "B",
2520                     1 << 2: "C",
2521             })
2522
2523         * lldb/lldb_webkit.py:
2524         (addSummaryAndSyntheticFormattersForRawBitmaskType):
2525         (addSummaryAndSyntheticFormattersForRawBitmaskType.GeneratedRawBitmaskProvider):
2526         (addSummaryAndSyntheticFormattersForRawBitmaskType.raw_bitmask_summary_provider):
2527         (addSummaryAndSyntheticFormattersForRawBitmaskType.lldb_webkit):
2528         A convenience function to dynamically creaste a synthetic formatter class and summary
2529         string function for the specified bitmask type and enumerator value to name map. This
2530         function register the dynamically created class and function with LLDB.
2531
2532         (__lldb_init_module):
2533         (FlagEnumerationProvider):
2534         (FlagEnumerationProvider._enumerator_value_to_name_map):
2535         (FlagEnumerationProvider._bitmask):
2536         (FlagEnumerationProvider._update):
2537         (FlagEnumerationProvider.has_children):
2538         (FlagEnumerationProvider.num_children):
2539         (FlagEnumerationProvider.get_child_index):
2540         (FlagEnumerationProvider.get_child_at_index):
2541         (FlagEnumerationProvider.update):
2542         Extract out provider logic from WTFOptionSetProvider into a base class that can be shared.
2543
2544         (WTFOptionSetProvider):
2545         (WTFOptionSetProvider._enumerator_value_to_name_map):
2546         (WTFOptionSetProvider._bitmask):
2547         (WTFOptionSetProvider._update):
2548         Write in terms of the base class.
2549
2550         (RawBitmaskProviderBase):
2551         (RawBitmaskProviderBase._enumerator_value_to_name_map):
2552         (RawBitmaskProviderBase._bitmask):
2553         Added. Base synthetic formatter class for a raw bitmask type. Derived classes are expected to
2554         override the class variable ENUMERATOR_VALUE_TO_NAME_MAP with a dictionary of the form:
2555         {
2556             1 << 0: "A",
2557             1 << 1: "B",
2558             1 << 2: "C",
2559         }
2560         It is not necessary to instantiate such a derived class directory. Instead use the convenience
2561         function addSummaryAndSyntheticFormattersForRawBitmaskType.
2562
2563         (WTFOptionSetProvider.has_children): Deleted.
2564         (WTFOptionSetProvider.num_children): Deleted.
2565         (WTFOptionSetProvider.get_child_index): Deleted.
2566         (WTFOptionSetProvider.get_child_at_index): Deleted.
2567         (WTFOptionSetProvider.update): Deleted.
2568
2569 2019-01-04  Aakash Jain  <aakash_jain@apple.com>
2570
2571         [ews-build] Add build step to validate the patch before processing it
2572         https://bugs.webkit.org/show_bug.cgi?id=193140
2573
2574         Reviewed by Lucas Forschler.
2575
2576         * BuildSlaveSupport/ews-build/factories.py:
2577         (Factory.__init__): Added ValidatePatch step.
2578         * BuildSlaveSupport/ews-build/steps.py:
2579         (ValidatePatch):
2580         (ValidatePatch.fetch_data_from_url): Fetch data from a url.
2581         (ValidatePatch.get_patch_json): Get patch json data.
2582         (ValidatePatch.get_bug_json): Get bug json data.
2583         (ValidatePatch.get_bug_id_from_patch): Get bug id from a patch id.
2584         (ValidatePatch._is_patch_obsolete): Check if the patch is obsolete.
2585         (ValidatePatch._is_patch_review_denied): Check if the patch is marked r-.
2586         (ValidatePatch._is_bug_closed): Check if the bug is already closed.
2587         (ValidatePatch.skip_build): Skip the build.
2588         (ValidatePatch.start):
2589
2590 2019-01-04  Alex Christensen  <achristensen@webkit.org>
2591
2592         Progress towards fixing Mac CMake build
2593         https://bugs.webkit.org/show_bug.cgi?id=193105
2594
2595         Reviewed by Don Olmstead.
2596
2597         * TestWebKitAPI/PlatformMac.cmake:
2598
2599 2019-01-04  Alex Christensen  <achristensen@webkit.org>
2600
2601         Fix API test after r239631
2602         https://bugs.webkit.org/show_bug.cgi?id=193118
2603
2604         * TestWebKitAPI/Tests/WebKit/UserMedia.cpp:
2605         (TestWebKitAPI::TEST):
2606         This test relied on m_maximumProcessCount being set to 1 in ProcessPoolConfiguration::createWithLegacyOptions.
2607         Do the same thing via the API to fix the test.
2608
2609 2019-01-04  Jer Noble  <jer.noble@apple.com>
2610
2611         [WebKitLegacy] Media playback pauses on scroll
2612         https://bugs.webkit.org/show_bug.cgi?id=192829
2613
2614         Reviewed by Eric Carlson.
2615
2616         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
2617         * TestWebKitAPI/Tests/WebKitCocoa/StopSuspendResumeAllMedia.mm: Added.
2618         (TestWebKitAPI::TEST):
2619         * TestWebKitAPI/Tests/WebKitLegacy/ios/ScrollingDoesNotPauseMedia.mm: Added.
2620         (-[ScrollingDoesNotPauseMediaDelegate webViewDidFinishLoad:]):
2621         (-[ScrollingDoesNotPauseMediaDelegate uiWebView:didCommitLoadForFrame:]):
2622         (-[ScrollingDoesNotPauseMediaDelegate handleEvent:]):
2623         (TestWebKitAPI::TEST):
2624
2625 2019-01-04  Chris Dumez  <cdumez@apple.com>
2626
2627         Add support for toggling device orientation API support per site
2628         https://bugs.webkit.org/show_bug.cgi?id=193143
2629         <rdar://problem/46605724>
2630
2631         Reviewed by Alex Christensen.
2632
2633         Add API test coverage.
2634
2635         * TestWebKitAPI/Tests/WebKitCocoa/WebsitePolicies.mm:
2636         (-[DataMappingSchemeHandler setTaskHandler:]):
2637         (-[DataMappingSchemeHandler webView:startURLSchemeTask:]):
2638         (-[WebsitePoliciesDeviceOrientationDelegate initWithDeviceOrientationEventEnabled:]):
2639         (-[WebsitePoliciesDeviceOrientationDelegate _webView:decidePolicyForNavigationAction:userInfo:decisionHandler:]):
2640         (-[WebsitePoliciesDeviceOrientationDelegate webView:didFinishNavigation:]):
2641
2642 2019-01-04  Aakash Jain  <aakash_jain@apple.com>
2643
2644         [ews-build] use svn-apply script to apply the patches
2645         https://bugs.webkit.org/show_bug.cgi?id=193138
2646
2647         Reviewed by Lucas Forschler.
2648
2649         * BuildSlaveSupport/ews-build/factories.py:
2650         (Factory.__init__): Add the ApplyPatch step.
2651         * BuildSlaveSupport/ews-build/steps.py:
2652         (CheckOutSource): Added step name.
2653         (CheckOutSource.__init__): Used alwaysUseLatest so that it doesn't apply patch.
2654         (ApplyPatch): Build step to apply patch using svn-apply script.
2655         (UnApplyPatchIfRequired):
2656         (UnApplyPatchIfRequired.__init__): Deleted, since the alwaysUseLatest parameter is now in base class.
2657
2658 2019-01-04  Alex Christensen  <achristensen@webkit.org>
2659
2660         Deprecate WKContextCreate
2661         https://bugs.webkit.org/show_bug.cgi?id=193118
2662
2663         Reviewed by Brady Eidson.
2664
2665         * MiniBrowser/win/WebKitBrowserWindow.cpp:
2666         (WebKitBrowserWindow::WebKitBrowserWindow):
2667         * TestWebKitAPI/Tests/WebKit/AboutBlankLoad.cpp:
2668         (TestWebKitAPI::TEST):
2669         * TestWebKitAPI/Tests/WebKit/CloseFromWithinCreatePage.cpp:
2670         (TestWebKitAPI::TEST):
2671         * TestWebKitAPI/Tests/WebKit/CloseThenTerminate.cpp:
2672         (TestWebKitAPI::TEST):
2673         * TestWebKitAPI/Tests/WebKit/CookieManager.cpp:
2674         (TestWebKitAPI::TEST):
2675         * TestWebKitAPI/Tests/WebKit/DownloadDecideDestinationCrash.cpp:
2676         (TestWebKitAPI::TEST):
2677         * TestWebKitAPI/Tests/WebKit/EnumerateMediaDevices.cpp:
2678         (TestWebKitAPI::TEST):
2679         * TestWebKitAPI/Tests/WebKit/EphemeralSessionPushStateNoHistoryCallback.cpp:
2680         (TestWebKitAPI::TEST):
2681         * TestWebKitAPI/Tests/WebKit/EvaluateJavaScript.cpp:
2682         (TestWebKitAPI::TEST):
2683         * TestWebKitAPI/Tests/WebKit/EventModifiers.cpp:
2684         (TestWebKitAPI::TEST):
2685         * TestWebKitAPI/Tests/WebKit/FailedLoad.cpp:
2686         (TestWebKitAPI::TEST):
2687         * TestWebKitAPI/Tests/WebKit/Find.cpp:
2688         (TestWebKitAPI::TEST):
2689         * TestWebKitAPI/Tests/WebKit/FindMatches.mm:
2690         (TestWebKitAPI::TEST):
2691         * TestWebKitAPI/Tests/WebKit/ForceRepaint.cpp:
2692         (TestWebKitAPI::TEST):
2693         * TestWebKitAPI/Tests/WebKit/FrameHandle.cpp:
2694         (TestWebKitAPI::TEST):
2695         * TestWebKitAPI/Tests/WebKit/FrameMIMETypeHTML.cpp:
2696         (TestWebKitAPI::TEST):
2697         * TestWebKitAPI/Tests/WebKit/FrameMIMETypePNG.cpp:
2698         (TestWebKitAPI::TEST):
2699         * TestWebKitAPI/Tests/WebKit/Geolocation.cpp:
2700         (TestWebKitAPI::TEST):
2701         * TestWebKitAPI/Tests/WebKit/LayoutMilestonesWithAllContentInFrame.cpp:
2702         (TestWebKitAPI::TEST):
2703         * TestWebKitAPI/Tests/WebKit/LoadAlternateHTMLStringWithNonDirectoryURL.cpp:
2704         (TestWebKitAPI::loadAlternateHTMLString):
2705         * TestWebKitAPI/Tests/WebKit/LoadPageOnCrash.cpp:
2706         (TestWebKitAPI::WebKit2CrashLoader::WebKit2CrashLoader):
2707         * TestWebKitAPI/Tests/WebKit/MenuTypesForMouseEvents.cpp:
2708         (TestWebKitAPI::buildAndPerformTest):
2709         * TestWebKitAPI/Tests/WebKit/ModalAlertsSPI.cpp:
2710         (TestWebKitAPI::TEST):
2711         * TestWebKitAPI/Tests/WebKit/NavigationClientDefaultCrypto.cpp:
2712         (TestWebKitAPI::TEST):
2713         * TestWebKitAPI/Tests/WebKit/PageGroup.cpp:
2714         (TestWebKitAPI::TEST):
2715         * TestWebKitAPI/Tests/WebKit/PageLoadBasic.cpp:
2716         (TestWebKitAPI::TEST):
2717         * TestWebKitAPI/Tests/WebKit/PageLoadDidChangeLocationWithinPageForFrame.cpp:
2718         (TestWebKitAPI::TEST):
2719         * TestWebKitAPI/Tests/WebKit/PendingAPIRequestURL.cpp:
2720         (TestWebKitAPI::TEST):
2721         * TestWebKitAPI/Tests/WebKit/PreventEmptyUserAgent.cpp:
2722         (TestWebKitAPI::TEST):
2723         * TestWebKitAPI/Tests/WebKit/PrivateBrowsingPushStateNoHistoryCallback.cpp:
2724         (TestWebKitAPI::TEST):
2725         * TestWebKitAPI/Tests/WebKit/ProcessDidTerminate.cpp:
2726         (TestWebKitAPI::TEST):
2727         * TestWebKitAPI/Tests/WebKit/ReloadPageAfterCrash.cpp:
2728         (TestWebKitAPI::TEST):
2729         * TestWebKitAPI/Tests/WebKit/ResizeReversePaginatedWebView.cpp:
2730         (TestWebKitAPI::TEST):
2731         * TestWebKitAPI/Tests/WebKit/ResizeWindowAfterCrash.cpp:
2732         (TestWebKitAPI::TEST):
2733         * TestWebKitAPI/Tests/WebKit/RestoreSessionState.cpp:
2734         (TestWebKitAPI::TEST):
2735         * TestWebKitAPI/Tests/WebKit/RestoreSessionStateContainingFormData.cpp:
2736         (TestWebKitAPI::TEST):
2737         * TestWebKitAPI/Tests/WebKit/ScrollPinningBehaviors.cpp:
2738         (TestWebKitAPI::TEST):
2739         * TestWebKitAPI/Tests/WebKit/ShouldKeepCurrentBackForwardListItemInList.cpp:
2740         (TestWebKitAPI::TEST):
2741         * TestWebKitAPI/Tests/WebKit/TerminateTwice.cpp:
2742         (TestWebKitAPI::TEST):
2743         * TestWebKitAPI/Tests/WebKit/UserMedia.cpp:
2744         (TestWebKitAPI::TEST):
2745         * TestWebKitAPI/Tests/WebKit/WKPageConfiguration.cpp:
2746         (TestWebKitAPI::TEST):
2747         * TestWebKitAPI/Tests/WebKit/WKPageCopySessionStateWithFiltering.cpp:
2748         (TestWebKitAPI::TEST):
2749         * TestWebKitAPI/Tests/WebKit/WKPageGetScaleFactorNotZero.cpp:
2750         (TestWebKitAPI::TEST):
2751         * TestWebKitAPI/Tests/WebKit/WKPageIsPlayingAudio.cpp:
2752         (TestWebKitAPI::TEST):
2753         * TestWebKitAPI/Tests/WebKit/WKThumbnailView.mm:
2754         (TestWebKitAPI::TEST):
2755         * TestWebKitAPI/Tests/WebKit/WebCoreStatisticsWithNoWebProcess.cpp:
2756         (TestWebKitAPI::TEST):
2757         * TestWebKitAPI/Tests/WebKit/mac/GetPIDAfterAbortedProcessLaunch.cpp:
2758         (TestWebKitAPI::TEST):
2759         * TestWebKitAPI/Tests/WebKit/mac/RestoreStateAfterTermination.mm:
2760         (TestWebKitAPI::TEST):
2761         * TestWebKitAPI/Tests/WebKitCocoa/CommandBackForward.mm:
2762         (WebKit2_CommandBackForwardTestWKView::SetUp):
2763         * TestWebKitAPI/Tests/WebKitCocoa/FullscreenDelegate.mm:
2764         (TestWebKitAPI::TEST):
2765         * TestWebKitAPI/Tests/WebKitCocoa/PictureInPictureDelegate.mm:
2766         (TestWebKitAPI::TEST):
2767         * TestWebKitAPI/Tests/WebKitCocoa/SchemeRegistry.mm:
2768         (TestWebKitAPI::TEST):
2769         * TestWebKitAPI/mac/WebKitAgnosticTest.mm:
2770         (TestWebKitAPI::WebKitAgnosticTest::runWebKit2Test):
2771
2772 2019-01-03  Matt Rajca  <mrajca@apple.com>
2773
2774         Make DidPlayMediaPreventedFromPlaying autoplay event more generic.
2775         https://bugs.webkit.org/show_bug.cgi?id=193128
2776         rdar://34554231
2777
2778         Reviewed by Jer Noble.
2779
2780         Today, the "DidPlayMediaPreventedFromPlaying" autoplay event is only sent for
2781         media prevented from autoplaying. It could be generalized to a "DidPlayMediaWithUserGesture"
2782         event along with a flag that indicates whether or not autoplay was actually prevented.
2783
2784         Tests: existing API tests were updated to reflect the new names. New API tests
2785         were added for the new case in which the "DidPlayMediaWithUserGesture" event is sent.
2786
2787         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
2788         * TestWebKitAPI/Tests/WebKit/long-test.mp4: Added.
2789         * TestWebKitAPI/Tests/WebKitCocoa/WebsitePolicies.mm:
2790         (TEST):
2791         * TestWebKitAPI/Tests/WebKitCocoa/audio-with-play-button.html: Added.
2792         * TestWebKitAPI/Tests/WebKitCocoa/video-with-play-button.html: Added.
2793
2794 2019-01-04  Chris Dumez  <cdumez@apple.com>
2795
2796         [PSON] Calling history.back() from inside the load event handler prevents process-swapping
2797         https://bugs.webkit.org/show_bug.cgi?id=193120
2798
2799         Reviewed by Alex Christensen.
2800
2801         Add API test coverage.
2802
2803         * TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
2804
2805 2019-01-04  Chris Dumez  <cdumez@apple.com>
2806
2807         Crash under WebProcessPool::addSuspendedPage()
2808         https://bugs.webkit.org/show_bug.cgi?id=193110
2809
2810         Reviewed by Youenn Fablet.
2811
2812         Add API test coverage.
2813
2814         * TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
2815
2816 2019-01-04  Aakash Jain  <aakash_jain@apple.com>
2817
2818         [ews-build] Check patch relevance before applying the patch
2819         https://bugs.webkit.org/show_bug.cgi?id=193102
2820
2821         Reviewed by Lucas Forschler.
2822
2823         * BuildSlaveSupport/ews-build/factories.py:
2824         (Factory.__init__): Moved CheckPatchRelevance step to base class.
2825
2826 2019-01-04  Aakash Jain  <aakash_jain@apple.com>
2827
2828         [ews-build] Check patch relevance step should print patch id
2829         https://bugs.webkit.org/show_bug.cgi?id=193137
2830
2831         Reviewed by Lucas Forschler.
2832
2833         * BuildSlaveSupport/ews-build/steps.py:
2834         (CheckPatchRelevance.start): Update the status to include patch id.
2835
2836 2019-01-04  Jonathan Bedard  <jbedard@apple.com>
2837
2838         webkitpy: Increase simulator teardown timeout
2839         https://bugs.webkit.org/show_bug.cgi?id=193141
2840         <rdar://problem/46174217>
2841
2842         Rubber-stamped by Aakash Jain.
2843
2844         * Scripts/webkitpy/xcode/simulated_device.py:
2845         (SimulatedDeviceManager.tear_down): Use SIMULATOR_BOOT_TIMEOUT.
2846
2847 2019-01-03  Ross Kirsling  <ross.kirsling@sony.com>
2848
2849         test262-runner misbehaves when test file YAML has a trailing space
2850         https://bugs.webkit.org/show_bug.cgi?id=193053
2851
2852         Reviewed by Yusuke Suzuki.
2853
2854         * Scripts/test262/Runner.pm:
2855         (parseData):
2856         Accept trailing space when parsing a test file's YAML block.
2857
2858 2019-01-03  Michael Catanzaro  <mcatanzaro@igalia.com>
2859
2860         UserMedia test should use WKPageNavigationClient
2861         https://bugs.webkit.org/show_bug.cgi?id=192913
2862
2863         Reviewed by Youenn Fablet.
2864
2865         The test currently uses the deprecated WKPageLoaderClient. It should use
2866         WKPageNavigationClient instead, which provides the same callback under a similar name.
2867
2868         * TestWebKitAPI/Tests/WebKit/UserMedia.cpp:
2869         (TestWebKitAPI::TEST):
2870
2871 2019-01-02  Alex Christensen  <achristensen@webkit.org>
2872
2873         Homograph with LATIN SMALL LETTER R WITH FISHHOOK
2874         https://bugs.webkit.org/show_bug.cgi?id=192944
2875
2876         Reviewed by Tim Horton.
2877
2878         * TestWebKitAPI/Tests/WTF/cocoa/URLExtras.mm:
2879         (TestWebKitAPI::TEST):
2880
2881 2019-01-02  Wenson Hsieh  <wenson_hsieh@apple.com>
2882
2883         Add support for using the current text selection as the find string on iOS
2884         https://bugs.webkit.org/show_bug.cgi?id=193034
2885         <rdar://problem/45138739>
2886
2887         Reviewed by Tim Horton.
2888
2889         Add a new API test to verify that the new WebKit SPI (_stringForFind, _takeFindStringFromSelection:, and
2890         _setStringForFind) works as expected.
2891
2892         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
2893         * TestWebKitAPI/Tests/WebKitCocoa/UseSelectionAsFindString.mm: Added.
2894
2895 2019-01-02  Aakash Jain  <aakash_jain@apple.com>
2896
2897         [ews-build] Use git on OpenSource EWS bots
2898         https://bugs.webkit.org/show_bug.cgi?id=193092
2899
2900         Reviewed by Lucas Forschler.
2901
2902         * BuildSlaveSupport/ews-build/steps.py:
2903         (CheckOutSource): Use git instead of svn.
2904         (CheckOutSource.__init__): Use timeout of 2 hours since the initial checkout might take a long time.
2905
2906 2019-01-02  Daniel Bates  <dabates@apple.com>
2907
2908         [lldb-webkit] Remove broken code to print WTF::OptionSet::m_storage
2909         https://bugs.webkit.org/show_bug.cgi?id=193023
2910
2911         Reviewed by Simon Fraser.
2912
2913         The code to print WTF::OptionSet::m_storage as an item in the set never worked and does
2914         not seem meaningful to fix because WTF::OptionSet::m_storage is just the sum of the printed
2915         enumerator values. We should just remove this code.
2916
2917         * lldb/lldb_webkit.py:
2918         (WTFOptionSetProvider.has_children):
2919         (WTFOptionSetProvider.num_children):
2920         (WTFOptionSetProvider.get_child_index):
2921         (WTFOptionSetProvider.get_child_at_index):
2922
2923 2018-12-29  Yusuke Suzuki  <yusukesuzuki@slowstart.org>
2924
2925         .ycm_extra_conf.py should handle XXXInlines.h
2926         https://bugs.webkit.org/show_bug.cgi?id=193055
2927
2928         Reviewed by Carlos Garcia Campos.
2929
2930         compile_commands.json database only records flags and options for cpp source files.
2931         So, when we open headers, this database does not have any information for that.
2932         Our .ycm_extra_conf.py alleviates this by using XXX.cpp's configuration for XXX.h.
2933         But this mitigation does not handle XXXInlines.h well since we do not have XXXInlines.cpp.
2934         This patch adds support for XXXInlines.h in .ycm_extra_conf.py. When XXXInlines.h is queried,
2935         we attempt to find XXX.cpp and use the configuration if it exists.
2936
2937         * gtk/ycm_extra_conf.py:
2938         (getImplementationFilename):
2939         (FlagsForFile):
2940
2941 2018-12-31  Carlos Garcia Campos  <cgarcia@igalia.com>
2942
2943         Unreviewed. Support PHP 7.3 in Debian.
2944
2945         Add 7.3 to the list of php versions supported in Debian.
2946
2947         * Scripts/webkitpy/port/base.py:
2948         (Port._debian_php_version):
2949
2950 2018-12-27  Alex Christensen  <achristensen@webkit.org>
2951
2952         Resurrect Mac CMake build
2953         https://bugs.webkit.org/show_bug.cgi?id=192658
2954
2955         Reviewed by Yusuke Suzuki.
2956
2957         * DumpRenderTree/PlatformMac.cmake:
2958         * MiniBrowser/mac/CMakeLists.txt:
2959         * TestWebKitAPI/PlatformMac.cmake:
2960
2961 2018-12-26  Adrian Perez de Castro  <aperez@igalia.com>
2962
2963         [Tools] Remove references to Bison and Flex
2964         https://bugs.webkit.org/show_bug.cgi?id=193033
2965
2966         Reviewed by Michael Catanzaro.
2967
2968         The Bison and Flex tools are not needed anymore since r209883.
2969
2970         * CygwinDownloader/cygwin-downloader.py:
2971         * EWSTools/ubuntu-ews-packages:
2972         * Scripts/filter-build-webkit:
2973         (shouldIgnoreLine):
2974         * gtk/install-dependencies:
2975         * wpe/install-dependencies:
2976
2977 2018-12-22  Carlos Garcia Campos  <cgarcia@igalia.com>
2978
2979         WebDriver: warn about non existing tests when parsing expectations
2980         https://bugs.webkit.org/show_bug.cgi?id=192979
2981
2982         Reviewed by Michael Catanzaro.
2983
2984         It's common to update web driver tests and forget updating the test expectations in case of tests removed or
2985         renamed.
2986
2987         * Scripts/webkitpy/webdriver_tests/webdriver_test_runner.py:
2988         (WebDriverTestRunner.__init__):
2989
2990 2018-12-21  Chris Dumez  <cdumez@apple.com>
2991
2992         navigator.userAgent in service workers does not reflect customUserAgent set by client
2993         https://bugs.webkit.org/show_bug.cgi?id=192951
2994
2995         Reviewed by Youenn Fablet.
2996
2997         Extend API test coverage.
2998
2999         * TestWebKitAPI/Tests/WebKitCocoa/ServiceWorkerBasic.mm:
3000         (-[SWCustomUserAgentDelegate initWithUserAgent:]):
3001         (-[SWCustomUserAgentDelegate _webView:decidePolicyForNavigationAction:userInfo:decisionHandler:]):
3002         (-[SWUserAgentMessageHandler initWithExpectedMessage:]):
3003         (-[SWUserAgentMessageHandler userContentController:didReceiveScriptMessage:]):
3004
3005 2018-12-21  Jiewen Tan  <jiewen_tan@apple.com>
3006
3007         [WebAuthN] userPresence should always be true
3008         https://bugs.webkit.org/show_bug.cgi?id=192835
3009         <rdar://problem/46538788>
3010
3011         Reviewed by Brent Fulgham.
3012
3013         * TestWebKitAPI/Tests/WebCore/CtapRequestTest.cpp:
3014         (TestWebKitAPI::TEST):
3015
3016 2018-12-19  Simon Fraser  <simon.fraser@apple.com>
3017
3018         Add support to run-benchmark to use non-default copies of the browser apps
3019         https://bugs.webkit.org/show_bug.cgi?id=192905
3020         rdar://problem/46845840
3021
3022         Reviewed by Dewei Zhu.
3023         
3024         Add support for a --browser-path argument to run-benchmark, which allows you to use
3025         a custom app bundle for a given browser (only implemented for Safari at present).
3026
3027         * Scripts/webkitpy/benchmark_runner/benchmark_runner.py:
3028         (BenchmarkRunner.__init__):
3029         * Scripts/webkitpy/benchmark_runner/browser_driver/browser_driver.py:
3030         (BrowserDriver.__init__):
3031         * Scripts/webkitpy/benchmark_runner/browser_driver/browser_driver_factory.py:
3032         (BrowserDriverFactory.create):
3033         * Scripts/webkitpy/benchmark_runner/browser_driver/osx_browser_driver.py:
3034         (OSXBrowserDriver._launch_process):
3035         (OSXBrowserDriver._launch_process_with_caffeinate): Fix spelling.
3036         (OSXBrowserDriver._launch_process_with_caffinate): Deleted.
3037         * Scripts/webkitpy/benchmark_runner/browser_driver/osx_chrome_driver.py:
3038         (OSXChromeCanaryDriver.launch_url):
3039         * Scripts/webkitpy/benchmark_runner/browser_driver/osx_firefox_driver.py:
3040         (OSXFirefoxNightlyDriver.launch_url):
3041         * Scripts/webkitpy/benchmark_runner/browser_driver/osx_safari_driver.py:
3042         (OSXSafariDriver.__init__):
3043         (OSXSafariDriver.launch_url):
3044         * Scripts/webkitpy/benchmark_runner/run_benchmark.py:
3045         (parse_args):
3046         (run_benchmark_plan):
3047         * Scripts/webkitpy/benchmark_runner/webserver_benchmark_runner.py:
3048         (WebServerBenchmarkRunner.__init__):
3049         * Scripts/webkitpy/browserperfdash/browserperfdash_unittest.py:
3050         (FakeBenchmarkRunner.__init__):
3051
3052 2018-12-21  Jiewen Tan  <jiewen_tan@apple.com>
3053
3054         [WebAuthN] Import an APDU coder from Chromium
3055         https://bugs.webkit.org/show_bug.cgi?id=192949
3056         <rdar://problem/46879933>
3057
3058         Reviewed by Brent Fulgham.
3059
3060         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
3061         * TestWebKitAPI/Tests/WebCore/ApduTest.cpp: Added.
3062         (TestWebKitAPI::TEST):
3063
3064 2018-12-21  Wenson Hsieh  <wenson_hsieh@apple.com>
3065
3066         Setting the file wrapper and content type of an attachment to a PDF should update its image
3067         https://bugs.webkit.org/show_bug.cgi?id=192984
3068         <rdar://problem/46798028>
3069
3070         Reviewed by Tim Horton.
3071
3072         Add an API test to verify that setting the file wrapper for a _WKAttachment with an enclosing image element with
3073         PDF data correctly updates the image element.
3074
3075         * TestWebKitAPI/Tests/WebKitCocoa/WKAttachmentTests.mm:
3076
3077 2018-12-21  Michael Catanzaro  <mcatanzaro@igalia.com>
3078
3079         Add JSCOnly to bot dashboard
3080         https://bugs.webkit.org/show_bug.cgi?id=192964
3081
3082         Reviewed by Alexey Proskuryakov.
3083
3084         Apparently we have five JSCOnly test bots and multiple developers working on keeping them in
3085         good shape. Sadly, they are hidden bots not exposed in the dashboard. They would be more
3086         useful if they were not so secret, so add them.
3087
3088         There appear to be no build-only bots, so the first column is blank. And of course there are
3089         no WebKit1 or WebKit2 bots, because this is JSCOnly, so the second and third columns are
3090         blank too. That's OK. This will be the last bot on the dashboard, so it won't look too bad,
3091         and there's plenty of room in the final column for all the bots.
3092
3093         I had a hard time picking a logo to use, because the JavaScript language does not have an
3094         official logo. But I believe I've found one that will be satisfactory.
3095
3096         I will sneak in one bonus change: WPE's EWS queue was missing, and has been added.
3097
3098         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Images/SquirrelFish.png: Added.
3099         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Images/SquirrelFish@2x.png: Added.
3100         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BubbleQueueServer.js:
3101         (BubbleQueueServer):
3102         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/Dashboard.js:
3103         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/WebKitBuildbot.js:
3104         (WebKitBuildbot):
3105         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Styles/Main.css:
3106         (table.queue-grid tr.platform.linux-jsconly img.logo):
3107
3108 2018-12-21  Benjamin Poulain  <benjamin@webkit.org>
3109
3110         <rdar://problem/46194315> macOS: WebKit1 does not handle occlusion changes
3111         https://bugs.webkit.org/show_bug.cgi?id=192821
3112
3113         Reviewed by Chris Dumez.
3114
3115         * DumpRenderTree/mac/DumpRenderTree.mm:
3116         (createWebViewAndOffscreenWindow):
3117         * TestWebKitAPI/mac/WebKitAgnosticTest.mm:
3118
3119 2018-12-20  Fujii Hironori  <Hironori.Fujii@sony.com>
3120
3121         [Win][Clang] Fix compilation warnings of DumpRenderTree
3122         https://bugs.webkit.org/show_bug.cgi?id=192924
3123
3124         Reviewed by Alex Christensen.
3125
3126         * DumpRenderTree/AccessibilityController.h: Added member variable initializations in the class definition.
3127         * DumpRenderTree/win/AccessibilityControllerWin.cpp:
3128         (AccessibilityController::AccessibilityController): Moved member variable initializations to the class definition.
3129         * DumpRenderTree/win/DumpRenderTree.cpp:
3130         (dumpHistoryItem): String literals can't be converted non-const type. Use auto for them.
3131         (resetWebPreferencesToConsistentValues): Pass a temporal _bstr_t
3132         object to the argument of setDefaultTextEncodingName instead of a
3133         const string literal.
3134         (createWebViewAndOffscreenWindow): Use %lx for HRESULT (aka 'long').
3135         (main): Exit if _dup2 fails. Use %lu for'DWORD'(aka 'unsigned long').
3136         (setCacheFolder): Deleted.
3137         * DumpRenderTree/win/DumpRenderTreeWin.h: Fix class/struct mismatch of FrameLoadDelegate and PolicyDelegate declarations.
3138         * DumpRenderTree/win/EditingDelegate.cpp:
3139         (dump): Use %d for int.
3140         * DumpRenderTree/win/FrameLoadDelegate.cpp: Removed unused variable g_delegateWaitingOnTimer.
3141         * DumpRenderTree/win/ResourceLoadDelegate.cpp:
3142         (BSTRFromString): Deleted unused function.
3143         * DumpRenderTree/win/TestRunnerWin.cpp:
3144         (TestRunner::setDatabaseQuota): Pass a temporal _bstr_t object to
3145         the arguemnt of setQuota instead of const string literal.
3146         * DumpRenderTree/win/WorkQueueItemWin.cpp:
3147         (jsStringRefToWString): Deleted unused function.
3148
3149 2018-12-20  Chris Dumez  <cdumez@apple.com>
3150
3151         Add API test coverage for customUserAgent client setting and service workers
3152         https://bugs.webkit.org/show_bug.cgi?id=192952
3153
3154         Reviewed by Alex Christensen.
3155
3156         * TestWebKitAPI/Tests/WebKitCocoa/ServiceWorkerBasic.mm:
3157         (-[SWMessageHandler userContentController:didReceiveScriptMessage:]):
3158         (-[SWSchemes webView:startURLSchemeTask:]):
3159         (-[SWCustomUserAgentDelegate _webView:decidePolicyForNavigationAction:userInfo:decisionHandler:]):
3160         (-[SWUserAgentMessageHandler userContentController:didReceiveScriptMessage:]):
3161
3162 2018-12-20  Chris Dumez  <cdumez@apple.com>
3163
3164         Use Optional::hasValue() instead of Optional::has_value()
3165         https://bugs.webkit.org/show_bug.cgi?id=192948
3166
3167         Reviewed by Tim Horton.
3168
3169         * TestWebKitAPI/Tests/WebCore/CBORReaderTest.cpp:
3170         (TestWebKitAPI::TEST):
3171         * TestWebKitAPI/Tests/WebCore/CBORWriterTest.cpp:
3172         (TestWebKitAPI::TEST):
3173         * TestWebKitAPI/Tests/WebCore/FileSystem.cpp:
3174         (TestWebKitAPI::TEST_F):
3175
3176 2018-12-20  Chris Dumez  <cdumez@apple.com>
3177
3178         Add style script rule to check for uses of std::optional<>
3179         https://bugs.webkit.org/show_bug.cgi?id=192931
3180
3181         Reviewed by Tim Horton.
3182
3183         * Scripts/webkitpy/style/checkers/cpp.py:
3184         (check_wtf_optional):
3185         (check_style):
3186
3187 2018-12-20  Jiewen Tan  <jiewen_tan@apple.com>
3188
3189         [WebAuthN] Add a runtime flag for local authenticator
3190         https://bugs.webkit.org/show_bug.cgi?id=192792
3191         <rdar://problem/46798738>
3192
3193         Reviewed by Brent Fulgham.
3194
3195         * DumpRenderTree/TestOptions.cpp:
3196         (TestOptions::TestOptions):
3197         * DumpRenderTree/TestOptions.h:
3198         * DumpRenderTree/mac/DumpRenderTree.mm:
3199         (enableExperimentalFeatures):
3200         (setWebPreferencesForTestOptions):
3201         * WebKitTestRunner/TestController.cpp:
3202         (WTR::TestController::resetPreferencesToConsistentValues):
3203         (WTR::updateTestOptionsFromTestHeader):
3204         * WebKitTestRunner/TestOptions.h:
3205         (WTR::TestOptions::hasSameInitializationOptions const):
3206
3207 2018-12-20  Jonathan Bedard  <jbedard@apple.com>
3208
3209         webkitpy: Autoinstall package URLs have changed
3210         https://bugs.webkit.org/show_bug.cgi?id=192909
3211         <rdar://problem/46860359>
3212
3213         Rubber-stamped by Alexey Proskuryakov.
3214
3215         PyPi urls have been moved around, we need to update our auto-installed packages.
3216
3217         We should check for Selenium before asking PyPi for the latest version.
3218
3219         * Scripts/webkitpy/thirdparty/__init__.py:
3220         (AutoinstallImportHook._install_mechanize): Update with new pypi url.
3221         (AutoinstallImportHook._install_keyring): Ditto.
3222         (AutoinstallImportHook._install_pep8): Ditto.
3223         (AutoinstallImportHook._install_mozlog): Ditto.
3224         (AutoinstallImportHook._install_mozprocess): Ditto.
3225         (AutoinstallImportHook._install_pytest_timeout): Ditto.
3226         (AutoinstallImportHook._install_pytest): Ditto.
3227         (AutoinstallImportHook._install_pylint): Ditto.
3228         (AutoinstallImportHook._install_buildbot): Ditto.
3229         (AutoinstallImportHook._install_coverage): Ditto.
3230         (AutoinstallImportHook._install_twisted_15_5_0): Ditto.
3231         (AutoinstallImportHook._install_selenium): Update with new pypi url, only check
3232         for new Selenium if the installed version isn't sufficient.
3233         (AutoinstallImportHook.get_latest_pypi_url): Update with new pypi url.
3234
3235 2018-12-20  Chris Dumez  <cdumez@apple.com>
3236
3237         Use Optional::valueOr() instead of Optional::value_or()
3238         https://bugs.webkit.org/show_bug.cgi?id=192933
3239
3240         Reviewed by Geoffrey Garen.
3241
3242         * TestWebKitAPI/Tests/WTF/URLParser.cpp:
3243         (TestWebKitAPI::checkURL):
3244         (TestWebKitAPI::checkRelativeURL):
3245         (TestWebKitAPI::checkURLDifferences):
3246         (TestWebKitAPI::checkRelativeURLDifferences):
3247         * TestWebKitAPI/Tests/WebCore/URLParserTextEncoding.cpp:
3248         (TestWebKitAPI::checkURL):
3249
3250 2018-12-20  Ryan Haddad  <ryanhaddad@apple.com>
3251
3252         Unreviewed, rolling out r239417.
3253
3254         Introduced two API test failures on macOS.
3255
3256         Reverted changeset:
3257
3258         "<rdar://problem/46194315> macOS: WebKit1 does not handle
3259         occlusion changes"
3260         https://bugs.webkit.org/show_bug.cgi?id=192821
3261         https://trac.webkit.org/changeset/239417
3262
3263 2018-12-20  Devin Rousso  <drousso@apple.com>
3264
3265         Web Inspector: UIString should take an optional key and description to aid localization
3266         https://bugs.webkit.org/show_bug.cgi?id=153962
3267         <rdar://problem/24542505>
3268
3269         Reviewed by Brian Burg.
3270
3271         * Scripts/extract-localizable-js-strings:
3272
3273 2018-12-20  Tim Horton  <timothy_horton@apple.com>
3274
3275         Unparented WKWebView can't retrieve main resource data for a main frame plugin
3276         https://bugs.webkit.org/show_bug.cgi?id=192923
3277         <rdar://problem/46859068>
3278
3279         Reviewed by Wenson Hsieh.
3280
3281         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
3282         * TestWebKitAPI/WebKitCocoa/GetResourceData.mm:
3283         Add a test ensuring that both parented and unparented WKWebViews can
3284         retrieve main resource data when loading a PDF.
3285
3286 2018-12-20  Carlos Garcia Campos  <cgarcia@igalia.com>
3287
3288         [GTK][WPE] Bump webkitgtk-test-fonts to 0.0.8
3289         https://bugs.webkit.org/show_bug.cgi?id=192852
3290
3291         Reviewed by Michael Catanzaro.
3292
3293         EmojiOne font was replaced by Noto Color Emoji.
3294
3295         * WebKitTestRunner/gtk/fonts/fonts.conf: Use Noto Color Emoji when Apple Color Emoji font family is used in tests.
3296         * gtk/jhbuild.modules:
3297         * wpe/jhbuild.modules:
3298
3299 2018-12-19  Chris Dumez  <cdumez@apple.com>
3300
3301         wtf/Optional.h: move-constructor and move-assignment operator should disengage the value being moved from
3302         https://bugs.webkit.org/show_bug.cgi?id=192728
3303         <rdar://problem/46746779>
3304
3305         Reviewed by Geoff Garen.
3306
3307         * DumpRenderTree/*:
3308         * MiniBrowser/*:
3309         * TestRunnerShared/*:
3310         * TestWebKitAPI/*:
3311         * WebGPUAPIStructure/*:
3312         * WebKitTestRunner/*:
3313
3314 2018-12-19  Benjamin Poulain  <benjamin@webkit.org>
3315
3316         <rdar://problem/46194315> macOS: WebKit1 does not handle occlusion changes
3317         https://bugs.webkit.org/show_bug.cgi?id=192821
3318
3319         Reviewed by Chris Dumez.
3320
3321         * DumpRenderTree/mac/DumpRenderTree.mm:
3322         (createWebViewAndOffscreenWindow):
3323
3324 2018-12-19  Alex Christensen  <achristensen@webkit.org>
3325
3326         Navigations away from the SafeBrowsing interstitial show a flash of old content
3327         https://bugs.webkit.org/show_bug.cgi?id=192676
3328
3329         Reviewed by Chris Dumez.
3330
3331         * TestWebKitAPI/Tests/WebKitCocoa/SafeBrowsing.mm:
3332         (safeBrowsingView):
3333         (TEST):
3334         (-[SafeBrowsingHelper webView:runJavaScriptAlertPanelWithMessage:initiatedByFrame:completionHandler:]): Deleted.
3335
3336 2018-12-19  Adrian Perez de Castro  <aperez@igalia.com>
3337
3338         [GTK][WPE] Unify TestController::platformRunUntil() and honor condition flag
3339         https://bugs.webkit.org/show_bug.cgi?id=192855
3340
3341         Reviewed by Michael Catanzaro.
3342
3343         * WebKitTestRunner/gtk/TestControllerGtk.cpp:
3344         (WTR::TestController::notifyDone): Use the WPE implementation.
3345         (WTR::TestController::platformRunUntil): Use the WPE implementation.
3346         * WebKitTestRunner/wpe/TestControllerWPE.cpp:
3347         (WTR::TestController::platformRunUntil): Honor the condition flag.
3348
3349 2018-12-19  Megan Gardner  <megan_gardner@apple.com>
3350
3351         Allow clients to set the navigator platform
3352         https://bugs.webkit.org/show_bug.cgi?id=192735
3353
3354         Reviewed by Tim Horton.
3355
3356         Add a test for setting a custom navigator platform.
3357
3358         * TestWebKitAPI/Tests/WebKitCocoa/WebsitePolicies.mm:
3359         (-[CustomNavigatorPlatformDelegate _webView:decidePolicyForNavigationAction:userInfo:decisionHandler:]):
3360         (-[CustomNavigatorPlatformDelegate webView:didFinishNavigation:]):
3361
3362 2018-12-19  Truitt Savell  <tsavell@apple.com>
3363
3364         Unreviewed, rolling out r239358.
3365
3366         Revision caused imported/w3c/web-platform-tests/IndexedDB/ to
3367         crash on Debug bots
3368
3369         Reverted changeset:
3370
3371         "Clean up IndexedDB files between tests"
3372         https://bugs.webkit.org/show_bug.cgi?id=192796
3373         https://trac.webkit.org/changeset/239358
3374
3375 2018-12-18  Wenson Hsieh  <wenson_hsieh@apple.com>
3376
3377         [iOS] A copied text selection is pasted as a web archive attachment in the entry view in Messages
3378         https://bugs.webkit.org/show_bug.cgi?id=192842
3379         <rdar://problem/46823586>
3380
3381         Reviewed by Tim Horton.
3382
3383         Adjusts an existing API test to verify that "com.apple.webarchive" is not one of the types registered to the
3384         item provider when dragging a rich text selection.
3385
3386         * TestWebKitAPI/Tests/ios/DragAndDropTestsIOS.mm:
3387
3388 2018-12-18  David Quesada  <david_quesada@apple.com>
3389
3390         REGRESSION: [iOS] API test TestWebKitAPI._WKDownload.OriginatingWebView is a flaky failure
3391         https://bugs.webkit.org/show_bug.cgi?id=192810
3392         <rdar://problem/46812536>
3393
3394         Reviewed by Alex Christensen.
3395
3396         * TestWebKitAPI/Tests/WebKitCocoa/Download.mm:
3397         (-[OriginatingWebViewDownloadDelegate _downloadDidStart:]):
3398             After releasing our reference to the web view, wait until the next turn of the runloop
3399             before checking that the originatingWebView has been zeroed, since the web view might
3400             still be referenced in the autorelease pool. This _WKDownload unit test isn't about
3401             testing general memory management of WKWebViews, only that _WKDownload does not retain
3402             its web view via the 'originatingWebView' property.
3403
3404 2018-12-18  Sihui Liu  <sihui_liu@apple.com>
3405
3406         Clean up IndexedDB files between tests
3407         https://bugs.webkit.org/show_bug.cgi?id=192796
3408
3409         Reviewed by Geoffrey Garen.
3410
3411         * DumpRenderTree/mac/DumpRenderTree.mm:
3412         (runTest):
3413         * WebKitTestRunner/TestController.cpp:
3414         (WTR::TestController::resetStateToConsistentValues):
3415         (WTR::RemoveAllIndexedDatabasesCallbackContext::RemoveAllIndexedDatabasesCallbackContext):
3416         (WTR::RemoveAllIndexedDatabasesCallback):
3417         (WTR::TestController::ClearIndexedDatabases):
3418         * WebKitTestRunner/TestController.h:
3419
3420 2018-12-18  Alex Christensen  <achristensen@webkit.org>
3421
3422         Fix API test introduced in r239339 on iOS.
3423         https://bugs.webkit.org/show_bug.cgi?id=192675
3424
3425         * TestWebKitAPI/Tests/WebKitCocoa/SafeBrowsing.mm:
3426         (TEST):
3427         The iOS implementation of the safe browsing warning is a little different.
3428         It does some element creation when it is added to the window so it knows how big it is.
3429         To test these elements, we need to simulate adding it to the window.
3430         A similar technique is done in other iOS API tests, such as SafeBrowsing.ShowWarningSPI.
3431
3432 2018-12-18  Jonathan Bedard  <jbedard@apple.com>
3433
3434         webkitpy: Ignore device type for test when using --force
3435         https://bugs.webkit.org/show_bug.cgi?id=192786
3436         <rdar://problem/46794894>
3437
3438         Reviewed by Daniel Bates.
3439
3440         It is sometimes the case that a contributor will wish to run a test on a specific device,
3441         despite expectations which indicate a test should not be run on that device.
3442
3443         * Scripts/webkitpy/layout_tests/run_webkit_tests.py:
3444         (parse_args):
3445         * Scripts/webkitpy/port/device_port.py:
3446         (DevicePort.default_child_processes): Strip device type information when using --force.
3447         (DevicePort.setup_test_run): Only allow incomplete match when using --force.
3448
3449 2018-12-18  Alex Christensen  <achristensen@webkit.org>
3450
3451         WKWebView has old URL while displaying SafeBrowsing interstitial, for link-click navigations
3452         https://bugs.webkit.org/show_bug.cgi?id=192675
3453
3454         Reviewed by Geoffrey Garen.
3455
3456         * TestWebKitAPI/Tests/WebKitCocoa/SafeBrowsing.mm:
3457         (goBack):
3458         (TEST):
3459         (visitUnsafeSite):
3460         (-[SafeBrowsingHelper observeValueForKeyPath:ofObject:change:context:]):
3461         (-[SafeBrowsingHelper webView:runJavaScriptAlertPanelWithMessage:initiatedByFrame:completionHandler:]):
3462
3463 2018-12-18  Chris Dumez  <cdumez@apple.com>
3464
3465         Regression(r239182) SuspendedPage's process reuse for link navigation optimization sometimes broken
3466         https://bugs.webkit.org/show_bug.cgi?id=192772
3467
3468         Reviewed by Antti Koivisto.
3469
3470         Add API test coverage.
3471
3472         * TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
3473
3474 2018-12-18  Philippe Normand  <pnormand@igalia.com>
3475
3476         Unreviewed, JHBuild GTK build fix attempt
3477
3478         * gtk/jhbuild.modules: There's no libffi in this moduleset anymore.
3479         There's no ninja module either, it should be provided by the
3480         host system.
3481
3482 2018-12-17  Chris Dumez  <cdumez@apple.com>
3483
3484         Allow passing nil as session state to [WKWebView _restoreSessionState:]
3485         https://bugs.webkit.org/show_bug.cgi?id=192789
3486         <rdar://problem/46755277>
3487
3488         Reviewed by Alex Christensen.
3489
3490         Add API test coverage.
3491
3492         * TestWebKitAPI/Tests/WebKit/WKBackForwardList.mm:
3493         (TEST):
3494
3495 2018-12-17  Simon Fraser  <simon.fraser@apple.com>
3496
3497         Don't use more expensive layer backing store formats when subpixel text antialiasing is not enabled
3498         https://bugs.webkit.org/show_bug.cgi?id=192780
3499         rdar://problem/43394387
3500
3501         Reviewed by Tim Horton.
3502
3503         No need to set "AppleFontSmoothing" defaults for WK2.
3504
3505         * WebKitTestRunner/InjectedBundle/mac/InjectedBundleMac.mm:
3506         (WTR::InjectedBundle::platformInitialize):
3507
3508 2018-12-17  Jonathan Bedard  <jbedard@apple.com>
3509
3510         webkitpy: Handle case where stdout and stderr don't accept unicode
3511         https://bugs.webkit.org/show_bug.cgi?id=192775
3512         <rdar://problem/46497303>
3513
3514         Reviewed by Stephanie Lewis.
3515
3516         * Scripts/webkitpy/layout_tests/views/metered_stream.py:
3517         (MeteredStream.write): If unicode cannot be written to the stream, replace unicode
3518         characters with '?'.
3519         * Scripts/webkitpy/layout_tests/views/metered_stream_unittest.py:
3520         (RegularTest.test_stream_with_encoding):
3521
3522 2018-12-17  Daniel Bates  <dabates@apple.com>
3523
3524         Support concatenating StringView with other string types
3525         https://bugs.webkit.org/show_bug.cgi?id=177566
3526
3527         Reviewed by Darin Adler.
3528
3529         Add some tests to ensure we do not regress the number of allocations needed when performing
3530         string concatenation with string views.
3531
3532         * TestWebKitAPI/Tests/WTF/StringOperators.cpp:
3533         (TestWebKitAPI::TEST):
3534
3535 2018-12-17  Commit Queue  <commit-queue@webkit.org>
3536
3537         Unreviewed, rolling out r239265 and r239274.
3538         https://bugs.webkit.org/show_bug.cgi?id=192765
3539
3540         unorm_normalize is deprecated, and broke an internal build
3541         (Requested by Truitt on #webkit).
3542
3543         Reverted changesets:
3544
3545         "[GTK][WPE] Need a function to convert internal URI to display
3546         ("pretty") URI"
3547         https://bugs.webkit.org/show_bug.cgi?id=174816
3548         https://trac.webkit.org/changeset/239265
3549
3550         "Fix the Apple Internal Mac build with a newer SDK"
3551         https://trac.webkit.org/changeset/239274
3552
3553 2018-12-17  Daniel Bates  <dabates@apple.com>
3554
3555         Implement UIScriptController::toggleCapsLock() for iOS
3556         https://bugs.webkit.org/show_bug.cgi?id=191815
3557
3558         Reviewed by Andy Estes.
3559
3560         Add support for toggling the caps lock state in WebKitTestRunner on iOS.
3561
3562         * TestRunnerShared/UIScriptContext/UIScriptController.h:
3563         * WebKitTestRunner/TestController.cpp:
3564         (WTR::TestController::resetStateToConsistentValues): Clear the current modifier state
3565         before running a test. This ensures that the caps lock state does not persist between
3566         tests should a test enable caps lock and not disable it.
3567         * WebKitTestRunner/ios/HIDEventGenerator.mm:
3568         (hidUsageCodeForCharacter): Map "capsLock" to the Caps Lock key usage code.
3569         * WebKitTestRunner/ios/UIScriptControllerIOS.mm:
3570         (WTR::createUIPhysicalKeyboardEvent): Modified to take the keyboard input flags to use to
3571         create the event. Also substituted NSString* for const String& as the data type for the first
3572         two parameters to avoid conversions in the implementation of UIScriptController::toggleCapsLock()
3573         below.
3574         (WTR::UIScriptController::keyDown): Update as needed due to changes to prototype of createUIPhysicalKeyboardEvent().
3575         (WTR::UIScriptController::toggleCapsLock): Dispatch a UIEvent to toggle caps lock.
3576
3577 2018-12-17  Daniel Bates  <dabates@apple.com>
3578
3579         [iOS] Remove -[WebEvent initWithKeyEventType:...:characterSet:]
3580         https://bugs.webkit.org/show_bug.cgi?id=192633
3581
3582         Reviewed by Wenson Hsieh.
3583
3584         Update code to use the modern initializer.
3585
3586         * DumpRenderTree/mac/EventSendingController.mm:
3587         (-[EventSendingController keyDown:withModifiers:withLocation:]):
3588
3589 2018-12-17  Matt Lewis  <jlewis3@apple.com>
3590
3591         Unreviewed, rolling out r239254.
3592
3593         This broke the Windows 10 Debug build
3594
3595         Reverted changeset:
3596
3597         "Replace many uses of String::format with more type-safe
3598         alternatives"
3599         https://bugs.webkit.org/show_bug.cgi?id=192742
3600         https://trac.webkit.org/changeset/239254
3601
3602 2018-12-17  David Kilzer  <ddkilzer@apple.com>
3603
3604         clang-tidy: loop variable is copied but only used as const reference in WebCore, WebKit, Tools
3605         <https://webkit.org/b/192751>
3606         <rdar://problem/46771623>
3607
3608         Reviewed by Daniel Bates.
3609
3610         Change loop variables to const references to avoid unnecessary
3611         copies.
3612
3613         * DumpRenderTree/mac/DumpRenderTreePasteboard.mm:
3614         (-[LocalPasteboard pasteboardItems]):
3615
3616 2018-12-17  Ms2ger  <Ms2ger@igalia.com>
3617
3618         [GTK][WPE] Need a function to convert internal URI to display ("pretty") URI
3619         https://bugs.webkit.org/show_bug.cgi?id=174816
3620
3621         Reviewed by Michael Catanzaro.
3622
3623         Add tests for userVisibleString() and (for GTK and WPE) webkit_uri_for_display().
3624
3625         * TestWebKitAPI/CMakeLists.txt:
3626         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
3627         * TestWebKitAPI/Tests/WTF/URLHelpers.cpp: Added.
3628         (TestWebKitAPI::TEST):
3629         * TestWebKitAPI/Tests/WebKitGLib/TestWebKitURIUtilities.cpp: Added.
3630         (testURIForDisplayUnaffected):
3631         (testURIForDisplayAffected):
3632         (beforeAll):
3633         (afterAll):
3634         * TestWebKitAPI/glib/CMakeLists.txt:
3635
3636 2018-12-17  Carlos Garcia Campos  <cgarcia@igalia.com>
3637
3638         [WPE] Add API to notify about frame displayed view backend callback
3639         https://bugs.webkit.org/show_bug.cgi?id=192224
3640
3641         Reviewed by Michael Catanzaro.
3642
3643         Add a test case to check the new API.
3644
3645         * TestWebKitAPI/Tests/WebKitGLib/TestWebKitWebView.cpp:
3646         (testWebViewFrameDisplayed):
3647         (beforeAll):
3648         * wpe/jhbuild.modules: Bump WPEBackend-fdo to 1.1.0.
3649
3650 2018-12-16  Adrian Perez de Castro  <aperez@igalia.com>
3651
3652         Unreviewed build fix after r239253
3653
3654         * gtk/jhbuild.modules: Fix typo in libpsl dependency name.
3655
3656 2018-12-15  Darin Adler  <darin@apple.com>
3657
3658         Use warning-ignoring macros more consistently and simply
3659         https://bugs.webkit.org/show_bug.cgi?id=192743
3660
3661         Reviewed by Mark Lam.
3662
3663         * DumpRenderTree/TestNetscapePlugIn/main.cpp:
3664         (handleEventCarbon): Use ALLOW_DEPRECATED_DECLARATIONS_BEGIN/END.
3665         * DumpRenderTree/mac/TextInputControllerMac.m:
3666         (-[TextInputController interpretKeyEvents:withSender:]): Use
3667         IGNORE_WARNINGS_BEGIN/END.
3668         * WebKitTestRunner/mac/EventSenderProxy.mm:
3669         (WTR::EventSenderProxy::mouseForceClick): Use
3670         IGNORE_NULL_CHECK_WARNINGS_BEGIN/END.
3671         (WTR::EventSenderProxy::startAndCancelMouseForceClick): Ditto.
3672         (WTR::EventSenderProxy::mouseForceDown): Ditto.
3673         (WTR::EventSenderProxy::mouseForceUp): Ditto.
3674         (WTR::EventSenderProxy::mouseForceChanged): Ditto.
3675
3676 2018-12-15  Darin Adler  <darin@apple.com>
3677
3678         Replace many uses of String::format with more type-safe alternatives
3679         https://bugs.webkit.org/show_bug.cgi?id=192742
3680
3681         Reviewed by Mark Lam.
3682
3683         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
3684         (WTR::cacheTestRunnerCallback): Use makeString.
3685         * WebKitTestRunner/TestController.cpp:
3686         (WTR::TestController::didReceiveAuthenticationChallenge): Use makeString.
3687         (WTR::TestController::downloadDidFail): Use an ASCIILiteral via the _s syntax.
3688
3689 2018-12-15  Adrian Perez de Castro  <aperez@igalia.com>
3690
3691         [WPE][GTK] Add libpsl to JHBuild module sets
3692         https://bugs.webkit.org/show_bug.cgi?id=192740
3693
3694         Reviewed by Michael Catanzaro.
3695
3696         * gtk/jhbuild.modules: Add libpsl module.
3697         * wpe/jhbuild.modules: Ditto.
3698
3699 2018-12-14  Alexey Proskuryakov  <ap@apple.com>
3700
3701         Add a style checker rule for Xcode version macros use
3702         https://bugs.webkit.org/show_bug.cgi?id=192703
3703
3704         Reviewed by Alex Christensen.
3705
3706         * Scripts/webkitpy/style/checkers/cpp.py:
3707         (check_os_version_checks):
3708         (process_line):
3709         (CppChecker):
3710         * Scripts/webkitpy/style/checkers/cpp_unittest.py:
3711         (WebKitStyleTest.test_os_version_checks):
3712
3713 2018-12-14  Chris Dumez  <cdumez@apple.com>
3714
3715         [PSON] Process-swapping on a loadHTMLString causes duplicate decidePolicyForNavigationAction delegate calls
3716         https://bugs.webkit.org/show_bug.cgi?id=192704
3717
3718         Reviewed by Geoffrey Garen.
3719
3720         Extend existing API test to reproduce the problem.
3721
3722         * TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
3723
3724 2018-12-14  Chris Dumez  <cdumez@apple.com>
3725
3726         [PSON] WebsitePolicies are lost on process-swap
3727         https://bugs.webkit.org/show_bug.cgi?id=192694
3728         <rdar://problem/46715748>
3729
3730         Reviewed by Brady Eidson.
3731
3732         Extend existing API test to reproduce the issue.
3733
3734         * TestWebKitAPI/Tests/WebKitCocoa/WebsitePolicies.mm:
3735
3736 2018-12-14  Michael Catanzaro  <mcatanzaro@igalia.com>
3737
3738         [GTK] Error writing data to TLS socket in some sites when using the jhbuild
3739         https://bugs.webkit.org/show_bug.cgi?id=192678
3740
3741         Reviewed by Carlos Garcia Campos.
3742
3743         Update our ancient versions of libsoup and glib-networking.
3744
3745         * gtk/install-dependencies:
3746         * gtk/jhbuild.modules:
3747         * gtk/patches/libsoup-auth-Fix-async-authentication-when-flag-SOUP_MESSAGE.patch: Removed.
3748         * gtk/patches/libsoup-auth-do-not-use-cached-credentials-in-lookup-method-.patch: Removed.
3749         * gtk/patches/libsoup-soup-message-io-Do-not-fail-when-there-s-no-empty-li.patch: Removed.
3750         * gtk/patches/libsoup-soup-socket-fix-critical-warning-when-the-peer-certi.patch: Removed.
3751         * wpe/install-dependencies:
3752         * wpe/jhbuild.modules:
3753         * wpe/patches/libsoup-soup-socket-fix-critical-warning-when-the-peer-certi.patch: Removed.
3754
3755 2018-12-14  Carlos Garcia Campos  <cgarcia@igalia.com>
3756
3757         [WPE] Use new view state API from libwpe
3758         https://bugs.webkit.org/show_bug.cgi?id=191906
3759
3760         Reviewed by Žan Doberšek.
3761
3762         * TestWebKitAPI/Tests/WebKitGLib/TestWebKitWebView.cpp:
3763         (beforeAll): Enable /webkit/WebKitWebView/page-visibility in WPE.
3764         * TestWebKitAPI/glib/WebKitGLib/TestMain.h:
3765         (Test::createWebViewBackend): Make the view initially hidden for consistency with GTK+ tests.
3766         * TestWebKitAPI/glib/WebKitGLib/WebViewTest.h:
3767         * TestWebKitAPI/glib/WebKitGLib/wpe/WebViewTestWPE.cpp:
3768         (WebViewTest::showInWindow): Add wpe_view_activity_state_visible, wpe_view_activity_state_in_window and
3769         wpe_view_activity_state_focused state flags.
3770         (WebViewTest::hideView): Remove wpe_view_activity_state_visible and wpe_view_activity_state_focused state flags.
3771         * wpe/backends/HeadlessViewBackend.cpp:
3772         (WPEToolingBackends::HeadlessViewBackend::HeadlessViewBackend): Assume view is always visible, focused and in window.
3773         * wpe/backends/WindowViewBackend.cpp:
3774         (WPEToolingBackends::WindowViewBackend::WindowViewBackend): Update the view state flags depending on state
3775         received in configure callback.
3776         * wpe/jhbuild.modules: Bump libwpe to 1.1.0
3777
3778 2018-12-13  Fujii Hironori  <Hironori.Fujii@sony.com>
3779
3780         [WinCairo][Clang] DLLLauncherMain.cpp: warning: unused function 'prependPath' and 'appleApplicationSupportDirectory'
3781         https://bugs.webkit.org/show_bug.cgi?id=192688
3782
3783         Reviewed by Ross Kirsling.
3784
3785         * win/DLLLauncher/DLLLauncherMain.cpp:
3786         (copyEnvironmentVariable): Moved.
3787         (getStringValue): Enclosed with #if !defined(WIN_CAIRO).
3788         (applePathFromRegistry): Ditto.
3789         (appleApplicationSupportDirectory): Ditto.
3790         (prependPath): Ditto.
3791
3792 2018-12-13  Don Olmstead  <don.olmstead@sony.com>
3793
3794         Unreviewed. Changed my status to a reviewer.
3795
3796         * Scripts/webkitpy/common/config/contributors.json:
3797
3798 2018-12-13  Wenson Hsieh  <wenson_hsieh@apple.com>
3799
3800         [iOS] Support dropping contact card data (public.vcard) in editable content
3801         https://bugs.webkit.org/show_bug.cgi?id=192570
3802         <rdar://problem/35626913>
3803
3804         Reviewed by Tim Horton.
3805
3806         * TestWebKitAPI/Tests/WebKitCocoa/WKAttachmentTests.mm:
3807
3808         Add API tests to verify that registering `MKMapItem`s and `CNContact`s to item providers and dropping them in
3809         attachment-enabled rich text editable areas inserts attachment elements (and in the case of `MKMapItem`,
3810         additionally inserts a link).
3811
3812         * TestWebKitAPI/Tests/ios/DragAndDropTestsIOS.mm:
3813         (TestWebKitAPI::createMapItemForTesting):
3814         (TestWebKitAPI::createContactItemForTesting):
3815
3816         Add API tests to verify that dropping map items and contact items into rich and plain editable areas behaves as
3817         expected (in the case where a URL is present, e.g. dropping a map item, we insert the URL as an anchor, and when
3818         there is no other suitable representation in the item provider, we do nothing at all, which is the case for the
3819         dropped `CNContact`). Also, add a test to verify that drag and drop can be used to upload these items as .vcf
3820         files.
3821
3822 2018-12-13  Ross Kirsling  <ross.kirsling@sony.com>
3823
3824         Unreviewed -- update my status to "reviewer".
3825
3826         * Scripts/webkitpy/common/config/contributors.json:
3827
3828 2018-12-13  Youenn Fablet  <youenn@apple.com>
3829
3830         On page close, WebPage::m_userMediaPermissionRequestManager is nullified too early
3831         https://bugs.webkit.org/show_bug.cgi?id=192657
3832
3833         Reviewed by Eric Carlson.
3834
3835         Add a test that loads a page registering ondevicechange,
3836         load another page in the same process, closes the first page.
3837         Ensure that the process does not crash in that case.
3838
3839         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
3840         * TestWebKitAPI/Tests/WebKit/UserMedia.cpp:
3841         (TestWebKitAPI::TEST):
3842         (TestWebKitAPI::didCrashCallback):
3843         * TestWebKitAPI/Tests/WebKit/ondevicechange.html: Added.
3844
3845 2018-12-13  Carlos Eduardo Ramalho  <cadubentzen@gmail.com>
3846
3847         [GStreamer][JHBuild] update-webkit{gtk,wpe}-libs fails with libfdk-2.0.0
3848         https://bugs.webkit.org/show_bug.cgi?id=192643
3849
3850         Reviewed by Philippe Normand.
3851
3852         This problem happens with Arch Linux users which have libfdk-2.0.0
3853         installed (which is anybody with gst-plugins-bad 1.14.4 installed).
3854
3855         The problem has already been solved upstream at
3856         https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/merge_requests/77.
3857
3858         Adding patches while this problem is not in a release yet.
3859
3860         * gstreamer/jhbuild.modules: Add patches to fix build of gst-plugins-bad with libfdk-2.0.0.
3861         * gstreamer/patches/gst-plugins-bad-0003-fdkaacenc-Remove-MODE_2_1.patch: Added.
3862         * gstreamer/patches/gst-plugins-bad-0004-fdkaacdec-Use-WAV-channel-mapping-instead-of-interleave-setting.patch: Added.
3863
3864 2018-12-12  Carlos Garcia Campos  <cgarcia@igalia.com>
3865
3866         [FreeType] Add initial implementation of variation fonts
3867         https://bugs.webkit.org/show_bug.cgi?id=192151
3868
3869         Reviewed by Michael Catanzaro.
3870
3871         Add cairo patch to avoid crashes.
3872
3873         * gtk/jhbuild.modules:
3874         * gtk/patches/cairo-ft-Use-FT_Done_MM_Var-instead-of-free-when-available.patch: Added.
3875
3876 2018-12-12  Fujii Hironori  <Hironori.Fujii@sony.com>
3877
3878         [Win][Clang][WebKitLegacy] WebFrame.cpp: warning: delete called on non-final 'WebFrame' that has virtual functions but non-virtual destructor [-Wdelete-non-virtual-dtor]
3879         https://bugs.webkit.org/show_bug.cgi?id=192618
3880
3881         Reviewed by Alex Christensen.
3882
3883         * DumpRenderTree/win/DRTDataObject.cpp:
3884         * DumpRenderTree/win/DRTDataObject.h:
3885         * DumpRenderTree/win/DRTDesktopNotificationPresenter.h:
3886         * DumpRenderTree/win/DRTDropSource.h:
3887         * DumpRenderTree/win/EditingDelegate.h:
3888         * DumpRenderTree/win/PolicyDelegate.h:
3889         * DumpRenderTree/win/UIDelegate.h:
3890
3891 2018-12-12  Ryosuke Niwa  <rniwa@webkit.org>
3892
3893         Make TextInputController.legacyAttributedString take DOM nodes and offsets
3894         https://bugs.webkit.org/show_bug.cgi?id=192653
3895
3896         Reviewed by Wenson Hsieh.
3897
3898         Updated TextInputController.legacyAttributedString to take DOM nodes and offsets instead of
3899         a DOM Range object in preparation to add layout tests for HTMLConverter which crosses
3900         shadow boundaries.
3901
3902         * DumpRenderTree/mac/TextInputControllerMac.m:
3903         (+[TextInputController isSelectorExcludedFromWebScript:]): Updated the selector signature.
3904         (+[TextInputController webScriptNameForSelector:]): Ditto.
3905         (-[TextInputController legacyAttributedString:offset:to:offset:]): Made this function take
3906         start node and offset then end node and offset pairs.
3907
3908 2018-12-12  Alex Christensen  <achristensen@webkit.org>
3909
3910         Implement safe browsing in WebKit on WatchOS
3911         https://bugs.webkit.org/show_bug.cgi?id=192641
3912         <rdar://problem/46376188>
3913
3914         Reviewed by Geoff Garen.
3915
3916         * TestWebKitAPI/Tests/WebKitCocoa/SafeBrowsing.mm:
3917         (-[SafeBrowsingNavigationDelegate _webViewDidShowSafeBrowsingWarning:]):
3918         (safeBrowsingView):
3919         Add a test that the new delegate callback is called.
3920
3921 2018-12-12  Michael Catanzaro  <mcatanzaro@igalia.com>
3922
3923         Unreviewed manual rollout of r239100-r239102 and r239116
3924         https://bugs.webkit.org/show_bug.cgi?id=192151
3925         <rdar://problem/46655586>
3926
3927         * gtk/jhbuild.modules:
3928         * gtk/patches/cairo-ft-Use-FT_Done_MM_Var-instead-of-free-when-available.patch: Removed.
3929
3930 2018-12-12  Commit Queue  <commit-queue@webkit.org>
3931
3932         Unreviewed, rolling out r239103.
3933         https://bugs.webkit.org/show_bug.cgi?id=192627
3934
3935         It broke the built because it depends on another patch that
3936         didn't land yet (Requested by KaL on #webkit).
3937
3938         Reverted changeset:
3939
3940         "[WPE] Add API to notify about frame displayed view backend
3941         callback"
3942         https://bugs.webkit.org/show_bug.cgi?id=192224
3943         https://trac.webkit.org/changeset/239103
3944
3945 2018-11-30  Carlos Garcia Campos  <cgarcia@igalia.com>
3946
3947         [WPE] Add API to notify about frame displayed view backend callback
3948         https://bugs.webkit.org/show_bug.cgi?id=192224
3949
3950         Reviewed by Michael Catanzaro.
3951
3952         Add a test case to check the new API.
3953
3954         * TestWebKitAPI/Tests/WebKitGLib/TestWebKitWebView.cpp:
3955         (testWebViewFrameDisplayed):
3956         (beforeAll):
3957
3958 2018-12-12  Carlos Garcia Campos  <cgarcia@igalia.com>
3959
3960         [FreeType] Add initial implementation of variation fonts
3961         https://bugs.webkit.org/show_bug.cgi?id=192151
3962
3963         Reviewed by Michael Catanzaro.
3964
3965         Add cairo patch to avoid crashes.
3966
3967         * gtk/jhbuild.modules:
3968         * gtk/patches/cairo-ft-Use-FT_Done_MM_Var-instead-of-free-when-available.patch: Added.
3969
3970 2018-12-11  Justin Michaud  <justin_michaud@apple.com>
3971
3972         Implement feature flag for CSS Typed OM
3973         https://bugs.webkit.org/show_bug.cgi?id=192610
3974
3975         Reviewed by Ryosuke Niwa.
3976
3977         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
3978
3979 2018-12-11  Chris Dumez  <cdumez@apple.com>
3980
3981         Unreviewed, fix bad check in API test added in r239080.
3982
3983         * TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
3984
3985 2018-12-11  Fujii Hironori  <Hironori.Fujii@sony.com>
3986
3987         [Win][Clang] Fix warning -Wmissing-field-initializers
3988         https://bugs.webkit.org/show_bug.cgi?id=192584
3989
3990         Reviewed by Yusuke Suzuki.
3991
3992         Initialize a struct with '{ }' instead of '= {0}'.
3993
3994         * DumpRenderTree/win/DumpRenderTree.cpp:
3995         (runTest):
3996         * DumpRenderTree/win/EventSender.cpp:
3997         (makeMsg):
3998         (replaySavedEvents):
3999         (beginDragWithFilesCallback):
4000         * DumpRenderTree/win/PixelDumpSupportWin.cpp:
4001         (createBitmapContextFromWebView):
4002         * MiniBrowser/win/WebKitLegacyBrowserWindow.cpp:
4003         (updateMenuItemForHistoryItem):
4004         * MiniBrowser/win/WinMain.cpp:
4005         (wWinMain):
4006         * TestWebKitAPI/win/HostWindow.cpp:
4007         (TestWebKitAPI::HostWindow::clientRect const):
4008         (TestWebKitAPI::HostWindow::registerWindowClass):
4009         * TestWebKitAPI/win/PlatformWebViewWin.cpp:
4010         (TestWebKitAPI::PlatformWebView::registerWindowClass):
4011         * WebKitTestRunner/win/PlatformWebViewWin.cpp:
4012         (WTR::registerWindowClass):
4013         (WTR::PlatformWebView::windowFrame):
4014         (WTR::PlatformWebView::windowSnapshotImage):
4015
4016 2018-12-11  Chris Dumez  <cdumez@apple.com>
4017
4018         PSON logic gets confused by concurrent decidePolicyForNavigationAction requests
4019         https://bugs.webkit.org/show_bug.cgi?id=192482
4020         <rdar://problem/46470145>
4021
4022         Reviewed by Antti Koivisto.
4023
4024         Add API test coverage.
4025
4026         * TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
4027
4028 2018-12-11  Andy Estes  <aestes@apple.com>
4029
4030         Introduce makeBlockPtr for lambdas
4031         https://bugs.webkit.org/show_bug.cgi?id=192594
4032
4033         Reviewed by Alex Christensen.
4034
4035         Adopted makeBlockPtr and added API tests.
4036
4037         * DumpRenderTree/TestRunner.cpp:
4038         (TestRunner::callUIScriptCallback):
4039         * TestWebKitAPI/Tests/WTF/BlockPtr.mm:
4040         (TestWebKitAPI::TEST):
4041         * TestWebKitAPI/Tests/WebKitCocoa/DownloadProgress.mm:
4042         (-[DownloadProgressTestRunner init]):
4043         (-[DownloadProgressTestRunner subscribeAndWaitForProgress]):
4044
4045 2018-12-11  Chris Dumez  <cdumez@apple.com>
4046
4047         REGRESSION (r238764-238783): TestWTF.WTF.StringOperators is failing
4048         https://bugs.webkit.org/show_bug.cgi?id=192361
4049         <rdar://problem/46524903>
4050
4051         Reviewed by Alex Christensen.
4052
4053         Compile StringOperators.cpp with -O1 optimization level instead of -Os. This
4054         fixes the failures for me locally.
4055
4056         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
4057
4058 2018-12-11  Philippe Normand  <pnormand@igalia.com>
4059
4060         Unreviewed, WPE build fix after r239028
4061
4062         The FLATPAK_USER_DIR env var is not set early enough, leading to:
4063
4064         Traceback (most recent call last):
4065         File "/home/phil/WebKit/Tools/Scripts/webkit-flatpak", line 28, in <module>
4066           sys.exit(WebkitFlatpak.load_from_args().run())
4067         File "/home/phil/WebKit/Tools/flatpak/flatpakutils.py", line 761, in run
4068           if not self.clean_args():
4069         File "/home/phil/WebKit/Tools/flatpak/flatpakutils.py", line 574, in clean_args
4070           _log.debug("Using flatpak user dir: %s" % os.environ["FLATPAK_USER_DIR"])
4071         File "/usr/lib/python2.7/UserDict.py", line 40, in __getitem__
4072           raise KeyError(key)
4073         KeyError: 'FLATPAK_USER_DIR'
4074
4075         * flatpak/flatpakutils.py:
4076         (WebkitFlatpak.clean_args):
4077
4078 2018-12-10  Don Olmstead  <don.olmstead@sony.com>
4079
4080         Move ENABLE_RESOURCE_LOAD_STATISTICS to FeatureDefines.xcconfig
4081         https://bugs.webkit.org/show_bug.cgi?id=192573
4082
4083         Reviewed by Simon Fraser.
4084
4085         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
4086
4087 2018-12-10  Don Olmstead  <don.olmstead@sony.com>
4088
4089         [CMake] Add ENABLE_RESOURCE_LOAD_STATISTICS to WebKitFeatures.cmake
4090         https://bugs.webkit.org/show_bug.cgi?id=192574
4091
4092         Reviewed by Michael Catanzaro.
4093
4094         * Scripts/webkitperl/FeatureList.pm:
4095
4096 2018-12-10  Don Olmstead  <don.olmstead@sony.com>
4097
4098         Sync FeatureList.pm
4099         https://bugs.webkit.org/show_bug.cgi?id=192565
4100
4101         Reviewed by Michael Catanzaro.
4102
4103         * Scripts/webkitperl/FeatureList.pm:
4104
4105 2018-12-10  Wenson Hsieh  <wenson_hsieh@apple.com>
4106
4107         [iOS] Unable to upload data that conforms to "public.item" but not "public.content"
4108         https://bugs.webkit.org/show_bug.cgi?id=192555
4109         <rdar://problem/35204990>
4110
4111         Reviewed by Tim Horton.
4112
4113         Add a test to verify that `.p12` files may be uploaded as files via drag and drop. "com.rsa.pkcs-12" is an
4114         example of a data type that conforms to "public.item", but not "public.content"; before this patch, we would
4115         only support uploading "public.content", so files such as these would not be accepted when dropping into file
4116         inputs, or be exposed as files on DataTransfer.
4117
4118         * TestWebKitAPI/Tests/ios/DragAndDropTestsIOS.mm:
4119         (TestWebKitAPI::TEST):
4120
4121 2018-12-10  David Kilzer  <ddkilzer@apple.com>
4122
4123         Injected bundle for WebKitTestRunner leaks WKTypeRef objects
4124         <https://webkit.org/b/192481>
4125         <rdar://problem/46539059>
4126
4127         Follow-up to address Darin's feedback.
4128
4129         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
4130         (WTR::TestRunner::shouldDumpPixels const):
4131         (WTR::TestRunner::whatToDump const):
4132         (WTR::TestRunner::shouldWaitUntilDone const):
4133         (WTR::TestRunner::shouldDumpFrameLoadCallbacks):
4134         (WTR::TestRunner::didReceiveServerRedirectForProvisionalNavigation const):
4135         (WTR::TestRunner::secureEventInputIsEnabled const):
4136         (WTR::TestRunner::isStatisticsPrevalentResource):
4137         (WTR::TestRunner::isStatisticsVeryPrevalentResource):
4138         (WTR::TestRunner::isStatisticsRegisteredAsSubresourceUnder):
4139         (WTR::TestRunner::isStatisticsRegisteredAsSubFrameUnder):
4140         (WTR::TestRunner::isStatisticsRegisteredAsRedirectingTo):
4141         (WTR::TestRunner::isStatisticsHasHadUserInteraction):
4142         (WTR::TestRunner::isStatisticsGrandfathered):
4143         (WTR::TestRunner::hasDOMCache):
4144         (WTR::TestRunner::keyExistsInKeychain):
4145
4146 2018-12-10  Jonathan Bedard  <jbedard@apple.com>
4147
4148         webkitpy: Ref tests don't respect platform specific expectations
4149         https://bugs.webkit.org/show_bug.cgi?id=192515
4150         <rdar://problem/46564839>
4151
4152         Reviewed by Lucas Forschler.
4153
4154         * Scripts/webkitpy/port/base.py:
4155         (Port._expected_baselines_for_suffixes): Accept multiple suffixes so ref tests can use this function.
4156         (Port.expected_baselines): Move implementation to _expected_baselines_for_suffixes.
4157         (Port.expected_filename): Remove irrelevant FIXME, code clean-up.
4158         (Port.reference_files): Instead of just searching a single directory, use _expected_baselines_for_suffixes to
4159         search all platform expectations as well.
4160         * Scripts/webkitpy/port/base_unittest.py:
4161         (test_ref_tests_platform_directory):
4162
4163 2018-12-10  Chris Dumez  <cdumez@apple.com>
4164
4165         Add SPI to allow the client to set the user-agent at main frame level, from the UIProcess
4166         https://bugs.webkit.org/show_bug.cgi?id=192509
4167         <rdar://problem/46500832>
4168
4169         Reviewed by Alex Christensen.
4170
4171         Add API test coverage.
4172
4173         * TestWebKitAPI/Tests/WebKitCocoa/WebsitePolicies.mm:
4174         (-[DataMappingSchemeHandler addMappingFromURLString:toData:]):
4175         (-[DataMappingSchemeHandler webView:startURLSchemeTask:]):
4176         (-[DataMappingSchemeHandler webView:stopURLSchemeTask:]):
4177         (-[CustomUserAgentDelegate _webView:decidePolicyForNavigationAction:userInfo:decisionHandler:]):
4178         (-[CustomUserAgentDelegate webView:didFinishNavigation:]):
4179
4180 2018-12-10  Wenson Hsieh  <wenson_hsieh@apple.com>
4181
4182         [iOS] Caret is obscured by finger when dragging over an editable element
4183         https://bugs.webkit.org/show_bug.cgi?id=192499
4184         <rdar://problem/46570101>
4185
4186         Reviewed by Tim Horton.
4187
4188         Augment some existing API tests to check that the `precise` flag is either on or off on `UIDropProposal`.
4189
4190         * TestWebKitAPI/Tests/ios/DragAndDropTestsIOS.mm:
4191         * TestWebKitAPI/cocoa/DragAndDropSimulator.h:
4192         * TestWebKitAPI/ios/DragAndDropSimulatorIOS.mm:
4193         (-[DragAndDropSimulator _resetSimulatedState]):
4194         (-[DragAndDropSimulator lastKnownDropProposal]):
4195
4196         Rename `currentDropProposal` to `lastKnownDropProposal`, and expose it as a readonly property.
4197
4198         (-[DragAndDropSimulator _concludeDropAndPerformOperationIfNecessary]):
4199         (-[DragAndDropSimulator _advanceProgress]):
4200         (-[DragAndDropSimulator setShowCustomActionSheetBlock:]):
4201         (-[DragAndDropSimulator showCustomActionSheetBlock]):
4202         (-[DragAndDropSimulator setConvertItemProvidersBlock:]):
4203         (-[DragAndDropSimulator convertItemProvidersBlock]):
4204         (-[DragAndDropSimulator setOverridePerformDropBlock:]):
4205         (-[DragAndDropSimulator overridePerformDropBlock]):
4206         (-[DragAndDropSimulator setOverrideDragUpdateBlock:]):
4207         (-[DragAndDropSimulator overrideDragUpdateBlock]):
4208         (-[DragAndDropSimulator setDropCompletionBlock:]):
4209         (-[DragAndDropSimulator dropCompletionBlock]):
4210
4211         Refactor these properties to return and take normal Objective-C blocks, rather than `BlockPtr`s. However, use
4212         `BlockPtr` instance variables to manage the lifetimes of these blocks.
4213
4214         (-[DragAndDropSimulator _webView:willUpdateDropProposalToProposal:forSession:]):
4215         (-[DragAndDropSimulator _webView:willUpdateDataInteractionOperationToOperation:forSession:]): Deleted.
4216
4217         Update this to use the new WebKit delegate hook for overriding the drop proposal.
4218
4219 2018-12-10  Michael Catanzaro  <mcatanzaro@igalia.com>
4220
4221         [WPE][GTK] run-minibrowser improperly creates webkit-flatpak environment
4222         https://bugs.webkit.org/show_bug.cgi?id=190241
4223
4224         Reviewed by Carlos Garcia Campos.
4225
4226         run-minibrowser calls into webkit-flatpak to check if a flatpak environment is available.
4227         Currently this actually creates the directories needed for the flatpak environment. Fix it.
4228
4229         * flatpak/flatpakutils.py:
4230         (WebkitFlatpak.clean_args):
4231         (WebkitFlatpak.run):
4232
4233 2018-12-10  Michael Catanzaro  <mcatanzaro@igalia.com>
4234
4235         [GTK] Don't use the slice allocator
4236         https://bugs.webkit.org/show_bug.cgi?id=192360
4237
4238         Reviewed by Carlos Garcia Campos.
4239
4240         * MiniBrowser/gtk/main.c:
4241         (aboutDataRequestFree):
4242         (aboutDataRequestNew):
4243
4244 2018-12-10  Tim Horton  <timothy_horton@apple.com>
4245
4246         WKWebView should support custom tintColor
4247         https://bugs.webkit.org/show_bug.cgi?id=192518
4248         <rdar://problem/37243261>
4249
4250         Reviewed by Wenson Hsieh.
4251
4252         * TestWebKitAPI/Tests/WebKitCocoa/SystemColors.mm:
4253         (TestWebKitAPI::TEST):
4254         Add a test that tintColor affects UITextInputTraits' interaction colors.
4255
4256 2018-12-09  Wenson Hsieh  <wenson_hsieh@apple.com>
4257
4258         [iOS] DragAndDropTests.RespectsExternalSourceFidelityRankings is flaky
4259         https://bugs.webkit.org/show_bug.cgi?id=192524
4260
4261         Reviewed by Ryosuke Niwa.
4262
4263         This test started failing on certain builds of iOS where UIKit now attempts to reveal the selection by scrolling
4264         (see <rdar://problem/28300343>). This API test simulates two drops from external sources, both from the point
4265         (300, 400) to (100, 300) in window coordinates. On these aforementioned builds of iOS, what happens is that the
4266         first drop inserts text that overflows the editable region by an enormous amount, which creates an extremely
4267         wide selection rect and increases the width of the document; revealing this selection causes the web view to
4268         scroll horizontally, such that the second attempt to simulate a drag from (300, 400) to (100, 300) fails, since
4269         these window coordinates no longer correspond to the drop destination element in the document.
4270
4271         To fix this test, we simply mark the drop destination as `overflow: hidden` to ensure that we don't try and
4272         scroll horizontally after the first drop.
4273
4274         * TestWebKitAPI/Tests/WebKitCocoa/autofocus-contenteditable.html:
4275
4276 2018-12-08  Daniel Bates  <dabates@apple.com>
4277
4278         Fix lldb_webkit.py following r238771
4279         (https://bugs.webkit.org/show_bug.cgi?id=190234)
4280
4281         Substitute WTFURLProvider for WebCoreURLProvider in one call site that was inadvertently
4282         missed in r238771.
4283
4284         * lldb/lldb_webkit.py:
4285         (WebCoreDocumentProvider.url):
4286
4287 2018-12-07  Aakash Jain  <aakash_jain@apple.com>
4288
4289         [ews-build] check-patch-relevance failure should not mark the overall build as failure
4290         https://bugs.webkit.org/show_bug.cgi?id=192510
4291
4292         Reviewed by Lucas Forschler.
4293