WKContentViewEditingActions API test always fails
[WebKit-https.git] / Tools / ChangeLog
1 2017-06-14  Tim Horton  <timothy_horton@apple.com>
2
3         WKContentViewEditingActions API test always fails
4         https://bugs.webkit.org/show_bug.cgi?id=173374
5
6         Reviewed by Wenson Hsieh.
7
8         * TestWebKitAPI/Tests/WebKit2Cocoa/WKContentViewEditingActions.mm:
9         (TEST):
10         selectAll isn't working, because canPerformAction for selectAll returns NO
11         if selectionIsNone (which is true in the non-contenteditable case).
12         Instead, make use of r218180's test page, which knows how to select itself.
13         Also, reset the pasteboard at the beginning of the test to reduce confusion
14         (I landed the test broken because my simulator had the correct text
15         stuck in its pasteboard).
16
17 2017-06-14  Jonathan Bedard  <jbedard@apple.com>
18
19         Configure screen scale for running layout tests on plus devices
20         https://bugs.webkit.org/show_bug.cgi?id=173319
21
22         Reviewed by Tim Horton.
23
24         * DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj: Include UIKitTestSPI.h in project.
25         * DumpRenderTree/mac/DumpRenderTree.mm:
26         (dumpRenderTree): Set screen scale to 2.0.
27         * TestRunnerShared/spi/UIKitTestSPI.h: Copied from Tools/WebKitTestRunner/ios/UIKitSPI.h,
28         add _setScale for UIScreen.
29         * WebKitTestRunner/WebKitTestRunner.xcodeproj/project.pbxproj: Include UIKitTestSPI.h in project.
30         * WebKitTestRunner/cocoa/TestRunnerWKWebView.mm: Import UIKitTestSPI.h instead of UIKitSPI.h.
31         * WebKitTestRunner/ios/HIDEventGenerator.h: Ditto.
32         * WebKitTestRunner/ios/HIDEventGenerator.mm: Ditto.
33         * WebKitTestRunner/ios/PlatformWebViewIOS.mm: Ditto.
34         * WebKitTestRunner/ios/TestControllerIOS.mm: Ditto.
35         (WTR::TestController::platformInitialize): Set screen scale to 2.0.
36         * WebKitTestRunner/ios/UIKitSPI.h: Moved to TestRunnerShared/spi/UIKitTestSPI.h.
37         * WebKitTestRunner/ios/UIScriptControllerIOS.mm: Import UIKitTestSPI.h instead of UIKitSPI.h.
38         * WebKitTestRunner/ios/mainIOS.mm: Ditto.
39
40 2017-06-14  Alexey Proskuryakov  <ap@apple.com>
41
42         Add iOS 11 support to the bot watcher's dashboard
43         https://bugs.webkit.org/show_bug.cgi?id=173369
44
45         Reviewed by Lucas Forschler.
46
47         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Images/IOS11.png: Added.
48         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Images/IOS11@2x.png: Added.
49         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Images/IOS11Simulator.png: Added.
50         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Images/IOS11Simulator@2x.png: Added.
51         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/Dashboard.js:
52         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Styles/Main.css:
53
54 2017-06-14  Carlos Alberto Lopez Perez  <clopez@igalia.com>
55
56         [GTK][WPE] Raise the timeout values for layout tests
57         https://bugs.webkit.org/show_bug.cgi?id=173368
58
59         Reviewed by Carlos Garcia Campos.
60
61         Raise the values to 15 seconds in Release builds and 30 seconds (2x) in Debug builds.
62         When running under valgrind a 10x multiplier is applied.
63
64         * Scripts/webkitpy/port/gtk.py:
65         (GtkPort.default_timeout_ms):
66         * Scripts/webkitpy/port/gtk_unittest.py:
67         (GtkPortTest.test_default_timeout_ms):
68         * Scripts/webkitpy/port/wpe.py:
69         (WPEPort.default_timeout_ms):
70         * Scripts/webkitpy/port/wpe_unittest.py: Copied from Tools/Scripts/webkitpy/port/gtk_unittest.py.
71         (WPEPortTest):
72         (WPEPortTest.make_port):
73         (WPEPortTest.test_default_timeout_ms):
74         (WPEPortTest.test_get_crash_log):
75
76 2017-06-14  Alex Christensen  <achristensen@webkit.org>
77
78         Test persistent WKHTTPCookieStorages on iOS.
79         https://bugs.webkit.org/show_bug.cgi?id=173284
80
81         * TestWebKitAPI/Tests/WebKit2Cocoa/WKHTTPCookieStore.mm:
82         (TEST):
83         Make the bots green again for now. There's still a problem, and I'll investigate and fix.
84
85 2017-06-14  Per Arne Vollan  <pvollan@apple.com>
86
87         [Win] DRT should not use disk cache.
88         https://bugs.webkit.org/show_bug.cgi?id=173361
89
90         Reviewed by Darin Adler.
91
92         Like on macOS/iOS, DRT on Windows should only use memory cache.
93
94         * DumpRenderTree/win/DumpRenderTree.cpp:
95         (setDefaultsToConsistentValuesForTesting):
96         (prepareConsistentTestingEnvironment):
97
98 2017-06-14  Nael Ouedraogo  <nael.ouedraogo@crf.canon.fr>
99
100         MediaSource duration attribute should not be equal to Infinity when set to a value greater than 2^64
101         https://bugs.webkit.org/show_bug.cgi?id=171668
102
103         Reviewed by Jer Noble.
104
105         MediaSource duration attribute is a double represented in MediaSource by a MediaTime instance created with
106         MediaTime::CreateWithDouble(). This method implements an overflow control mechanism which sets MediaTime to
107         Infinity when the double value passed as argument is greater than 2^64.
108
109         This patch removes the overflow control mechanism when time value is represented as a double. This patch also
110         modifies the behavior of mathematical operations between a double MediaTime and rational MediaTime: the rational
111         MediaTime is converted to a double before applying the operation. Double MediaTime precision is the same as for
112         double. Overflow mechanisms still apply to the conversion of a double MediaTime to rational with setTimescale()
113         method. No behavior change for rational MediaTime.
114
115         * TestWebKitAPI/Tests/WTF/MediaTime.cpp: Add tests to check operation results between double and rational MediaTime.
116         (TestWebKitAPI::TEST):
117
118 2017-06-13  Alex Christensen  <achristensen@webkit.org>
119
120         Test persistent WKHTTPCookieStorages on iOS
121         https://bugs.webkit.org/show_bug.cgi?id=173284
122         <rdar://problem/32260156>
123
124         * TestWebKitAPI/Tests/WebKit2Cocoa/WKHTTPCookieStore.mm:
125         (TEST):
126
127 2017-06-13  Matt Rajca  <mrajca@apple.com>
128
129         WebsitePolicies: let clients select specific autoplay quirks
130         https://bugs.webkit.org/show_bug.cgi?id=173343
131
132         Reviewed by Alex Christensen.
133
134         * TestWebKitAPI/Tests/WebKit2Cocoa/WebsitePolicies.mm:
135         (-[AutoplayPoliciesDelegate _webView:decidePolicyForNavigationAction:decisionHandler:]):
136         (TEST): Updated tests.
137
138 2017-06-13  Daniel Bates  <dabates@apple.com>
139
140         Implement W3C Secure Contexts Draft Specification
141         https://bugs.webkit.org/show_bug.cgi?id=158121
142         <rdar://problem/26012994>
143
144         Reviewed by Brent Fulgham.
145
146         Part 4
147
148         Expose the isSecureContext attribute by default in DumpRenderTree and WebKitTestRunner.
149         Teach DumpRenderTree for Mac and WebKitTestRunner to parse the test option enableIsSecureContextAttribute
150         to toggle the runtime enabled feature flag isSecureContextAttributeEnabled.
151
152         * DumpRenderTree/TestOptions.h:
153         * DumpRenderTree/TestOptions.mm:
154         (TestOptions::TestOptions):
155         * DumpRenderTree/mac/DumpRenderTree.mm:
156         (setWebPreferencesForTestOptions):
157         * DumpRenderTree/win/DumpRenderTree.cpp:
158         (enableExperimentalFeatures):
159         * WebKitTestRunner/TestController.cpp:
160         (WTR::TestController::resetPreferencesToConsistentValues):
161         (WTR::updateTestOptionsFromTestHeader):
162         * WebKitTestRunner/TestOptions.h:
163         (WTR::TestOptions::hasSameInitializationOptions):
164
165 2017-06-13  Alex Christensen  <achristensen@webkit.org>
166
167         Test persistent WKHTTPCookieStorages on iOS
168         https://bugs.webkit.org/show_bug.cgi?id=173284
169         <rdar://problem/32260156>
170
171         Reviewed by Alexey Proskuryakov.
172
173         * TestWebKitAPI/Tests/WebKit2Cocoa/WKHTTPCookieStore.mm:
174         (TEST):
175
176 2017-06-13  Carlos Garcia Campos  <cgarcia@igalia.com>
177
178         [GTK] Blob download doesn't work
179         https://bugs.webkit.org/show_bug.cgi?id=172442
180
181         Reviewed by Carlos Alberto Lopez Perez.
182
183         Add a unit test to check blob downloads.
184
185         * TestWebKitAPI/Tests/WebKit2Gtk/TestDownloads.cpp:
186         (testBlobDownload):
187         (beforeAll):
188
189 2017-06-13  Carlos Garcia Campos  <cgarcia@igalia.com>
190
191         [GTK] Do not include WTR, DumpRendererTree and ImageDiff in tarballs
192         https://bugs.webkit.org/show_bug.cgi?id=173316
193
194         Reviewed by Alex Christensen.
195
196         It's not really possible to run layout tests from the tarball, so it's better not to include those files.
197
198         * gtk/manifest.txt.in:
199
200 2017-06-13  Carlos Garcia Campos  <cgarcia@igalia.com>
201
202         [WTR] Crash in WebGeolocationManagerProxy::~WebGeolocationManagerProxy() when running several tests
203         https://bugs.webkit.org/show_bug.cgi?id=173315
204
205         Reviewed by Darin Adler.
206
207         This has started to happen after r218165, but I don't think it's a regression, but that r218165 revealed the bug
208         somehow in WTR. The problem is that GeolocationProviderMock keeps a pointer to the WKGeolocationManagerRef
209         returned by WKContextGetGeolocationManager. But in TestController::generatePageConfiguration() the context is
210         freed before the GeolocationProviderMock. When the GeolocationProviderMock is then destroyed, it calls
211         WKGeolocationManagerSetProvider(m_geolocationManager, 0); but the WKGeolocationManagerRef has already been
212         destroyed. GeolocationProviderMock should keep a reference to the WKContext to ensure the
213         WKGeolocationManagerRef is not destroyed.
214
215         * WebKitTestRunner/GeolocationProviderMock.cpp:
216         (WTR::GeolocationProviderMock::GeolocationProviderMock):
217         * WebKitTestRunner/GeolocationProviderMock.h:
218
219 2017-06-13  Wenson Hsieh  <wenson_hsieh@apple.com>
220
221         Unable to paste text that was copied from a page into the universal search field
222         https://bugs.webkit.org/show_bug.cgi?id=173293
223         <rdar://problem/32440918>
224
225         Reviewed by Ryosuke Niwa.
226
227         Adds 2 new unit tests for copying plain and rich selected web content.
228         See WebCore and WebKit ChangeLogs for more detail.
229
230         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
231         * TestWebKitAPI/Tests/WebKit2Cocoa/rich-and-plain-text.html: Added.
232         * TestWebKitAPI/Tests/ios/UIPasteboardTests.mm: Added.
233         (TestWebKitAPI::dataForPasteboardType):
234         (TestWebKitAPI::setUpWebViewForPasteboardTests):
235         (TestWebKitAPI::TEST):
236
237 2017-06-13  Joanmarie Diggs  <jdiggs@igalia.com>
238
239         AX: [ATK] Implement missing AtkRelation types
240         https://bugs.webkit.org/show_bug.cgi?id=155494
241
242         Reviewed by Darin Adler.
243
244         Add additional methods to test ARIA properties which are exposed via
245         AtkRelation. Implement ATK support for ariaOwnsElementAtIndex().
246
247         * WebKitTestRunner/InjectedBundle/AccessibilityUIElement.h:
248         (WTR::AccessibilityUIElement::ariaLabelledByElementAtIndex):
249         (WTR::AccessibilityUIElement::ariaDescribedByElementAtIndex):
250         (WTR::AccessibilityUIElement::ariaOwnsReferencingElementAtIndex):
251         (WTR::AccessibilityUIElement::ariaFlowToReferencingElementAtIndex):
252         (WTR::AccessibilityUIElement::ariaControlsReferencingElementAtIndex):
253         (WTR::AccessibilityUIElement::ariaLabelledByReferencingElementAtIndex):
254         (WTR::AccessibilityUIElement::ariaDescribedByReferencingElementAtIndex):
255         * WebKitTestRunner/InjectedBundle/Bindings/AccessibilityUIElement.idl:
256         * WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
257         (WTR::AccessibilityUIElement::ariaOwnsElementAtIndex):
258         (WTR::AccessibilityUIElement::ariaOwnsReferencingElementAtIndex):
259         (WTR::AccessibilityUIElement::ariaFlowToReferencingElementAtIndex):
260         (WTR::AccessibilityUIElement::ariaControlsReferencingElementAtIndex):
261         (WTR::AccessibilityUIElement::ariaLabelledByElementAtIndex):
262         (WTR::AccessibilityUIElement::ariaLabelledByReferencingElementAtIndex):
263         (WTR::AccessibilityUIElement::ariaDescribedByElementAtIndex):
264         (WTR::AccessibilityUIElement::ariaDescribedByReferencingElementAtIndex):
265
266 2017-06-12  Daniel Bates  <dabates@apple.com>
267
268         Add unit tests for SecurityOrigin::IsPotentiallyTrustworthy()
269         https://bugs.webkit.org/show_bug.cgi?id=173286
270         <rdar://problem/32726102>
271
272         Reviewed by Brent Fulgham.
273
274         * TestWebKitAPI/Tests/WebCore/SecurityOrigin.cpp:
275         (TestWebKitAPI::TEST_F):
276
277 2017-06-12  Lucas Forschler  <lforschler@apple.com>
278
279         <rdar://problem/32683422>
280         Teach copy-webkitlibraries-to-product-directory script about updated libraries.
281
282         Reviewed by Conrad Schultz.
283
284         * Scripts/copy-webkitlibraries-to-product-directory:
285
286 2017-06-12  Tim Horton  <timothy_horton@apple.com>
287
288         [iOS] Cmd-C doesn't copy text from WKWebView
289         https://bugs.webkit.org/show_bug.cgi?id=173277
290         <rdar://problem/32396742>
291
292         Reviewed by Dan Bernstein.
293
294         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
295         * Tests/WebKit2Cocoa/WKContentViewEditingActions.mm:
296         Add a test ensuring that -copy on WKContentView will cause text to be copied.
297
298 2017-06-12  Jiewen Tan  <jiewen_tan@apple.com>
299
300         [WebCrypto] Remove experimental feature flag of SubtleCrypto
301         https://bugs.webkit.org/show_bug.cgi?id=173197
302         <rdar://problem/32688148>
303
304         Reviewed by Brent Fulgham.
305
306         * DumpRenderTree/mac/DumpRenderTree.mm:
307         (enableExperimentalFeatures):
308         * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
309         (WTR::InjectedBundle::beginTesting):
310         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
311         (WTR::TestRunner::setSubtleCryptoEnabled): Deleted.
312         * WebKitTestRunner/InjectedBundle/TestRunner.h:
313
314 2017-06-12  Wenson Hsieh  <wenson_hsieh@apple.com>
315
316         [iOS DnD] Allow the injected bundle to add client data when writing an image to the pasteboard
317         https://bugs.webkit.org/show_bug.cgi?id=173238
318         <rdar://problem/31943370>
319
320         Reviewed by Ryosuke Niwa and Tim Horton.
321
322         Add a new unit test to verify that data inserted by the injected bundle when beginning a drag on an image
323         element is plumbed across to the UI delegate. Also refactors injected bundle unit tests to use the new version
324         of adjustedDataInteractionItemProvidersForItemProvider: that takes representing objects and additional data.
325
326         * TestWebKitAPI/Tests/ios/DataInteractionTests.mm:
327         (TestWebKitAPI::TEST):
328         * TestWebKitAPI/ios/DataInteractionSimulator.h:
329         * TestWebKitAPI/ios/DataInteractionSimulator.mm:
330         (-[DataInteractionSimulator _webView:adjustedDataInteractionItemProvidersForItemProvider:representingObjects:additionalData:]):
331         (-[DataInteractionSimulator _webView:adjustedDataInteractionItemProviders:]): Deleted.
332
333 2017-06-12  Wenson Hsieh  <wenson_hsieh@apple.com>
334
335         WebItemProviderPasteboard should call its completion block immediately after a synchronous load
336         https://bugs.webkit.org/show_bug.cgi?id=173225
337         <rdar://problem/32713144>
338
339         Reviewed by Tim Horton.
340
341         Adds a new unit test to verify whether the completion block is called synchronously or asynchronously, in both
342         cases where the synchronous timeout is very large, and the synchronous timeout is not used (0).
343
344         * TestWebKitAPI/Tests/ios/DataInteractionTests.mm:
345         (TestWebKitAPI::TEST):
346
347 2017-06-12  Jonathan Bedard  <jbedard@apple.com>
348
349         Return correct process names for iOS on-device testing
350         https://bugs.webkit.org/show_bug.cgi?id=173263
351
352         Reviewed by Alex Christensen.
353
354         When running tests on iOS devices, process names do not end with '.Development'
355         as they do on Mac and iOS simulator.
356
357         * WebKitTestRunner/TestController.cpp:
358         (WTR::TestController::webProcessName): Return correct process name without '.Development'
359         for iOS on-device testing.
360         (WTR::TestController::networkProcessName): Ditto.
361         (WTR::TestController::databaseProcessName): Ditto.
362
363 2017-06-12  Chris Dumez  <cdumez@apple.com>
364
365         Regression(r217867): Legacy SessionHistoryEntryData format should not change
366         https://bugs.webkit.org/show_bug.cgi?id=173267
367         <rdar://problem/32701257>
368
369         Reviewed by Simon Fraser.
370
371         Restrict test to stop covering saving / restore of scrollRestoration via the legacy
372         SessionHistoryEntryData. Maintain coverage for the default value of scrollRestoration
373         though as this covers the crash that r217867 was fixing.
374
375         * TestWebKitAPI/Tests/WebKit2/RestoreSessionState.cpp:
376         (TestWebKitAPI::createSessionStateData):
377         (TestWebKitAPI::TEST):
378         (TestWebKitAPI::createSessionStateDataContainingScrollRestoration): Deleted.
379
380 2017-06-12  Carlos Garcia Campos  <cgarcia@igalia.com>
381
382         [GTK] Stop dismissing menus attached to the web view for every injected event
383         https://bugs.webkit.org/show_bug.cgi?id=172708
384
385         Reviewed by Alex Christensen.
386
387         It's a workaround we added in r184015 that has worked so far for the context menu, but doesn't really work now
388         that we also attach popup menus to the web view. We really need to be able to show a popup menu, and then send
389         events while the menu is open.
390
391         * WebKitTestRunner/InjectedBundle/EventSendingController.cpp:
392         (WTR::EventSendingController::contextClick): Use WKBundlePageCopyContextMenuAtPointInWindow() also in GTK+ port.
393         * WebKitTestRunner/gtk/EventSenderProxyGtk.cpp:
394         (WTR::EventSenderProxy::dispatchEvent): Stop calling PlatformWebView::dismissAllPopupMenus().
395
396 2017-06-12  Miguel Gomez  <magomez@igalia.com>
397
398         [GTK][WPE] Enable GStreamer GL on development builds
399         https://bugs.webkit.org/show_bug.cgi?id=173248
400
401         Enable GStreamer GL for GTK and WPE.
402
403         Reviewed by Carlos Garcia Campos.
404
405         * Scripts/webkitperl/FeatureList.pm:
406
407 2017-06-12  Carlos Garcia Campos  <cgarcia@igalia.com>
408
409         Unreviewed. Fix GTK+ test /webkit2/WebKitWebView/notification after r216641.
410
411         Notifications are no longer cleared on page navigation.
412
413         * TestWebKitAPI/Tests/WebKit2Gtk/TestWebKitWebView.cpp:
414         (testWebViewNotification):
415
416 2017-06-11  Carlos Garcia Campos  <cgarcia@igalia.com>
417
418         Unreviewed. Fix GTK+ test /webkit2/WebKitAutomationSession/request-session after r217831.
419
420         DBus interface and object path names were updated in r217831.
421
422         * TestWebKitAPI/Tests/WebKit2Gtk/TestAutomationSession.cpp:
423
424 2017-06-10  Dan Bernstein  <mitz@apple.com>
425
426         Reverted r218056 because it made the IDE reindex constantly.
427
428         * ContentExtensionTester/Configurations/DebugRelease.xcconfig:
429         * DumpRenderTree/mac/Configurations/DebugRelease.xcconfig:
430         * ImageDiff/cg/Configurations/DebugRelease.xcconfig:
431         * MiniBrowser/Configurations/DebugRelease.xcconfig:
432         * MobileMiniBrowser/Configurations/DebugRelease.xcconfig:
433         * TestWebKitAPI/Configurations/DebugRelease.xcconfig:
434         * WebEditingTester/Configurations/DebugRelease.xcconfig:
435         * WebKitTestRunner/Configurations/DebugRelease.xcconfig:
436
437 2017-06-10  Dan Bernstein  <mitz@apple.com>
438
439         [Xcode] With Xcode 9 developer beta, everything rebuilds when switching between command-line and IDE
440         https://bugs.webkit.org/show_bug.cgi?id=173223
441
442         Reviewed by Sam Weinig.
443
444         The rebuilds were happening due to a difference in the compiler options that the IDE and
445         xcodebuild were specifying. Only the IDE was passing the -index-store-path option. To make
446         xcodebuild pass that option, too, set CLANG_INDEX_STORE_ENABLE to YES if it is unset, and
447         specify an appropriate path in CLANG_INDEX_STORE_PATH.
448
449         * ContentExtensionTester/Configurations/DebugRelease.xcconfig:
450         * DumpRenderTree/mac/Configurations/DebugRelease.xcconfig:
451         * ImageDiff/cg/Configurations/DebugRelease.xcconfig:
452         * MiniBrowser/Configurations/DebugRelease.xcconfig:
453         * MobileMiniBrowser/Configurations/DebugRelease.xcconfig:
454         * TestWebKitAPI/Configurations/DebugRelease.xcconfig:
455         * WebEditingTester/Configurations/DebugRelease.xcconfig:
456         * WebKitTestRunner/Configurations/DebugRelease.xcconfig:
457
458 2017-06-10  Jonathan Bedard  <jbedard@apple.com>
459
460         webkitpy: Reduce polling in ServerProcess
461         https://bugs.webkit.org/show_bug.cgi?id=173116
462
463         Reviewed by Ryosuke Niwa.
464
465         We should be smarter about polling. We do not need to poll every time a line is read from
466         stdout and stderr since lines are usually read from cached data. We should only poll
467         when extracting that cached data from stdout and stderr.
468
469         * Scripts/webkitpy/port/driver.py:
470         (Driver._read_block): Rely on output of the ServerProcess to detect a crash or a timeout
471         and on ServerProcess to poll the process if not data is available in stdout and stderr.
472         * Scripts/webkitpy/port/driver_unittest.py:
473         (DriverTest.test_read_block_crashed_process): Test that the Driver will handle a crashing
474         ServerProcess.
475         * Scripts/webkitpy/port/server_process.py:
476         (ServerProcess._read): Allow for data to be read from _output even if the process has
477         crashed. Only poll the process if data needs to be extracted from stdout or stderr. 
478         * Scripts/webkitpy/port/server_process_mock.py:
479         (MockServerProcess): Add number_of_times_polled.
480         (MockServerProcess.poll): Increment number_of_times_polled.
481         (MockServerProcess.has_crashed): Poll before returning crash state.
482         (MockServerProcess.read_stdout_line): MockServerProcess should return None if it has crashed,
483         just like a ServerProcess would.
484         (MockServerProcess.read_stdout): Ditto.
485         * Scripts/webkitpy/port/server_process_unittest.py:
486         (TestServerProcess.test_basic): Use stdin.readline() instead of time.sleep() to prevent the
487         process from ending before stdout and stderr are read. This is the reason this test was flakey.
488         (TestServerProcess):
489         (TestServerProcess.test_process_crashing): Test that when a process crashes, data can be read until
490         the processes is polled.
491         (TestServerProcess.test_process_crashing_no_data): Test that when a process which has not output any
492         data to stdout and stderr crashes, ServerProcess._read(...) polls the process to detect the crash.
493
494 2017-06-10  Andy Estes  <aestes@apple.com>
495
496         [QuickLook] PreviewLoader needs to check if its ResourceLoader has reached the terminal state before calling didReceiveResponse() and friends
497         https://bugs.webkit.org/show_bug.cgi?id=173190
498         <rdar://problem/31360659>
499
500         Reviewed by Brady Eidson.
501         
502         Added a release assert that tries to create a proper test failure if the web process crashes.
503
504         * TestWebKitAPI/Tests/WebKit2Cocoa/QuickLook.mm:
505         (-[QuickLookDecidePolicyDelegate _webViewWebProcessDidCrash:]):
506
507 2017-06-09  Wenson Hsieh  <wenson_hsieh@apple.com>
508
509         [iOS DnD] Add a hook to perform two-step drops in editable content
510         https://bugs.webkit.org/show_bug.cgi?id=172992
511         <rdar://problem/32590174>
512
513         Reviewed by Tim Horton.
514
515         Adds 2 new API tests to cover using the injected editing bundle to override performTwoStepDrop.
516         Tests:  DataInteractionTests.InjectedBundleOverridePerformTwoStepDrop
517                 DataInteractionTests.InjectedBundleAllowPerformTwoStepDrop
518
519         * TestWebKitAPI/Tests/WebKit2Cocoa/BundleEditingDelegatePlugIn.mm:
520         (-[BundleEditingDelegatePlugIn webProcessPlugIn:didCreateBrowserContextController:]):
521         (-[BundleEditingDelegatePlugIn _webProcessPlugInBrowserContextController:performTwoStepDrop:atDestination:isMove:]):
522
523         Allow the BundleOverridePerformTwoStepDrop bundle parameter to determine whether or not two-step drops should
524         be overridden. Currently, this is overridden to just return true.
525
526         * TestWebKitAPI/Tests/ios/DataInteractionTests.mm:
527         (TestWebKitAPI::TEST):
528         * WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
529         (WTR::InjectedBundlePage::InjectedBundlePage):
530
531 2017-06-09  Zan Dobersek  <zdobersek@igalia.com>
532
533         [WPE] Enable ENCRYPTED_MEDIA for build-webkit builds
534         https://bugs.webkit.org/show_bug.cgi?id=173103
535
536         Reviewed by Xabier Rodriguez-Calvar.
537
538         * Scripts/webkitperl/FeatureList.pm: Enable ENCRYPTED_MEDIA flag
539         when building the WPE port through build-webkit.
540
541 2017-06-09  Zan Dobersek  <zdobersek@igalia.com>
542
543         [WPE] Enable MEDIA_SOURCE for build-webkit builds
544         https://bugs.webkit.org/show_bug.cgi?id=173136
545
546         Reviewed by Xabier Rodriguez-Calvar.
547
548         * Scripts/webkitperl/FeatureList.pm: Enable the MEDIA_SOURCE feature for WPE.
549
550 2017-06-08  Carlos Garcia Campos  <cgarcia@igalia.com>
551
552         [GTK] Use API::FormClient instead of the C API in WebKitFormClient
553         https://bugs.webkit.org/show_bug.cgi?id=173098
554
555         Reviewed by Žan Doberšek.
556
557         Fix memory leak and runtime warning when running /webkit2/WebKitWebView/submit-form. The web extension is
558         assuming that all tests containing forms define ids for the form elements like
559         /webkit2/WebKitWebExtension/form-controls-associated-signal does.
560
561         * TestWebKitAPI/Tests/WebKit2Gtk/WebExtensionTest.cpp:
562         (formControlsAssociatedCallback):
563
564 2017-06-08  Jonathan Bedard  <jbedard@apple.com>
565
566         webkitpy: Run sample/spindump on iOS devices
567         https://bugs.webkit.org/show_bug.cgi?id=171881
568         <rdar://problem/32084602>
569
570         Reviewed by Daniel Bates.
571
572         * Scripts/webkitpy/port/darwin.py:
573         (DarwinPort.sample_process): Only add sudo prefix if the platform is Mac, which
574         requires sudo to run spindump.
575         * Scripts/webkitpy/port/ios_device.py:
576         (IOSDevicePort.look_for_new_samples): Deleted.
577         (IOSDevicePort.sample_process): Deleted.
578         * Scripts/webkitpy/port/ios_device_unittest.py:
579         (IOSDeviceTest): iOS devices use 'ios' and their os_name.
580         (IOSDeviceTest.test_spindump):
581         (IOSDeviceTest.test_sample_process):
582         (IOSDeviceTest.test_sample_process_exception):
583         * Scripts/webkitpy/port/ios_simulator_unittest.py:
584         (IOSSimulatorTest): iOS Simulators run on Mac and use 'mac' as their os_name.
585
586 2017-06-08  Keith Miller  <keith_miller@apple.com>
587
588         WebAssembly: We should only create wrappers for functions that can be exported
589         https://bugs.webkit.org/show_bug.cgi?id=173088
590
591         Reviewed by Saam Barati.
592
593         Add quick mode for wasm tests.
594
595         * Scripts/run-jsc-stress-tests:
596
597 2017-06-08  Darin Adler  <darin@apple.com>
598
599         WTF tests have incorrect RefLogger lifetimes making it impossible to test with Address Sanitizer
600         https://bugs.webkit.org/show_bug.cgi?id=173106
601
602         Reviewed by Sam Weinig.
603
604         * TestWebKitAPI/Tests/WTF/HashCountedSet.cpp: Define RefLogger objects first, so they are
605         destroyed last.
606         * TestWebKitAPI/Tests/WTF/HashMap.cpp: Ditto.
607         * TestWebKitAPI/Tests/WTF/HashSet.cpp: Ditto.
608
609 2017-06-07  Dan Bernstein  <mitz@apple.com>
610
611         [Cocoa] additionalReadAccessAllowedURLs doesn’t preserve non-Latin1 paths
612         https://bugs.webkit.org/show_bug.cgi?id=173086
613
614         Reviewed by Andy Estes.
615
616         * TestWebKitAPI/Tests/WebKit2Cocoa/AdditionalReadAccessAllowedURLs.mm:
617         (TEST):
618
619 2017-06-07  Alexey Proskuryakov  <ap@apple.com>
620
621         Add High Sierra support to WebKit tools
622         https://bugs.webkit.org/show_bug.cgi?id=173080
623
624         Rubber-stamped by Daniel Bates.
625
626         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Images/HighSierra.png: Added.
627         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Images/HighSierra@2x.png: Added.
628         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/Dashboard.js:
629         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Styles/Main.css:
630         Added dashboard support.
631
632         * BuildSlaveSupport/build.webkit.org-config/wkbuild.py:
633         * BuildSlaveSupport/build.webkit.org-config/wkbuild_unittest.py:
634         Trigger the right build queues on check-in.
635
636         * Scripts/webkitpy/common/system/platforminfo.py:
637         * Scripts/webkitpy/common/system/platforminfo_unittest.py:
638         * Scripts/webkitpy/layout_tests/models/test_expectations.py:
639         * Scripts/webkitpy/port/mac.py:
640         * Scripts/webkitpy/port/mac_unittest.py:
641         * TestResultServer/static-dashboards/flakiness_dashboard.js:
642         Added cases for Sierra, and updated tests for new baseline search paths.
643
644 2017-06-07  Ryan Haddad  <ryanhaddad@apple.com>
645
646         Unreviewed, rolling out r217902.
647
648         This change appears to have caused imported/w3c/web-platform-
649         tests/fetch/api/cors tests to fail on El Capitan.
650
651         Reverted changeset:
652
653         "Teach run-webkit-tests how to run HTTPS Web Platform Tests"
654         https://bugs.webkit.org/show_bug.cgi?id=172930
655         http://trac.webkit.org/changeset/217902
656
657 2017-06-07  Daniel Bates  <dabates@apple.com>
658
659         Teach run-webkit-tests how to run HTTPS Web Platform Tests
660         https://bugs.webkit.org/show_bug.cgi?id=172930
661         <rdar://problem/32570201>
662
663         Reviewed by Youenn Fablet.
664
665         Some web platform tests need to be run from an HTTPS server in order to exercise functionality
666         that is conditioned on the page being delivered over a secure protocol. One example of such
667         a test is LayoutTests/imported/w3c/web-platform-tests/WebCryptoAPI/secure_context/crypto-subtle-secure-context-available.https.sub.html.
668
669         Ideally we should look to use wptrunner to run Web Platform Tests. For now, modify run-webkit-tests
670         to access web platform tests from an HTTPS server when the filename of the test contains ".https.".
671         This makes run-webkit-test match the behavior of wptrunner: <https://github.com/w3c/web-platform-tests/blob/7ce469d1c46dd45aacfe1b408bf2ad36a630e089/tools/manifest/item.py#L42>.
672
673         * Scripts/webkitpy/layout_tests/servers/web_platform_test_server.py:
674         (https_base_url): Parses the Web Platform Tests JSON configuration and returns the base URL
675         to the Web Platform Tests HTTPS server.
676         * Scripts/webkitpy/port/base.py:
677         (Port.to.web_platform_test_server_https_base_url): Turns around and calls https_base_url().
678         * Scripts/webkitpy/port/driver.py:
679         (Driver.__init__): Caches the base URL to the Web Platform Tests HTTPS server. Also rename
680         instance variables web_platform_test_server_doc_root, web_platform_test_server_base_url to
681         _web_platform_test_server_doc_root and _web_platform_test_server_base_url, respectively to
682         indicate that they should be considered private instance variables.
683         (Driver.is_web_platform_test): Update code for renamed instance variables.
684         (Driver):
685         (Driver._web_platform_test_base_url_for_test): Returns the URL to access the specified test.
686         (Driver.test_to_uri): Modified to use Driver._web_platform_test_base_url_for_test() to
687         determine the base URL to use to access the test.
688         (Driver.uri_to_test): Added logic to compute the filesystem local test name from a Web
689         Platform Tests HTTPS URL. Also updated code for renamed instance variables.
690
691 2017-06-07  Per Arne Vollan  <pvollan@apple.com>
692
693         Support removal of authentication data through the Website data store API.
694         https://bugs.webkit.org/show_bug.cgi?id=171217
695
696         Reviewed by Brady Eidson.
697
698         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
699         * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
700         (WTR::InjectedBundle::didReceiveMessageToPage):
701         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
702         (WTR::TestRunner::removeAllSessionCredentials):
703         (WTR::TestRunner::callDidRemoveAllSessionCredentialsCallback):
704         * WebKitTestRunner/InjectedBundle/TestRunner.h:
705         * WebKitTestRunner/TestController.h:
706         * WebKitTestRunner/TestInvocation.cpp:
707         (WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):
708         (WTR::TestInvocation::didRemoveAllSessionCredentials):
709         * WebKitTestRunner/TestInvocation.h:
710         * WebKitTestRunner/cocoa/TestControllerCocoa.mm:
711         (WTR::TestController::removeAllSessionCredentials):
712
713 2017-06-07  Charlie Turner  <cturner@igalia.com>
714
715         Add Charlie Turner as contributor
716         https://bugs.webkit.org/show_bug.cgi?id=173055
717
718         Reviewed by Carlos Alberto Lopez Perez.
719
720         I also ran the Tools/Scripts/validate-committer-lists --canonicalize command at the suggestion
721         of webkit-patch upload, which reordered some fields and removed a newline.
722
723         * Scripts/webkitpy/common/config/contributors.json:
724
725 2017-06-06  Chris Dumez  <cdumez@apple.com>
726
727         RELEASE_ASSERT(static_cast<size_t>(enumerationValue) < WTF_ARRAY_LENGTH(values)) hit in convertEnumerationToJS<WebCore::History::ScrollRestoration>()
728         https://bugs.webkit.org/show_bug.cgi?id=173033
729         <rdar://problem/32591099>
730
731         Reviewed by Simon Fraser.
732
733         Add API test coverage to make sure History's scrollRestoration is properly saved / restored via the
734         WKPageCopySessionState() / WKPageRestoreFromSessionState() C API.
735
736         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
737         * TestWebKitAPI/Tests/WebKit2/RestoreSessionState.cpp: Added.
738         (TestWebKitAPI::didFinishLoadForFrame):
739         (TestWebKitAPI::setPageLoaderClient):
740         (TestWebKitAPI::createSessionStateDataContainingScrollRestoration):
741         (TestWebKitAPI::TEST):
742
743 2017-06-06  Andy Estes  <aestes@apple.com>
744
745         REGRESSION (r199558): WKWebView upload file which name contains Chinese character results in garbled code
746         https://bugs.webkit.org/show_bug.cgi?id=172849
747         <rdar://problem/32567454>
748
749         Reviewed by Darin Adler.
750
751         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
752         * TestWebKitAPI/Tests/WebKit2Cocoa/RunOpenPanel.mm: Added.
753         (-[RunOpenPanelUIDelegate webView:runOpenPanelWithParameters:initiatedByFrame:completionHandler:]):
754         (TestWebKitAPI::TEST):
755
756 2017-06-06  Yoav Weiss  <yoav@yoav.ws>
757
758         [preload] Conditional support for media preloading and align media `as` values.
759         https://bugs.webkit.org/show_bug.cgi?id=172501
760
761         Reviewed by Dean Jackson.
762
763         Turn on media preloading preference for tests.
764
765         * DumpRenderTree/mac/DumpRenderTree.mm: Turn on media preloading preference.
766         * DumpRenderTree/win/DumpRenderTree.cpp: Turn on media preloading preference.
767         * WebKitTestRunner/TestController.cpp: Turn on media preloading preference.
768
769 2017-06-06  Jonathan Bedard  <jbedard@apple.com>
770
771         webkitpy: Return correct process names from SimulatorProcess
772         https://bugs.webkit.org/show_bug.cgi?id=172940
773
774         Reviewed by Aakash Jain.
775
776         * Scripts/webkitpy/port/darwin.py:
777         (DarwinPort.plist_data_from_bundle): Share plist access code for accessing different plist entries.
778         (DarwinPort.app_identifier_from_bundle): Use plist_data_from_bundle.
779         (DarwinPort.app_executable_from_bundle): Access name of app executable from provided app bundle.
780         * Scripts/webkitpy/port/driver.py:
781         (Driver.has_crashed): Use _server_process.process_name() instead of _server_process.name() since
782         _server_process.name() will not return the correct process name for iOS.
783         (Driver._check_for_driver_crash_or_unresponsiveness): Ditto.
784         (Driver._read_block): Ditto.
785         * Scripts/webkitpy/port/driver_unittest.py:
786         (DriverTest.test_check_for_driver_crash.FakeServerProcess.process_name): Update since Driver uses
787         process_name() instead of name().
788         * Scripts/webkitpy/port/server_process.py:
789         (ServerProcess._start): Use process_name() instead of name().
790         (ServerProcess.stop): Ditto.
791         (ServerProcess.name): Deleted.
792         * Scripts/webkitpy/port/simulator_process.py:
793         (SimulatorProcess.process_name): Check the provided bundle for the process name.
794
795 2017-06-06  Dean Johnson  <dean_johnson@apple.com>
796
797         test-webkitpy: stop forking unsafely from within a spawned process
798         https://bugs.webkit.org/show_bug.cgi?id=172774
799
800         Reviewed by Darin Adler.
801
802         * Scripts/webkitpy/common/net/buildbot/buildbot.py:
803         (Builder.__init__): We don't use mechanize.Browser() as part of testing, so only initialize it when
804         it's going to be used.
805         (Builder.force_build):
806
807 2017-06-06  Jonathan Bedard  <jbedard@apple.com>
808
809         webkitpy: Process crash-logs for iOS devices
810         https://bugs.webkit.org/show_bug.cgi?id=171976
811         <rdar://problem/32134551>
812
813         Reviewed by David Kilzer.
814
815         When running layout tests on an iOS device, crash logs should be processed.
816         Implement crash log searching and parsing for iOS devices.
817
818         * Scripts/webkitpy/common/system/crashlogs.py:
819         (CrashLogs): Moved process regular expression for Darwin to class variable.
820         (CrashLogs.__init__): Accept optional list of crash logs to ignore.
821         (CrashLogs.find_newest_log): Add iOS as a potential platform.
822         (CrashLogs.find_all_logs): Ditto.
823         (CrashLogs._parse_darwin_crash_log): Share code for parsing of Darwin crash logs.
824         Do not assume that a Darwin crash log starts with the process.
825         (CrashLogs._find_newest_log_darwin): Remove .app in process name for iOS, use
826         shared code for parsing Darwin crash logs.
827         (CrashLogs._find_newest_log_darwin.is_crash_log): Skip crash logs passed into this
828         object so that crash logs already on the system before testing are not parsed.
829         (CrashLogs._find_newest_log_win.is_crash_log): Ditto.
830         (CrashLogs._find_all_logs_darwin.is_crash_log): Ditto.
831         (CrashLogs._find_all_logs_darwin): Use shared code for parsing Darwin crash logs.
832         * Scripts/webkitpy/common/system/crashlogs_unittest.py:
833         (make_mock_crash_report_darwin): Crash logs may not have their process on the first line.
834         * Scripts/webkitpy/common/system/systemhost.py:
835         (SystemHost.symbolicate_crash_log_if_needed): The symbolicated crash log for most
836         systems is just the crashlog, use this behavior by default.
837         * Scripts/webkitpy/common/system/systemhost_mock.py:
838         (MockSystemHost.symbolicate_crash_log_if_needed): The symbolicated crash log for most
839         systems is just the crashlog, use this behavior by default.
840         * Scripts/webkitpy/port/apple.py:
841         (ApplePort): Add a dictionary mapping hosts to a list of crash logs to be skipped.
842         (ApplePort.setup_test_run): Set the list of crash logs to be skipped to the crash logs on
843         the system before testing begins
844         * Scripts/webkitpy/port/base.py:
845         (Port._get_crash_log): Pass optional target host when getting crash logs.
846         * Scripts/webkitpy/port/darwin.py:
847         (DarwinPort._look_for_all_crash_logs_in_log_dir): Pass list of crash logs to be skipped to
848         CrashLogs object.
849         (DarwinPort._get_crash_log): Pass optional target host when getting crash logs, pass list of crash
850         logs to be skipped to CrashLogs object.
851         * Scripts/webkitpy/port/darwin_testcase.py:
852         (DarwinTest.test_get_crash_log): Removed unused local function.
853         (DarwinTest.test_get_crash_log.fake_time_cb): Deleted.
854         * Scripts/webkitpy/port/device.py:
855         (Device.symbolicate_crash_log_if_needed): If the platform device has a function with this
856         name, call it. Otherwise, assume the default behavior and read the file at the provided path.
857         * Scripts/webkitpy/port/driver.py:
858         (Driver._get_crash_log): Pass optional target host when getting crash logs.
859         * Scripts/webkitpy/port/gtk.py:
860         (GtkPort._get_crash_log): Pass optional target host when getting crash logs.
861         * Scripts/webkitpy/port/ios.py: Ditto.
862         (IOSPort.setup_test_run): Each device is treated as an independent host. Set the list of crash logs
863         to be skipped for each host.
864         * Scripts/webkitpy/port/ios_device.py:
865         (IOSDevicePort.path_to_crash_logs): Consult apple_additions for the path to crash logs.
866         (IOSDevicePort._look_for_all_crash_logs_in_log_dir): Search every connected device for
867         crash logs and pass list of crash logs to ignore to each instance of CrashLogs.
868         (IOSDevicePort._get_crash_log): Search the specified target host for a crash log if a target
869         host is specified. Else, search all connected devices for the specified crash-log.
870         (IOSDevicePort.look_for_new_crash_logs): Deleted.
871         * Scripts/webkitpy/port/ios_device_unittest.py:
872         (IOSDeviceTest.test_crashlog_path): Without apple_additions, an exception should be raised.
873         (IOSDeviceTest.test_get_crash_log): Ditto.
874         * Scripts/webkitpy/port/simulator_process.py:
875         (SimulatorProcess.process_name): Check the provided bundle for the process name.
876         * Scripts/webkitpy/port/win.py:
877         (WinPort._get_crash_log): Pass optional target host when getting crash logs, pass list of crash
878         logs to be skipped to CrashLogs object.
879         * Scripts/webkitpy/port/wpe.py:
880         (WPEPort._get_crash_log): Pass optional target host when getting crash logs.
881
882 2017-06-06  David Kilzer  <ddkilzer@apple.com>
883
884         Move WTF_ATTRIBUTE_PRINTF() from implementation to declaration
885         <https://webkit.org/b/172804>
886
887         Reviewed by Darin Adler.
888
889         WTF_ATTRIBUTE_PRINTF() only works outside the current
890         compilation unit if it's on the declaration, not the
891         implementation, of a function or class method.
892
893         * DumpRenderTree/TestNetscapePlugIn/PluginObject.cpp:
894         * DumpRenderTree/TestNetscapePlugIn/PluginObject.h:
895         * DumpRenderTree/TestNetscapePlugIn/PluginTest.cpp:
896         * DumpRenderTree/TestNetscapePlugIn/PluginTest.h:
897         - Move WTF_ATTRIBUTE_PRINTF() macro to declaration.
898         * DumpRenderTree/TestNetscapePlugIn/main.cpp:
899         - Remove redundant CRASH() macro definition.  Use the one from
900           <wtf/Assertions.h> instead.
901
902 2017-06-06  Joseph Pecoraro  <pecoraro@apple.com>
903
904         Move Resource Timing / User Timing from experimental features into main preferences
905         https://bugs.webkit.org/show_bug.cgi?id=172950
906
907         Reviewed by Darin Adler.
908
909         * DumpRenderTree/mac/DumpRenderTree.mm:
910         (enableExperimentalFeatures):
911         (resetWebPreferencesToConsistentValues):
912         * DumpRenderTree/win/DumpRenderTree.cpp:
913         (enableExperimentalFeatures):
914         (resetWebPreferencesToConsistentValues):
915         * WebKitTestRunner/TestController.cpp:
916         (WTR::TestController::resetPreferencesToConsistentValues):
917         Move out no longer experimental features to the main list.
918
919 2017-06-06  Carlos Alberto Lopez Perez  <clopez@igalia.com>
920
921         [WPE] Add an install-dependencies script
922         https://bugs.webkit.org/show_bug.cgi?id=172948
923
924         Reviewed by Žan Doberšek.
925
926         It is based on the gtk/install-dependencies script.
927         Includes support for Debian based distrubutions, Fedora and Arch.
928         It has been tested on a minimal Debian 9 chroot.
929
930         * wpe/install-dependencies: Added.
931
932 2017-06-05  Wenson Hsieh  <wenson_hsieh@apple.com>
933
934         Refactor -[WebItemProviderPasteboard valuesForPasteboardType:inItemSet:] to check readable types
935         https://bugs.webkit.org/show_bug.cgi?id=172891
936         <rdar://problem/32204540>
937
938         Reviewed by Darin Adler.
939
940         Adds 2 new API tests to exercise data interaction of HTML data and an attributed string into a rich
941         contenteditable. See WebCore ChangeLog for more details.
942
943         * TestWebKitAPI/Tests/ios/DataInteractionTests.mm:
944         (TestWebKitAPI::TEST):
945
946 2017-06-05  Daniel Bates  <dabates@apple.com>
947
948         webkitpy: Abstract Executive class
949         https://bugs.webkit.org/show_bug.cgi?id=172928
950         <rdar://problem/32569531>
951
952         Reviewed by Ryosuke Niwa.
953
954         Adds an AbstractExecutive class and makes Executive extend AbstractExecutive.
955         This will make it straightforward to create additional derived classes that
956         adhere to the same interface, say for iOS on-device testing.
957
958         * Scripts/webkitpy/common/system/abstractexecutive.py: Added.
959         (AbstractExecutive):
960         (AbstractExecutive.run_and_throw_if_fail):
961         (AbstractExecutive.cpu_count):
962         (AbstractExecutive.interpreter_for_script):
963         (AbstractExecutive.shell_command_for_script):
964         (AbstractExecutive.kill_process):
965         (AbstractExecutive.check_running_pid):
966         (AbstractExecutive.running_pids):
967         (AbstractExecutive.wait_newest):
968         (AbstractExecutive.wait_limited):
969         (AbstractExecutive.interrupt):
970         (AbstractExecutive.default_error_handler):
971         (AbstractExecutive.ignore_error):
972         (AbstractExecutive._stringify_args):
973         (AbstractExecutive.command_for_printing):
974         (AbstractExecutive.run_command):
975         (AbstractExecutive.popen):
976         (AbstractExecutive.run_in_parallel):
977         * Scripts/webkitpy/common/system/executive.py:
978         (Executive):
979         (Executive.cpu_count):
980         (Executive.running_pids):
981         (Executive.kill_all):
982         (Executive._compute_stdin):
983         (Executive.interpreter_for_script): Deleted.
984         (Executive.shell_command_for_script): Deleted.
985         (Executive.wait_newest): Deleted.
986         (Executive.wait_limited): Deleted.
987         (Executive.default_error_handler): Deleted.
988         (Executive.ignore_error): Deleted.
989         (Executive.command_for_printing): Deleted.
990
991 2017-06-05  Jonathan Bedard  <jbedard@apple.com>
992
993         webkitpy: Add iOS to platform
994         https://bugs.webkit.org/show_bug.cgi?id=172931
995
996         Reviewed by Daniel Bates.
997
998         * Scripts/webkitpy/common/system/platforminfo.py:
999         PlatformInfo.__init__): Use platform_module.release() as the os_version for iOS device.
1000         (PlatformInfo.is_ios): Added.
1001         (PlatformInfo._determine_os_name): A platform name of 'ios' means that the os name is 'ios'.
1002         * Scripts/webkitpy/common/system/platforminfo_mock.py:
1003         (MockPlatformInfo.is_ios): Added.
1004
1005 2017-06-05  Carlos Alberto Lopez Perez  <clopez@igalia.com>
1006
1007         [WPE][JHBuild] Switch github repository from git:// to https://
1008         https://bugs.webkit.org/show_bug.cgi?id=172921
1009
1010         Reviewed by Alex Christensen.
1011
1012         * wpe/jhbuild.modules:
1013
1014 2017-06-05  Tim Horton  <timothy_horton@apple.com>
1015
1016         ASSERTION FAILED: m_currentScriptCallbackID in UIScriptContext::requestUIScriptCompletion(JSStringRef) running fast/events/ios/autocorrect-with-range-selection.html
1017         https://bugs.webkit.org/show_bug.cgi?id=172887
1018         <rdar://problem/32546061>
1019
1020         Reviewed by Sam Weinig.
1021
1022         * WebKitTestRunner/ios/UIScriptControllerIOS.mm:
1023         (WTR::UIScriptController::applyAutocorrection):
1024         applyAutocorrection can call its completion handler synchronously,
1025         which makes UIScriptController unhappy (see bug 172884).
1026
1027 2017-06-03  Jonathan Bedard  <jbedard@apple.com>
1028
1029         webkitpy: Add contextmanager to disable logging for a block
1030         https://bugs.webkit.org/show_bug.cgi?id=172876
1031
1032         Reviewed by Daniel Bates.
1033
1034         Add a context manager which will use an OutputCapture object to capture logging
1035         in a block and hold it in a variable.
1036
1037         * Scripts/webkitpy/common/system/outputcapture.py:
1038         (OutputCaptureScope):
1039         (OutputCaptureScope.__init__): Construct with OutputCapture object.
1040         (OutputCaptureScope.__enter__): Begin capturing output. 
1041         (OutputCaptureScope.__exit__): Restore output and save captured output to a variable.
1042         output and retain the resulting log.
1043         * Scripts/webkitpy/common/system/outputcapture_unittest.py:
1044         (OutputCaptureTest.test_output_capture_scope): Added.
1045
1046 2017-06-02  Zalan Bujtas  <zalan@apple.com>
1047
1048         Cleanup FrameView::autoSizeIfEnabled.
1049         https://bugs.webkit.org/show_bug.cgi?id=172889
1050         <rdar://problem/32550783>
1051
1052         Reviewed by Tim Horton.
1053
1054         * TestWebKitAPI/Tests/WebKit2Cocoa/AutoLayoutIntegration.mm:
1055         (-[AutoLayoutWKWebView load:withWidth:expectingContentSize:resettingWidth:]): progression.
1056         (TEST):
1057
1058 2017-06-02  Chris Dumez  <cdumez@apple.com>
1059
1060         ResourceLoadStatistics are not using unique paths during test runs
1061         https://bugs.webkit.org/show_bug.cgi?id=172861
1062         <rdar://problem/32442251>
1063
1064         Reviewed by Darin Adler.
1065
1066         Make sure WebKitTestRunner sets a temporary path for saving resource
1067         load statistics.
1068
1069         * WebKitTestRunner/TestController.cpp:
1070         (WTR::TestController::generateContextConfiguration):
1071
1072 2017-06-02  Brady Eidson  <beidson@apple.com>
1073
1074         Prevent scheme handlers from handling all built-in URL schemes.
1075         <rdar://problem/32404790> and https://bugs.webkit.org/show_bug.cgi?id=172869
1076
1077         Reviewed by Andy Estes.
1078
1079         * TestWebKitAPI/Tests/WebKit2Cocoa/WKURLSchemeHandler-1.mm:
1080
1081 2017-06-02  Stephan Szabo  <stephan.szabo@am.sony.com>
1082
1083         [JSCOnly] Build static jsc.exe on Windows
1084         https://bugs.webkit.org/show_bug.cgi?id=172833
1085
1086         Reviewed by Konstantin Tokarev.
1087
1088         * CMakeLists.txt:
1089         * Scripts/build-jsc:
1090
1091 2017-06-02  Zalan Bujtas  <zalan@apple.com>
1092
1093         Disable ViewportSizeForViewportUnits tests on iOS.
1094         https://bugs.webkit.org/show_bug.cgi?id=172872
1095
1096         Reviewed by Tim Horton.
1097
1098         * TestWebKitAPI/Tests/WebKit2/ViewportSizeForViewportUnits.mm:
1099
1100 2017-06-02  Zalan Bujtas  <zalan@apple.com>
1101
1102         Allow clients to override viewport size for CSS viewport units.
1103         https://bugs.webkit.org/show_bug.cgi?id=172838
1104         <rdar://problem/32523441>
1105
1106         Reviewed by Tim Horton.
1107
1108         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
1109         * TestWebKitAPI/Tests/WebKit2/ViewportSizeForViewportUnits.mm: Added.
1110         (TEST):
1111
1112 2017-06-02  Simon Fraser  <simon.fraser@apple.com>
1113
1114         Get <chrono> out of StdLibExtras.h
1115         https://bugs.webkit.org/show_bug.cgi?id=172744
1116
1117         Reviewed by Zalan Bujtas.
1118
1119         * TestWebKitAPI/Tests/WTF/WorkQueue.cpp:
1120
1121 2017-06-02  Zan Dobersek  <zdobersek@igalia.com>
1122
1123         [WPE] Enable SUBTLE_CRYPTO
1124         https://bugs.webkit.org/show_bug.cgi?id=172756
1125
1126         Reviewed by Michael Catanzaro.
1127
1128         * Scripts/webkitperl/FeatureList.pm: Set ENABLE_SUBTLE_CRYPTO to 1 for WPE.
1129         * wpe/jhbuild.modules: Add libgpg-error and libgcrypt dependencies.
1130         * wpe/patches/libgcrypt-use-only-dev-urandom-for-testing.patch: Added. Prevents
1131         exhausting entropy when running the crypto layout tests.
1132
1133 2017-06-01  Carlos Garcia Campos  <cgarcia@igalia.com>
1134
1135         [GTK] Bump GTK+ and its dependencies in jhbuild
1136         https://bugs.webkit.org/show_bug.cgi?id=171918
1137
1138         Reviewed by Carlos Alberto Lopez Perez.
1139
1140         * WebKitTestRunner/InjectedBundle/gtk/ActivateFontsGtk.cpp:
1141         (WTR::initializeGtkSettings):
1142         * gtk/jhbuild.modules:
1143         * gtk/patches/gtk+-configure-fix-detecting-CUPS-2.x.patch: Removed.
1144         * gtk/patches/librsvg-2.36.1-bump-up-config.guess-to-support-aarch64.patch: Removed.
1145
1146 2017-06-01  Carlos Garcia Campos  <cgarcia@igalia.com>
1147
1148         [GTK] Bump wayland and weston in jhbuild
1149         https://bugs.webkit.org/show_bug.cgi?id=171921
1150
1151         Reviewed by Carlos Alberto Lopez Perez.
1152
1153         * gtk/jhbuild.modules:
1154         * gtk/patches/weston-libweston-include-weston-egl-ext.h-in-drm-x11-and-wa.patch: Added.
1155
1156 2017-06-01  Andy Estes  <aestes@apple.com>
1157
1158         REGRESSION (r217626): ENABLE_APPLE_PAY_SESSION_V3 was disabled by mistake
1159         https://bugs.webkit.org/show_bug.cgi?id=172828
1160
1161         Reviewed by Beth Dakin.
1162
1163         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
1164
1165 2017-06-01  Jonathan Bedard  <jbedard@apple.com>
1166
1167         webkitpy: Remove unneeded simulator teardown
1168         https://bugs.webkit.org/show_bug.cgi?id=171891
1169
1170         Reviewed by Aakash Jain.
1171
1172         * Scripts/webkitpy/port/ios_simulator.py:
1173         (IOSSimulatorPort.clean_up_test_run): Remove FIFO deletion since TCP is used
1174         for communication between Python and WebKitTestRunner/DumpRenderTree.
1175
1176 2017-06-01  Keith Miller  <keith_miller@apple.com>
1177
1178         Undo rollout in r217638 with bug fix
1179         https://bugs.webkit.org/show_bug.cgi?id=172824
1180
1181         Unreviewed, reland patch with unused set_state code removed.
1182
1183         * TestWebKitAPI/Tests/WTF/ThreadMessages.cpp:
1184         (runThreadMessageTest):
1185         (TEST):
1186
1187 2017-06-01  Jonathan Bedard  <jbedard@apple.com>
1188
1189         webkitpy: Do not send 0 or -1 as a pid to kill_process
1190         https://bugs.webkit.org/show_bug.cgi?id=172818
1191
1192         Reviewed by Darin Adler.
1193
1194         Sending a signal to process 0 will result in all processes in the group receiving 
1195         the signal. Sending a signal to process -1 will result in all non-system processes
1196         receiving the signal. Both Executive.kill_process and Executive.check_running_pid
1197         should consider these cases
1198
1199         * Scripts/webkitpy/common/system/executive.py:
1200         (Executive.kill_process): Throw exception if pid is undefined, 0 or negative.
1201         (Executive.check_running_pid): An undefined pid, pid 0 or a negative pid will
1202         never be running, although os.kill may succeed.
1203         * Scripts/webkitpy/port/simulator_process.py:
1204         (SimulatorProcess.stop): Do not kill process if it is undefined.
1205
1206 2017-05-31  Alexey Proskuryakov  <ap@apple.com>
1207
1208         JSC EWS bot does not run on WTF only patches
1209         https://bugs.webkit.org/show_bug.cgi?id=172777
1210         rdar://problem/32495975
1211
1212         Reviewed by Aakash Jain.
1213
1214         * Scripts/webkitpy/tool/steps/checkpatchrelevance.py:
1215         (CheckPatchRelevance): Add a missing comma.
1216
1217 2017-05-31  Commit Queue  <commit-queue@webkit.org>
1218
1219         Unreviewed, rolling out r217611 and r217631.
1220         https://bugs.webkit.org/show_bug.cgi?id=172785
1221
1222         "caused wasm-hashset-many.html to become flaky." (Requested by
1223         keith_miller on #webkit).
1224
1225         Reverted changesets:
1226
1227         "Reland r216808, underlying lldb bug has been fixed."
1228         https://bugs.webkit.org/show_bug.cgi?id=172759
1229         http://trac.webkit.org/changeset/217611
1230
1231         "Use dispatch queues for mach exceptions"
1232         https://bugs.webkit.org/show_bug.cgi?id=172775
1233         http://trac.webkit.org/changeset/217631
1234
1235 2017-05-31  Ryan Haddad  <ryanhaddad@apple.com>
1236
1237         EWS bots should reboot themselves more frequently
1238         https://bugs.webkit.org/show_bug.cgi?id=172402
1239
1240         Reviewed by Alexey Proskuryakov.
1241
1242         Instead of rebooting once a day, EWS bots will reboot after running 10 iterations.
1243
1244         * EWSTools/start-queue-mac.sh: Remove the restriction placed on the time that the bot will perform a reboot.
1245
1246 2017-05-31  Ryan Haddad  <ryanhaddad@apple.com>
1247
1248         Reallocate hardware for iOS bots.
1249         https://bugs.webkit.org/show_bug.cgi?id=172657
1250
1251         Reviewed by Alexey Proskuryakov.
1252
1253         * BuildSlaveSupport/build.webkit.org-config/config.json:
1254
1255 2017-05-31  Andy Estes  <aestes@apple.com>
1256
1257         Rename ENABLE_APPLE_PAY_DELEGATE to ENABLE_APPLE_PAY_SESSION_V3 and bump the supported version number
1258         https://bugs.webkit.org/show_bug.cgi?id=172366
1259
1260         Reviewed by Daniel Bates.
1261
1262         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
1263
1264 2017-05-31  Jiewen Tan  <jiewen_tan@apple.com>
1265
1266         Unreviewed, add Jiewen Tan as a reviewer
1267
1268         * Scripts/webkitpy/common/config/contributors.json:
1269
1270 2017-05-31  Adrian Perez de Castro  <aperez@igalia.com>
1271
1272         [GTK] MiniBrowser's browser_window_get_or_create_web_view_for_automation never creates new windows
1273         https://bugs.webkit.org/show_bug.cgi?id=172770
1274
1275         Reviewed by Michael Catanzaro.
1276
1277         * MiniBrowser/gtk/BrowserWindow.c:
1278         (browser_window_get_or_create_web_view_for_automation): Removed stray semicolon
1279         which caused the body of the if-clause to be accidentally empty.
1280
1281 2017-05-31  Keith Miller  <keith_miller@apple.com>
1282
1283         Reland r216808, underlying lldb bug has been fixed.
1284         https://bugs.webkit.org/show_bug.cgi?id=172759
1285
1286         Unreviewed, relanding old patch. See: rdar://problem/31183352
1287
1288         * TestWebKitAPI/Tests/WTF/ThreadMessages.cpp:
1289         (runThreadMessageTest):
1290         (TEST):
1291
1292 2017-05-31  Matt Lewis  <jlewis3@apple.com>
1293
1294         Unreviewed, rolling out r217603.
1295
1296         This patch broke the internal builds.
1297
1298         Reverted changeset:
1299
1300         "Get <chrono> out of StdLibExtras.h"
1301         https://bugs.webkit.org/show_bug.cgi?id=172744
1302         http://trac.webkit.org/changeset/217603
1303
1304 2017-05-31  Brent Fulgham  <bfulgham@apple.com>
1305
1306         Make ResourceLoadStatistics testing more reliable
1307         https://bugs.webkit.org/show_bug.cgi?id=172730
1308         <rdar://problem/32028373>
1309
1310         Reviewed by Andy Estes.
1311
1312         When we tell the UIProcess (WebKitTestRunner) to notify the system about statistics update notifications,
1313         we also need to tell the WebProcess to do so, too, or else the test system doesn't get messages.
1314
1315         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
1316         (WTR::TestRunner::setStatisticsNotifyPagesWhenDataRecordsWereScanned):
1317
1318 2017-05-31  Carlos Alberto Lopez Perez  <clopez@igalia.com>
1319
1320         [GTK][WPE] run-javascriptcore-tests should use the jhbuild
1321         https://bugs.webkit.org/show_bug.cgi?id=172757
1322
1323         Reviewed by Xabier Rodriguez-Calvar.
1324
1325         When needed, add the jhbuild wrapper at the beginning of the array
1326         that will be invoked to execute the run-jsc-stress-test or testapi
1327         commands.
1328
1329         * Scripts/run-javascriptcore-tests:
1330         (runJSCStressTests):
1331         * Scripts/webkitdirs.pm:
1332         (shouldUseJhbuild):
1333
1334 2017-05-31  Simon Fraser  <simon.fraser@apple.com>
1335
1336         Get <chrono> out of StdLibExtras.h
1337         https://bugs.webkit.org/show_bug.cgi?id=172744
1338
1339         Reviewed by Saam Barati.
1340
1341         * TestWebKitAPI/Tests/WTF/WorkQueue.cpp:
1342
1343 2017-05-30  Tim Horton  <timothy_horton@apple.com>
1344
1345         Keyboard autocorrections do not apply with an active selection (but keyboard acts like they did)
1346         https://bugs.webkit.org/show_bug.cgi?id=172735
1347         <rdar://problem/32015977>
1348
1349         Reviewed by Enrica Casucci.
1350
1351         * DumpRenderTree/ios/UIScriptControllerIOS.mm:
1352         (WTR::UIScriptController::applyAutocorrection):
1353         * TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
1354         * TestRunnerShared/UIScriptContext/UIScriptController.cpp:
1355         (WTR::UIScriptController::applyAutocorrection):
1356         * TestRunnerShared/UIScriptContext/UIScriptController.h:
1357         * WebKitTestRunner/ios/UIScriptControllerIOS.mm:
1358         (WTR::UIScriptController::applyAutocorrection):
1359         Expose applyAutocorrection to UIScriptController. Use a WKTesting method
1360         because I don't know how to tap the button in the autocorrection bar from a test.
1361
1362 2017-05-30  Daniel Bates  <dabates@apple.com>
1363
1364         Add unit test for WebKit2 C SPI runBeforeUnloadConfirmPanel()
1365         https://bugs.webkit.org/show_bug.cgi?id=172671
1366
1367         Reviewed by Alex Christensen.
1368
1369         We should add a unit test to ensure we do not regress the WKPageUIClient runBeforeUnloadConfirmPanel() callback.
1370         For completeness, the callback runBeforeUnloadConfirmPanel() existed since inception of WKPageUIClient (WKPageUIClientV0).
1371
1372         * TestWebKitAPI/Tests/WebKit2/ModalAlertsSPI.cpp:
1373         (TestWebKitAPI::analyzeDialogArguments): Test the runBeforeUnloadConfirmPanel() callback last as we need
1374         to trigger a navigation to test it.
1375         (TestWebKitAPI::runBeforeUnloadConfirmPanel): Added.
1376         (TestWebKitAPI::createNewPage): Wire up the runBeforeUnloadConfirmPanel callback.
1377
1378 2017-05-30  Jonathan Bedard  <jbedard@apple.com>
1379
1380         webkitpy: Start servers before setting-up for testing
1381         https://bugs.webkit.org/show_bug.cgi?id=172176
1382         <rdar://problem/32225538>
1383
1384         Reviewed by Alexey Proskuryakov.
1385
1386         On-device testing requires that servers are started before ports set-up their
1387         test environments.
1388
1389         * Scripts/webkitpy/layout_tests/controllers/layout_test_runner.py:
1390         (LayoutTestRunner.__init__): Start servers when initializing LayoutTestRunner.
1391         Servers are unconditionally stopped on exit.
1392         (LayoutTestRunner.run_tests): Move the starting of servers to the initializer. The
1393         Manager now stops servers.
1394         (LayoutTestRunner.start_servers): Set flag to indicate servers are running.
1395         (LayoutTestRunner.stop_servers): Check flag, only shutdown servers if they are shutdown.
1396         * Scripts/webkitpy/layout_tests/controllers/manager.py:
1397         (Manager.__init__): Delay construction of the test runner until we can determine
1398         if servers need to be started.
1399         (Manager.run): Determine if servers need to be started and construct the test runner.
1400         Shut servers down when the test run is finished.
1401         (Manager._run_tests): Move the determination of servers to run into Manager.run.
1402         * Scripts/webkitpy/layout_tests/servers/web_platform_test_server.py:
1403         (is_wpt_server_running): Server is not running if no config is found.
1404         * Scripts/webkitpy/layout_tests/servers/websocket_server.py:
1405         (PyWebSocket.is_running): Check if this WebSocket server is running.
1406         * Scripts/webkitpy/port/base.py:
1407         (Port.__init__): Define secure WebSocket server.
1408         (Port.to.is_websocket_server_running): Check if WebSocket servers are defined.
1409
1410 2017-05-30  Daniel Bates  <dabates@apple.com>
1411
1412         [WK2] Add runBeforeUnloadConfirmPanel WKUIDelegate SPI; support onbeforeunload confirm panel in MiniBrowser
1413         https://bugs.webkit.org/show_bug.cgi?id=172603
1414         <rdar://problem/32471306>
1415
1416         Reviewed by Brady Eidson.
1417
1418         Implement the -_webView:runBeforeUnloadConfirmPanelWithMessage:initiatedByFrame:completionHandler: delegate
1419         method in MiniBrowser to show a confirm panel as to whether to allow the unloading of the page when
1420         unloading is initiated for a page that registered a onbeforeunload handler.
1421
1422         Modify TestWebKitAPI/Tests/WebKit2Cocoa/ModalAlerts.mm to test that the -_webView:runBeforeUnloadConfirmPanelWithMessage:initiatedByFrame:completionHandler:
1423         is called. Also fix style nit; pass YES instead of true to avoid implicit conversion from bool to BOOL
1424         when invoking the completion handler in -_webView:runJavaScriptAlertPanelWithMessage:initiatedByFrame:completionHandler:.
1425
1426         Until we fix <https://bugs.webkit.org/show_bug.cgi?id=172614> the unit test in TestWebKitAPI/Tests/WebKit2Cocoa/ModalAlerts.mm
1427         for -_webView:runBeforeUnloadConfirmPanelWithMessage:initiatedByFrame:completionHandler: is only run on Mac
1428         as we do not have the infrastructure to simulate a click/tap on iOS and a click/tap on the page that
1429         registered an onbeforeunload handler is required to show a confirm panel when the page will be unloaded.
1430
1431         * MiniBrowser/mac/WK2BrowserWindowController.m:
1432         (-[WK2BrowserWindowController _webView:runBeforeUnloadConfirmPanelWithMessage:initiatedByFrame:completionHandler:]):
1433         * TestWebKitAPI/Tests/WebKit2/modal-alerts-in-new-about-blank-window.html:
1434         * TestWebKitAPI/Tests/WebKit2Cocoa/ModalAlerts.mm:
1435         (sawDialog):
1436         (-[ModalAlertsUIDelegate webView:createWebViewWithConfiguration:forNavigationAction:windowFeatures:]):
1437         (-[ModalAlertsUIDelegate webView:runJavaScriptConfirmPanelWithMessage:initiatedByFrame:completionHandler:]):
1438         (-[ModalAlertsUIDelegate _webView:runBeforeUnloadConfirmPanelWithMessage:initiatedByFrame:completionHandler:]):
1439
1440 2017-05-30  Alex Christensen  <achristensen@webkit.org>
1441
1442         Update libwebrtc configuration
1443         https://bugs.webkit.org/show_bug.cgi?id=172727
1444
1445         Reviewed by Geoffrey Garen.
1446
1447         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
1448
1449 2017-05-30  Fujii Hironori  <Hironori.Fujii@sony.com>
1450
1451         [WinCairo] TestWebKitAPI: ASSERTION FAILED: m_eglDisplay == EGL_NO_DISPLAY
1452         https://bugs.webkit.org/show_bug.cgi?id=172702
1453
1454         Reviewed by Alex Christensen.
1455
1456         EGL PlatformDisplay needs to be shut down before existing a
1457         program on Windows.
1458
1459         * TestWebKitAPI/Tests/WebKit/win/ScaleWebView.cpp:
1460         (TestWebKitAPI::ScaleWebView::TearDown): Call shutDownWebKit().
1461         * TestWebKitAPI/Tests/WebKit/win/WebViewDestruction.cpp:
1462         (TestWebKitAPI::WebViewDestruction::TearDown): Ditto.
1463
1464 2017-05-30  Per Arne Vollan  <pvollan@apple.com>
1465
1466         [Win] fast/shadow-dom/fullscreen-in-slot-fullscreenElement.html is flaky.
1467         https://bugs.webkit.org/show_bug.cgi?id=172709
1468
1469         Reviewed by Brent Fulgham.
1470
1471         Exit fullscreen mode after a fullscreen test.
1472
1473         * DumpRenderTree/win/DumpRenderTree.cpp:
1474         (resetWebViewToConsistentStateBeforeTesting):
1475
1476 2017-05-30  Antti Koivisto  <antti@apple.com>
1477
1478         ASSERTION FAILED: !needsLayout() in com.apple.WebCore: WebCore::FrameView::paintContents in fast/events/tabindex-focus-blur-all.html on WK1
1479         https://bugs.webkit.org/show_bug.cgi?id=172713
1480
1481         Reviewed by Zalan Bujtas.
1482
1483         * DumpRenderTree/mac/ResourceLoadDelegate.mm:
1484         (-[ResourceLoadDelegate webView:plugInFailedWithError:dataSource:]):
1485
1486             Remove forced display from plugin resource load delegate. It is testing some long-obsolete
1487             Safari WK1 behavior. Forcing display from this resource load delegate will hit the assertion
1488             because on Mac WK1 it may get invoked from middle of a layout.
1489
1490             Painting code skips out after the assert so it doesn't indicate unsafe access of any sort.
1491
1492 2017-05-30  Carlos Alberto Lopez Perez  <clopez@igalia.com>
1493
1494         Add a WPE EWS queue
1495         https://bugs.webkit.org/show_bug.cgi?id=172693
1496
1497         Reviewed by Carlos Garcia Campos.
1498
1499         * QueueStatusServer/config/queues.py:
1500         * QueueStatusServer/model/queues.py: Capitalize the name of the
1501         port on the tooltip of the bubbles. Do the same for the GTK port.
1502         (Queue.display_name):
1503         * Scripts/webkitpy/common/config/ews.json: Update the watcher mail
1504         for the GTK+ EWS also. Set for both ports as watcher the alias
1505         bugs-noreply@webkitgtk.org that maintainers of both ports follow.
1506         * Scripts/webkitpy/common/config/ports.py:
1507         (DeprecatedPort.port):
1508         (WpePort):
1509         (WpePort.build_webkit_command):
1510         (WpePort.run_webkit_tests_command):
1511         * Scripts/webkitpy/common/config/ports_unittest.py:
1512         (DeprecatedPortTest):
1513         (DeprecatedPortTest.test_wpe_port):
1514         * Scripts/webkitpy/tool/commands/earlywarningsystem_unittest.py:
1515         (test_ews_name):
1516
1517 2017-05-29  Zan Dobersek  <zdobersek@igalia.com>
1518
1519         Unreviewed. Bumping the WPEBackend-mesa dependency version.
1520
1521         * wpe/jhbuild.modules: Use the latest version that uses proper GLib
1522         priorities for IPC communication.
1523
1524 2017-05-27  Yusuke Suzuki  <utatane.tea@gmail.com>
1525
1526         [JSC] Map and Set constructors should have fast path for cloning
1527         https://bugs.webkit.org/show_bug.cgi?id=172413
1528
1529         Reviewed by Saam Barati.
1530
1531         * TestWebKitAPI/Tests/WTF/MathExtras.cpp:
1532         (TestWebKitAPI::TEST):
1533
1534 2017-05-27  Zalan Bujtas  <zalan@apple.com>
1535
1536         enclosingIntRect returns a rect with -1 width/height when the input FloatRect overflows integer.
1537         https://bugs.webkit.org/show_bug.cgi?id=172676
1538
1539         Reviewed by Simon Fraser.
1540
1541         * TestWebKitAPI/Tests/WebCore/FloatRect.cpp:
1542         (TestWebKitAPI::TEST):
1543
1544 2017-05-26  Zalan Bujtas  <zalan@apple.com>
1545
1546         TestWebKitAPI: EnclosingIntRect and RoundedIntRect should use EXPECT_EQ.
1547         https://bugs.webkit.org/show_bug.cgi?id=172674
1548
1549         Reviewed by Simon Fraser.
1550
1551         * TestWebKitAPI/Tests/WebCore/FloatRect.cpp:
1552         (TestWebKitAPI::TEST):
1553
1554 2017-05-26  Wenson Hsieh  <wenson_hsieh@apple.com>
1555
1556         Add test resources back into TestWebKitAPI Copy Resources phase
1557
1558         Rubber-stamped by Beth Dakin.
1559
1560         Add two files back into the Copy Resources phase after they were unintentionally
1561         removed in r217447 and r217496.
1562
1563         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
1564
1565 2017-05-26  Beth Dakin  <bdakin@apple.com>
1566
1567         Media documents inside iframes should not get controls in the TouchBar unless the 
1568         video is playing
1569         https://bugs.webkit.org/show_bug.cgi?id=172620
1570         -and corresponding-
1571         rdar://problem/32165477
1572
1573         Reviewed by Jon Lee.
1574
1575         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
1576         * TestWebKitAPI/Tests/WebKit2Cocoa/VideoControlsManager.mm:
1577         (TestWebKitAPI::TEST):
1578         * TestWebKitAPI/Tests/WebKit2Cocoa/offscreen-iframe-of-media-document.html: Added.
1579
1580 2017-05-25  Joseph Pecoraro  <pecoraro@apple.com>
1581
1582         _WKUserStyleSheet and WKUserScript leak string data
1583         https://bugs.webkit.org/show_bug.cgi?id=172583
1584         <rdar://problem/32395209>
1585
1586         Reviewed by Sam Weinig.
1587
1588         * TestWebKitAPI/Tests/WebKit2Cocoa/UserContentController.mm:
1589         We should not have been adopting an autoreleased object.
1590
1591 2017-05-25  Myles C. Maxfield  <mmaxfield@apple.com>
1592
1593         [WK1] iframes in layer-backed NSViews are not cleared between successive draws
1594         https://bugs.webkit.org/show_bug.cgi?id=172554
1595         <rdar://problem/31247133>
1596
1597         Reviewed by Simon Fraser.
1598
1599         Previously, there was no way to make DumpRenderTree's views layer-backed. Unfortunately,
1600         simply setting [WebView setWantsLayer:] is insufficient; turning it on and then off again
1601         leaves some state around inside the NSWindow which isn't easily cleaned up. Instead,
1602         we should just tear down and rebuild the window whenever we need a layer-backed WebView.
1603         We can also use the "webkit-test-runner" header comment to trigger this new layer-backed
1604         codepath.
1605
1606         * DumpRenderTree/TestOptions.h:
1607         * DumpRenderTree/TestOptions.mm:
1608         (TestOptions::TestOptions):
1609         (TestOptions::webViewIsCompatibleWithOptions):
1610         * DumpRenderTree/mac/DumpRenderTree.mm:
1611         (shouldIgnoreWebCoreNodeLeaks):
1612         (allowedFontFamilySet):
1613         (-[DRTMockScroller rectForPart:]):
1614         (-[DRTMockScroller drawKnob]):
1615         (-[DRTMockScroller drawRect:]):
1616         (createWebViewAndOffscreenWindow):
1617         (initializeGlobalsFromCommandLineOptions):
1618         (prepareConsistentTestingEnvironment):
1619         (dumpRenderTree):
1620         (dumpAudio):
1621         (dumpHistoryItem):
1622         (dumpBackForwardListForWebView):
1623         (resetWebViewToConsistentStateBeforeTesting):
1624         (WebThreadLockAfterDelegateCallbacksHaveCompleted):
1625         (runTest):
1626
1627 2017-05-25  Sam Weinig  <sam@webkit.org>
1628
1629         [WebIDL] Use the term 'operation' more consistently
1630         https://bugs.webkit.org/show_bug.cgi?id=172601
1631
1632         Reviewed by Chris Dumez.
1633
1634         We were using the term 'operation', a WebIDL term for function-like
1635         constructs, inconsistently in the code generator. Now, when we use
1636         'operation' when referring to the IDL concept (usually the object the
1637         parser produces) and 'function' when referring to code being generated.
1638
1639         * DumpRenderTree/Bindings/CodeGeneratorDumpRenderTree.pm:
1640         * WebKitTestRunner/InjectedBundle/Bindings/CodeGeneratorTestRunner.pm:
1641
1642 2017-05-25  Jer Noble  <jer.noble@apple.com>
1643
1644         Unreviewed build fix after r217447; only run test where JSC's ObjC API is available.
1645
1646         * TestWebKitAPI/Tests/mac/MediaPlaybackSleepAssertion.mm:
1647
1648 2017-05-25  Jer Noble  <jer.noble@apple.com>
1649
1650         System sleeps while playing to wireless target, ending stream.
1651         https://bugs.webkit.org/show_bug.cgi?id=172541
1652
1653         Reviewed by Eric Carlson.
1654
1655         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
1656         * TestWebKitAPI/Tests/mac/MediaPlaybackSleepAssertion.html: Added.
1657         * TestWebKitAPI/Tests/mac/MediaPlaybackSleepAssertion.mm: Added.
1658         (-[MediaPlaybackSleepAssertionLoadDelegate webView:didCreateJavaScriptContext:forFrame:]):
1659         (-[MediaPlaybackSleepAssertionPolicyDelegate webView:decidePolicyForNavigationAction:request:frame:decisionListener:]):
1660         (TestWebKitAPI::simulateKeyDown):
1661         (TestWebKitAPI::hasAssertionType):
1662         (TestWebKitAPI::TEST):
1663
1664 2017-05-25  Commit Queue  <commit-queue@webkit.org>
1665
1666         Unreviewed, rolling out r217423 and r217424.
1667         https://bugs.webkit.org/show_bug.cgi?id=172607
1668
1669         These caused an api failure on all testers. (Requested by
1670         mlewis13 on #webkit).
1671
1672         Reverted changesets:
1673
1674         "REGRESSION (r216977): 4 leaks introduced in new
1675         WebKit2_WKHTTPCookieStoreWithoutProcessPool_Test"
1676         https://bugs.webkit.org/show_bug.cgi?id=172558
1677         http://trac.webkit.org/changeset/217423
1678
1679         "REGRESSION (r217423): Fix last-second typo in 'auto'"
1680         http://trac.webkit.org/changeset/217424
1681
1682 2017-05-25  Joanmarie Diggs  <jdiggs@igalia.com>
1683
1684         [ATK] Expose doc-footnote ARIA role with ATK_ROLE_FOOTNOTE
1685         https://bugs.webkit.org/show_bug.cgi?id=172355
1686
1687         Reviewed by Chris Fleizach.
1688
1689         Add map ATK_ROLE_FOOTNOTE to "AXFootnote" and bump jhbuild minimum
1690         versions of atk, at-spi2-core, and at-spi2-atk to 2.25.2 (the earliest
1691         releases which support the new platform footnote accessibility role.
1692
1693         * WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
1694         * gtk/jhbuild.modules:
1695
1696 2017-05-25  David Kilzer  <ddkilzer@apple.com>
1697
1698         REGRESSION (r217423): Fix last-second typo in 'auto'
1699
1700         * TestWebKitAPI/Tests/WebKit2Cocoa/WKHTTPCookieStore.mm:
1701         (WebKit2_WKHTTPCookieStoreWithoutProcessPool_Test): Fix typo.
1702
1703 2017-05-24  David Kilzer  <ddkilzer@apple.com>
1704
1705         REGRESSION (r216977): 4 leaks introduced in new WebKit2_WKHTTPCookieStoreWithoutProcessPool_Test
1706         <https://webkit.org/b/172558>
1707
1708         Reviewed by Sam Weinig.
1709
1710         * TestWebKitAPI/Tests/WebKit2Cocoa/WKHTTPCookieStore.mm:
1711         (WebKit2_WKHTTPCookieStoreWithoutProcessPool_Test): Fix the leaks.
1712
1713 2017-05-24  Don Olmstead  <don.olmstead@am.sony.com>
1714
1715         [CMake] Consolidate CMake code related to Cairo
1716         https://bugs.webkit.org/show_bug.cgi?id=172568
1717
1718         Reviewed by Alex Christensen.
1719
1720         * DumpRenderTree/config.h:
1721         * TestWebKitAPI/config.h:
1722
1723 2017-05-24  Wenson Hsieh  <wenson_hsieh@apple.com>
1724
1725         Plumb additional image metadata to item providers when beginning data interaction on an image
1726         https://bugs.webkit.org/show_bug.cgi?id=172536
1727         <rdar://problem/32371300>
1728
1729         Reviewed by Beth Dakin.
1730
1731         Tweak existing image data interaction tests to check for suggested name and estimated size on the generated
1732         source item providers.
1733
1734         * TestWebKitAPI/Tests/ios/DataInteractionTests.mm:
1735         (checkSuggestedNameAndEstimatedSize):
1736         (TestWebKitAPI::TEST):
1737
1738 2017-05-24  Per Arne Vollan  <pvollan@apple.com>
1739
1740         [Win] Create unique network storage session for each DRT.
1741         https://bugs.webkit.org/show_bug.cgi?id=172540
1742
1743         Reviewed by Brent Fulgham.
1744
1745         During layout testing, each DRT instance should have its own network storage session.
1746
1747         * DumpRenderTree/win/DumpRenderTree.cpp:
1748         (prepareConsistentTestingEnvironment):
1749
1750 2017-05-24  Wenson Hsieh  <wenson_hsieh@apple.com>
1751
1752         Respect image UTIs when writing to item providers when beginning data interaction on an image
1753         https://bugs.webkit.org/show_bug.cgi?id=172436
1754         <rdar://problem/31786569>
1755
1756         Reviewed by Beth Dakin.
1757
1758         Tweaks existing unit tests and adds a new test for image data interaction. See WebCore ChangeLog for more
1759         details.
1760
1761         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
1762         * TestWebKitAPI/Tests/WebKit2Cocoa/apple.gif: Added.
1763         * TestWebKitAPI/Tests/WebKit2Cocoa/gif-and-file-input.html: Added.
1764
1765         Create a new test page containing a GIF and a file input.
1766
1767         * TestWebKitAPI/Tests/ios/DataInteractionTests.mm:
1768         (checkTypeIdentifierIsRegisteredAtIndex):
1769         (TestWebKitAPI::TEST):
1770
1771 2017-05-23  Per Arne Vollan  <pvollan@apple.com>
1772
1773         [Win] Increase test timeout for slow tests.
1774         https://bugs.webkit.org/show_bug.cgi?id=172449
1775
1776         Reviewed by Alexey Proskuryakov.
1777
1778         Instead of using a fixed timeout of 30 seconds for all tests, we should use the
1779         timeout member in the TestRunner class.
1780
1781         * DumpRenderTree/win/TestRunnerWin.cpp:
1782         (TestRunner::setWaitToDump):
1783
1784 2017-05-15  Matt Rajca  <mrajca@apple.com>
1785
1786         Replace autoplay events that fire at navigation with a DidAutoplayMediaPastThreshold event.
1787         https://bugs.webkit.org/show_bug.cgi?id=172138
1788
1789         Reviewed by Alex Christensen.
1790
1791         Added API tests.
1792
1793         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
1794         * TestWebKitAPI/Tests/WebKit2/js-autoplay-audio.html: Added.
1795         * TestWebKitAPI/Tests/WebKit2Cocoa/WebsitePolicies.mm:
1796         (TEST):
1797         * TestWebKitAPI/Tests/WebKit2Cocoa/silence-long.m4a: Added.
1798
1799 2017-05-23  Simon Fraser  <simon.fraser@apple.com>
1800
1801         Stop consulting -viewsNeedDisplay when doing layer flushing in WebKit1
1802         https://bugs.webkit.org/show_bug.cgi?id=172522
1803         rdar://problem/31071812
1804
1805         Reviewed by Sam Weinig.
1806
1807         Remove NSWindowStyleMaskFullSizeContentView which is no longer referenced in code.
1808         We set this in the .xib file now.
1809
1810         * MiniBrowser/mac/MiniBrowser_Prefix.pch:
1811
1812 2017-05-22  Simon Fraser  <simon.fraser@apple.com>
1813
1814         Snapshotting via -renderInContext: should do synchronous image decodes
1815         https://bugs.webkit.org/show_bug.cgi?id=172485
1816         rdar://problem/32276146
1817
1818         Reviewed by Tim Horton.
1819
1820         New API test.
1821
1822         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
1823         * TestWebKitAPI/Tests/WebKit/ios/SnapshotViaRenderInContext.mm: Added.
1824         (-[RenderInContextWebViewDelegate webViewDidFinishLoad:]):
1825         (-[RenderInContextWebViewDelegate webView:didFailLoadWithError:]):
1826         (TestWebKitAPI::getPixelIndex):
1827         (TestWebKitAPI::TEST):
1828
1829 2017-05-23  Myles C. Maxfield  <mmaxfield@apple.com>
1830
1831         Remove dead ENABLE(FONT_LOAD_EVENTS) code
1832         https://bugs.webkit.org/show_bug.cgi?id=172517
1833
1834         Rubber-stamped by Simon Fraser.
1835
1836         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
1837
1838 2017-05-23  Wenson Hsieh  <wenson_hsieh@apple.com>
1839
1840         Multiple links should be inserted separately when performing data interaction
1841         https://bugs.webkit.org/show_bug.cgi?id=172489
1842         <rdar://problem/31510832>
1843
1844         Reviewed by Dan Bernstein.
1845
1846         Adds a new test that performs data interaction in a contenteditable with multiple items containing URLs.
1847
1848         * TestWebKitAPI/Tests/ios/DataInteractionTests.mm:
1849         (TestWebKitAPI::TEST):
1850
1851 2017-05-23  Tim Horton  <timothy_horton@apple.com>
1852
1853         REGRESSION: API test WebKit2.WKObject is failing
1854         https://bugs.webkit.org/show_bug.cgi?id=172497
1855         <rdar://problem/31694641>
1856
1857         Reviewed by Geoff Garen.
1858
1859         * TestWebKitAPI/Tests/WebKit2Cocoa/WKObject.mm:
1860         (TestWebKitAPI::TEST):
1861         Add a test that ensures that we pretend to at least be *some* kind of
1862         NSString, which my first fix would not have passed.
1863
1864 2017-05-23  youenn fablet  <youenn@apple.com>
1865
1866         There should be an easy way to run HTTP/WPT served tests on a browser
1867         https://bugs.webkit.org/show_bug.cgi?id=172068
1868
1869         Reviewed by Sam Weinig.
1870
1871         Adding a new script open-layout-test to open a layout-test in a
1872         browser and making sure it is served as done through run-webkit-tests.
1873         In case tests should be run using a server, detecting whether the
1874         server are running. If not, calling run-webkit-httpd to run the
1875         servers and open the URL in a browser.
1876         Otherwise, open directly the URL.
1877
1878         Adding an option in run-webkit-httpd to open an URL after having
1879         started the servers.
1880
1881         Adding the --no-http-servers option in run-webkit-tests to not start any HTTP server.
1882         This allows running run-webkit-httpd once and not having to restart
1883         servers everytime a test should be served.
1884
1885         Moving most of run-webkit-httpd logic in its own python file to reuse
1886         it in open-layout-test script.
1887
1888         Adding routines to check whether HTTP and WPT servers are running.
1889
1890         * Scripts/open-layout-test: Added.
1891         (parse_args):
1892         (main):
1893         * Scripts/run-webkit-httpd:
1894         (main):
1895         * Scripts/webkitpy/layout_tests/controllers/layout_test_finder.py:
1896         (LayoutTestFinder.find_tests):
1897         * Scripts/webkitpy/layout_tests/controllers/layout_test_runner.py:
1898         (LayoutTestRunner.run_tests):
1899         * Scripts/webkitpy/layout_tests/run_webkit_tests.py:
1900         (parse_args):
1901         * Scripts/webkitpy/layout_tests/servers/http_server_base.py:
1902         (HttpServerBase._is_server_running_on_all_ports):
1903         (HttpServerBase):
1904         (HttpServerBase._is_running_on_port):
1905         (HttpServerBase._check_that_all_ports_are_available):
1906         (is_http_server_running):
1907         * Scripts/webkitpy/layout_tests/servers/run_webkit_httpd.py: Copied from Tools/Scripts/run-webkit-httpd.
1908         (parse_args):
1909         (main):
1910         (run_server):
1911         * Scripts/webkitpy/layout_tests/servers/web_platform_test_server.py:
1912         (is_wpt_server_running):
1913         * Scripts/webkitpy/port/base.py:
1914         (Port.to.is_http_server_running):
1915         (Port.to):
1916         (Port.to.is_wpt_server_running):
1917         (Port.to.start_web_platform_test_server):
1918         * Scripts/webkitpy/port/driver.py:
1919         (DriverProxy.is_web_platform_test):
1920         (DriverProxy):
1921         (DriverProxy.is_webkit_specific_web_platform_test):
1922
1923 2017-05-23  Emilio Cobos Álvarez  <ecobos@igalia.com>
1924
1925         Add a RuntimeEnabledFeature for display: contents, defaulted to false.
1926         https://bugs.webkit.org/show_bug.cgi?id=171984
1927
1928         Reviewed by Antti Koivisto.
1929
1930         * DumpRenderTree/mac/DumpRenderTree.mm:
1931         (enableExperimentalFeatures):
1932         * WebKitTestRunner/TestController.cpp:
1933         (WTR::TestController::resetPreferencesToConsistentValues):
1934
1935 2017-05-20  Alex Christensen  <achristensen@webkit.org>
1936
1937         REGRESSION(r215686): O(n^2) algorithm in CachedRawResource::addDataBuffer
1938         https://bugs.webkit.org/show_bug.cgi?id=172406
1939         <rdar://32109532>
1940
1941         Reviewed by Brady Eidson.
1942
1943         * TestWebKitAPI/Tests/WebCore/SharedBuffer.cpp:
1944         (TestWebKitAPI::checkBuffer):
1945         (TestWebKitAPI::TEST_F):
1946
1947 2017-05-22  Jason Marcell  <jmarcell@apple.com>
1948
1949         Do not enter Subversion-specific logic when parsing Git-based Trac data.
1950         https://bugs.webkit.org/show_bug.cgi?id=172433
1951         <rdar://problem/32234188>
1952
1953         Reviewed by Alexey Proskuryakov.
1954
1955         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/Trac.js:
1956         (Trac.prototype._convertCommitInfoElementToObject):
1957
1958 2017-05-22  Tim Horton  <timothy_horton@apple.com>
1959
1960         ExplicitSnapshotsChangeUponNavigation API test often fails
1961         https://bugs.webkit.org/show_bug.cgi?id=172475
1962         <rdar://problem/31688322>
1963
1964         Reviewed by Simon Fraser.
1965
1966         * TestWebKitAPI/cocoa/TestWKWebView.mm:
1967         (-[TestWKWebView _setUpTestWindow:]):
1968         Make TestWKWebView's window layer-backed. This is now the default,
1969         and it's also easy to accidentally write a test that depends on it
1970         (for example, ExplicitSnapshotsChangeUponNavigation adds an NSBox,
1971         which becomes layer backed, just like the WKWebView, but with no
1972         common layer-backed ancestor).
1973
1974 2017-05-22  youenn fablet  <youenn@apple.com>
1975
1976         Resync web-platform-tests up to 8df7c9c215678328212f232ce0b5270c505a8563
1977         https://bugs.webkit.org/show_bug.cgi?id=172426
1978
1979         Reviewed by Chris Dumez.
1980
1981         * Scripts/webkitpy/w3c/test_importer.py:
1982         (TestImporter.remove_deleted_files): Outputting warning when trying to delete a file that no longer exists.
1983
1984 2017-05-22  Konstantin Tokarev  <annulen@yandex.ru>
1985
1986         Unreviewed, change my status to reviewer and fill "expertise" field
1987
1988         * Scripts/webkitpy/common/config/contributors.json:
1989
1990 2017-05-22  Tomas Popela  <tpopela@redhat.com>
1991
1992         Remove some of the EFL port leftovers
1993         https://bugs.webkit.org/show_bug.cgi?id=172440
1994
1995         Reviewed by Carlos Garcia Campos.
1996
1997         * BuildSlaveSupport/built-product-archive:
1998         (archiveBuiltProduct):
1999         (extractBuiltProduct):
2000         * BuildSlaveSupport/test-result-archive:
2001         (archiveTestResults):
2002         * ImageDiff/PlatformEfl.cmake: Removed.
2003         * Scripts/run-efl-tests: Removed.
2004         * Scripts/webkit-build-directory:
2005         * Scripts/webkitpy/common/config/contributionareas.py:
2006         * Scripts/webkitpy/common/config/watchlist:
2007         * Scripts/webkitpy/layout_tests/run_webkit_tests.py:
2008         (parse_args):
2009         (_set_up_derived_options):
2010         * Scripts/webkitpy/performance_tests/perftestsrunner.py:
2011         (PerfTestsRunner.__init__):
2012         * Scripts/webkitpy/style/checker.py:
2013         * Scripts/webkitpy/style/checker_unittest.py:
2014         (GlobalVariablesTest.test_path_rules_specifier):
2015         * gtk/manifest.txt.in:
2016         * jhbuild/jhbuild-wrapper:
2017
2018 2017-05-22  Carlos Garcia Campos  <cgarcia@igalia.com>
2019
2020         Unreviewed. Do not include WPE files in GTK+ tarballs.
2021
2022         * gtk/manifest.txt.in:
2023
2024 2017-05-22  Carlos Garcia Campos  <cgarcia@igalia.com>
2025
2026         [GTK] Add webkit_context_menu_item_new_from_gaction
2027         https://bugs.webkit.org/show_bug.cgi?id=159631
2028
2029         Reviewed by Michael Catanzaro.
2030
2031         Update context menu tests to check the new GAction API.
2032
2033         * TestWebKitAPI/Tests/WebKit2Gtk/TestContextMenu.cpp:
2034         (testContextMenuPopulateMenu):
2035
2036 2017-05-21  Michael Catanzaro  <mcatanzaro@igalia.com>
2037
2038         [GTK] Remove Firefox user agent quirk for Google domains
2039         https://bugs.webkit.org/show_bug.cgi?id=171941
2040
2041         Reviewed by Carlos Garcia Campos.
2042
2043         * TestWebKitAPI/Tests/WebCore/UserAgentQuirks.cpp:
2044         (TestWebKitAPI::TEST):
2045         (TestWebKitAPI::assertUserAgentForURLHasFirefoxBrowserQuirk): Deleted.
2046
2047 2017-05-20  Ting-Wei Lan  <lantw44@gmail.com>
2048
2049         [GTK] gtkdoc-fixxref needs --module argument to work
2050         https://bugs.webkit.org/show_bug.cgi?id=172415
2051
2052         Reviewed by Michael Catanzaro.
2053
2054         * gtk/gtkdoc.py:
2055         (GTKDoc._run_gtkdoc_fixxref):
2056
2057 2017-05-20  Alexey Proskuryakov  <ap@apple.com>
2058
2059         make-new-script-test should create tests that use js-test.js, not js-test-pre.js
2060         https://bugs.webkit.org/show_bug.cgi?id=172416
2061
2062         Reviewed by Daniel Bates.
2063
2064         * Scripts/make-new-script-test:
2065
2066 2017-05-19  Fujii Hironori  <Hironori.Fujii@sony.com>
2067
2068         [Win] error LNK2005: WebCore::JSNode::checkSubClassPatchpoint() already defined in WebKit.lib
2069         https://bugs.webkit.org/show_bug.cgi?id=172267
2070
2071         Reviewed by Per Arne Vollan.
2072
2073         TestWebCoreLib and TestWebKitLib have linked both WebCore and WebKit.
2074         TestWebCoreLib should link only with WebCore. And, TestWebKitLib
2075         should link only with WebKit.
2076
2077         Unfortunately, there is a layer violation at the moment.
2078         WebCore::Image::loadPlatformResource needs loadResourceIntoBuffer
2079         in WebKit. This change contains a stub of loadResourceIntoBuffer
2080         in TestWebCoreLib for the workaround.
2081
2082         * TestWebKitAPI/PlatformWin.cmake: Do not link WebKit to
2083         TestWebCoreLib. Do not link WebCore to TestWebKitLib.
2084         * TestWebKitAPI/win/TestWebCoreStubs.cpp: Added.
2085         (loadResourceIntoBuffer): Added a stub.
2086
2087 2017-05-19  Simon Fraser  <simon.fraser@apple.com>
2088
2089         Fix dump-class-layout to handle different file architectures
2090         https://bugs.webkit.org/show_bug.cgi?id=172392
2091
2092         Reviewed by Zalan Bujtas.
2093
2094         Instead of using lldb.LLDB_ARCH_DEFAULT by default, run 'file' on the binary
2095         and use the first architecture reported. Also add a "--architecture" argument
2096         to allow the user to specify an architecture.
2097
2098         * Scripts/dump-class-layout:
2099         (import_lldb):
2100         (verify_type_recursive):
2101         (get_first_file_architecture):
2102         (dump_class):
2103         (main):
2104         (find_build_directory): Deleted.
2105
2106 2017-05-19  Jonathan Bedard  <jbedard@apple.com>
2107
2108         Unreviewed infrastructure fix.
2109
2110         * Scripts/webkitpy/port/ios_simulator.py:
2111         (IOSSimulatorPort._create_devices): Ignore failure to open Simulator.app.
2112
2113 2017-05-19  Jonathan Bedard  <jbedard@apple.com>
2114
2115         webkitpy: Use simctl boot to run multiple simulators at once
2116         https://bugs.webkit.org/show_bug.cgi?id=172374
2117
2118         Reviewed by Alexey Proskuryakov.
2119
2120         * Scripts/webkitpy/common/system/platforminfo.py:
2121         (PlatformInfo.xcode_version): Return the current version of Xcode.
2122         * Scripts/webkitpy/common/system/platforminfo_mock.py:
2123         (MockPlatformInfo.xcode_version): Return version 8.0 for testing.
2124         * Scripts/webkitpy/port/ios_simulator.py:
2125         (IOSSimulatorPort.use_multiple_simulator_apps): Return true if we need to
2126         run multiple Simulator.app instances.
2127         (IOSSimulatorPort._create_simulators): Only copy the simulator app for older
2128         versions of Xcode.
2129         (IOSSimulatorPort._create_devices): Use 'simctl boot' directly unless using
2130         an older version of Xcode.
2131
2132 2017-05-19  Wenson Hsieh  <wenson_hsieh@apple.com>
2133
2134         Unreviewed, fix the build on the latest internal SDK.
2135
2136         * TestWebKitAPI/Tests/ios/DataInteractionTests.mm:
2137         (TestWebKitAPI::TEST):
2138
2139 2017-05-19  Filip Pizlo  <fpizlo@apple.com>
2140
2141         arrayProtoPrivateFuncConcatMemcpy needs to be down with firstArray being undecided
2142         https://bugs.webkit.org/show_bug.cgi?id=172369
2143
2144         Reviewed by Mark Lam.
2145         
2146         Because I wrote a test that relies on the NoCJIT config scribbling free cells, I thought it
2147         would be a good idea to write this down.
2148
2149         * Scripts/run-jsc-stress-tests:
2150
2151 2017-05-19  Jonathan Bedard  <jbedard@apple.com>
2152
2153         webkitpy: Layout tests which have no output will succeed
2154         https://bugs.webkit.org/show_bug.cgi?id=172322
2155         <rdar://problem/32258350>
2156
2157         Reviewed by David Kilzer.
2158
2159         * Scripts/webkitpy/layout_tests/controllers/single_test_runner.py:
2160         (SingleTestRunner._compare_text): Add FailreNotTested to failures if test has no output.
2161         * Scripts/webkitpy/layout_tests/models/test_failures.py:
2162         (determine_result_type): FailureNotTested means that the test could not be loaded. This
2163         is classified as a MISSING failure.
2164         (FailureNotTested): Added.
2165         (FailureNotTested.message):
2166
2167 2017-05-19  Yusuke Suzuki  <utatane.tea@gmail.com>
2168
2169         Add SixSpeed benchmark to PerformanceTests
2170         https://bugs.webkit.org/show_bug.cgi?id=172326
2171
2172         Reviewed by Sam Weinig.
2173
2174         * Scripts/run-jsc-benchmarks:
2175
2176 2017-05-19  Wenson Hsieh  <wenson_hsieh@apple.com>
2177
2178         [WK1] MiniBrowser should navigate when handling a dropped URL
2179         https://bugs.webkit.org/show_bug.cgi?id=172350
2180
2181         Reviewed by Tim Horton.
2182
2183         Allow all drop actions, including URL navigation, for WebKit1 MiniBrowser.
2184
2185         * MiniBrowser/mac/WK1BrowserWindowController.m:
2186         (-[WK1BrowserWindowController webView:dragDestinationActionMaskForDraggingInfo:]):
2187
2188 2017-05-18  Ryosuke Niwa  <rniwa@webkit.org>
2189
2190         REGRESSION (r216694 - 216712): Performance test Speedometer/Full.html is failing
2191         https://bugs.webkit.org/show_bug.cgi?id=172077
2192
2193         Reviewed by Chris Dumez.
2194
2195         Fixed perftest.py by updating the lines to ignore in Speedometer.
2196
2197         Also start report the results as "Speedometer" instead of "DoYouEvenBench/Full.html" to perf.webkit.org.
2198
2199         * Scripts/webkitpy/performance_tests/perftest.py:
2200         (PerfTest._lines_to_ignore_in_parser_result): Updated for Speedometer 2.0.
2201         * Scripts/webkitpy/performance_tests/perftestsrunner.py:
2202         (PerfTestsRunner._collect_tests): Use "Speedometer" instead of "Speedometer/index.html" as the test name.
2203         (_generate_results_dict): Removed the workaround to keep reporting Speedometer as DoYouEvenBench.
2204         * Scripts/webkitpy/performance_tests/perftestsrunner_unittest.py:
2205         (MainTest.test_collect_tests_with_index_html_and_resources): Added.
2206
2207 2017-05-18  Andy Estes  <aestes@apple.com>
2208
2209         ENABLE(APPLE_PAY_DELEGATE) should be NO on macOS Sierra and earlier
2210         https://bugs.webkit.org/show_bug.cgi?id=172305
2211
2212         Reviewed by Anders Carlsson.
2213
2214         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
2215
2216 2017-05-18  Wenson Hsieh  <wenson_hsieh@apple.com>
2217
2218         Selection around attachment elements should not persist when beginning a drag
2219         https://bugs.webkit.org/show_bug.cgi?id=172319
2220         <rdar://problem/32283008>
2221
2222         Reviewed by Tim Horton.
2223
2224         Tests that temporary selection around an attachment does not persist longer than it needs to.
2225
2226         * TestWebKitAPI/Tests/ios/DataInteractionTests.mm:
2227         (TestWebKitAPI::TEST):
2228
2229 2017-05-18  John Wilander  <wilander@apple.com>
2230
2231         Resource Load Statistics: Grandfather domains for existing data records
2232         https://bugs.webkit.org/show_bug.cgi?id=172155
2233         <rdar://problem/24913532>
2234
2235         Reviewed by Alex Christensen.
2236
2237         Adds test infrastructure needed for the added functionality.
2238
2239         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
2240         * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
2241         (WTR::InjectedBundle::didReceiveMessageToPage):
2242         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
2243         (WTR::TestRunner::setStatisticsGrandfathered):
2244         (WTR::TestRunner::isStatisticsGrandfathered):
2245         (WTR::TestRunner::installStatisticsDidScanDataRecordsCallback):
2246         (WTR::TestRunner::statisticsDidScanDataRecordsCallback):
2247         (WTR::TestRunner::setStatisticsGrandfatheringTime):
2248         * WebKitTestRunner/InjectedBundle/TestRunner.h:
2249         * WebKitTestRunner/TestController.cpp:
2250         (WTR::TestController::setStatisticsGrandfathered):
2251         (WTR::TestController::isStatisticsGrandfathered):
2252         (WTR::TestController::setStatisticsGrandfatheringTime):
2253         * WebKitTestRunner/TestController.h:
2254         * WebKitTestRunner/TestInvocation.cpp:
2255         (WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):
2256
2257 2017-05-18  Saam Barati  <sbarati@apple.com>
2258
2259         WebAssembly: perform stack checks
2260         https://bugs.webkit.org/show_bug.cgi?id=165546
2261         <rdar://problem/29760307>
2262
2263         Reviewed by Filip Pizlo.
2264
2265         Add some new testing modes for using and not using fast TLS wasm contexts.
2266
2267         * Scripts/run-jsc-stress-tests:
2268
2269 2017-05-18  Daniel Bates  <dabates@apple.com>
2270
2271         REGRESSION (r209608): Cross-origin plugin document opened in child window blocked by parent
2272         window CSP when object-src 'none' is set
2273         https://bugs.webkit.org/show_bug.cgi?id=172038
2274         <rdar://problem/32258262>
2275
2276         Reviewed by Andy Estes.
2277
2278         Teach the test Netscape plugin to look for a URL that contains plugin-document-alert-and-notify-done.pl.
2279         When it sees this URL it will show a JavaScript alert and call testRunner.notifyDone().
2280
2281         * DumpRenderTree/TestNetscapePlugIn/main.cpp:
2282         (NPP_New):
2283
2284 2017-05-18  Per Arne Vollan  <pvollan@apple.com>
2285
2286         [Win] Many layout tests are failing.
2287         https://bugs.webkit.org/show_bug.cgi?id=172286
2288
2289         Reviewed by Brent Fulgham.
2290
2291         Add a FIXME comment about unimplemented functions, instead of writing this to the test result file.
2292  
2293         * DumpRenderTree/win/TestRunnerWin.cpp:
2294         (TestRunner::grantWebNotificationPermission):
2295         (TestRunner::denyWebNotificationPermission):
2296         (TestRunner::removeAllWebNotificationPermissions):
2297         (TestRunner::simulateWebNotificationClick):
2298
2299 2017-05-18  Don Olmstead  <don.olmstead@am.sony.com>
2300
2301         [Win] Remove usage of _snprintf
2302         https://bugs.webkit.org/show_bug.cgi?id=172251
2303
2304         Reviewed by Per Arne Vollan.
2305
2306         * DumpRenderTree/TestNetscapePlugIn/PluginTest.h:
2307         * MiniBrowser/win/PageLoadTestClient.cpp:
2308         (PageLoadTestClient::dumpRunStatistics):
2309
2310 2017-05-17  Ryan Haddad  <ryanhaddad@apple.com>
2311
2312         Unreviewed, rolling out r217014.
2313
2314         This change caused mac-wk2 LayoutTests to exit early due to
2315         crashes.
2316
2317         Reverted changeset:
2318
2319         "Resource Load Statistics: Grandfather domains for existing
2320         data records"
2321         https://bugs.webkit.org/show_bug.cgi?id=172155
2322         http://trac.webkit.org/changeset/217014
2323
2324 2017-05-17  John Wilander  <wilander@apple.com>
2325
2326         Resource Load Statistics: Grandfather domains for existing data records
2327         https://bugs.webkit.org/show_bug.cgi?id=172155
2328         <rdar://problem/24913532>
2329
2330         Reviewed by Alex Christensen.
2331
2332         Adds test infrastructure needed for the added functionality.
2333
2334         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
2335         * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
2336         (WTR::InjectedBundle::didReceiveMessageToPage):
2337         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
2338         (WTR::TestRunner::setStatisticsGrandfathered):
2339         (WTR::TestRunner::isStatisticsGrandfathered):
2340         (WTR::TestRunner::installStatisticsDidScanDataRecordsCallback):
2341         (WTR::TestRunner::statisticsDidScanDataRecordsCallback):
2342         (WTR::TestRunner::setStatisticsGrandfatheringTime):
2343         * WebKitTestRunner/InjectedBundle/TestRunner.h:
2344         * WebKitTestRunner/TestController.cpp:
2345         (WTR::TestController::setStatisticsGrandfathered):
2346         (WTR::TestController::isStatisticsGrandfathered):
2347         (WTR::TestController::setStatisticsGrandfatheringTime):
2348         * WebKitTestRunner/TestController.h:
2349         * WebKitTestRunner/TestInvocation.cpp:
2350         (WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):
2351
2352 2017-05-17  Alex Christensen  <achristensen@webkit.org>
2353
2354         Fix ios-simulator API test after r216977
2355         https://bugs.webkit.org/show_bug.cgi?id=171987
2356
2357         * TestWebKitAPI/Tests/WebKit2Cocoa/WKHTTPCookieStore.mm:
2358         (TEST):
2359         <rdar://problem/32260156> covers the investigation of this, but fixing it is 
2360         not as urgent as having the rest of this working. Notably the ephemeral part of the
2361         test works, so something is just wrong with the persistent part.
2362
2363 2017-05-17  Ryan Haddad  <ryanhaddad@apple.com>
2364
2365         Unreviewed, rolling out r216955.
2366
2367         This change caused strange behavior with web-platform-tests
2368         locally and on EWS.
2369
2370         Reverted changeset:
2371
2372         "webkitpy: Start servers before setting-up for testing"
2373         https://bugs.webkit.org/show_bug.cgi?id=172176
2374         http://trac.webkit.org/changeset/216955
2375
2376 2017-05-17  Wenson Hsieh  <wenson_hsieh@apple.com>
2377
2378         A URL type is vended for a non-URL plain text string when starting data interaction
2379         https://bugs.webkit.org/show_bug.cgi?id=172228
2380         <rdar://problem/32166729>
2381
2382         Reviewed by Andy Estes.
2383
2384         Adds two new data interaction tests, SinglePlainTextWordTypeIdentifiers and SinglePlainTextURLTypeIdentifiers,
2385         to verify that a URL UTI is not vended when beginning a data interaction on a single word, but that a URL is
2386         still vended when beginning data interaction on something that resembles a link.
2387
2388         * TestWebKitAPI/Tests/ios/DataInteractionTests.mm:
2389
2390 2017-05-17  David Kilzer  <ddkilzer@apple.com>
2391
2392         BlobDataFileReference::generateReplacementFile() should use mkstemp()
2393         <https://webkit.org/b/172192>
2394
2395         Reviewed by Brent Fulgham.
2396
2397         * Scripts/webkitpy/style/checkers/cpp.py:
2398         (check_language): Add check for mktemp.
2399         (CppChecker): Add 'security/temp_file' category.
2400         * Scripts/webkitpy/style/checkers/cpp_unittest.py:
2401         (CppStyleTest.test_insecure_temp_file): Add test.
2402
2403 2017-05-17  Devin Rousso  <drousso@apple.com>
2404
2405         Unreviewed, change my email.
2406
2407         * Scripts/webkitpy/common/config/contributors.json:
2408
2409 2017-05-17  Matt Lewis  <jlewis3@apple.com>
2410
2411         Unreviewed, rolling out r216974.
2412
2413         Revision caused consistent timeouts on all platforms.
2414
2415         Reverted changeset:
2416
2417         "Add a RuntimeEnabledFeature for display: contents, defaulted
2418         to false."
2419         https://bugs.webkit.org/show_bug.cgi?id=171984
2420         http://trac.webkit.org/changeset/216974
2421
2422 2017-05-17  Alex Christensen  <achristensen@webkit.org>
2423
2424         Interacting with WKHTTPCookieStores before creating WKWebViews and WKProcessPools should affect cookies used
2425         https://bugs.webkit.org/show_bug.cgi?id=171987
2426
2427         Reviewed by Brady Eidson.
2428
2429         * TestWebKitAPI/Tests/WebKit2Cocoa/WKHTTPCookieStore.mm:
2430         (-[CookieUIDelegate webView:runJavaScriptAlertPanelWithMessage:initiatedByFrame:completionHandler:]):
2431         (TEST):
2432
2433 2017-05-17  Emilio Cobos Álvarez  <ecobos@igalia.com>
2434
2435         Add a RuntimeEnabledFeature for display: contents, defaulted to false.
2436         https://bugs.webkit.org/show_bug.cgi?id=171984
2437
2438         Reviewed by Antti Koivisto.
2439
2440         * DumpRenderTree/mac/DumpRenderTree.mm:
2441         (enableExperimentalFeatures):
2442         * WebKitTestRunner/TestController.cpp:
2443         (WTR::TestController::resetPreferencesToConsistentValues):
2444
2445 2017-05-16  Timothy Horton  <timothy_horton@apple.com>
2446
2447         Fix the build
2448
2449         * TestWebKitAPI/Tests/mac/PageVisibilityStateWithWindowChanges.mm:
2450         (TestWebKitAPI::PageVisibilityStateWithWindowChanges::runTest):
2451
2452 2017-05-16  Tim Horton  <timothy_horton@apple.com>
2453
2454         PageVisibilityStateWithWindowChanges tests sometimes time out
2455         https://bugs.webkit.org/show_bug.cgi?id=172202
2456         <rdar://problem/29653266>
2457
2458         Reviewed by Dean Jackson.
2459
2460         * TestWebKitAPI/Tests/mac/PageVisibilityStateWithWindowChanges.mm:
2461         (TestWebKitAPI::PageVisibilityStateWithWindowChanges::runTest):
2462         Make sure the window is miniaturizable, otherwise, in some cases, miniaturize: will not work.
2463
2464 2017-05-16  Jonathan Bedard  <jbedard@apple.com>
2465
2466         webkitpy: Start servers before setting-up for testing
2467         https://bugs.webkit.org/show_bug.cgi?id=172176
2468         <rdar://problem/32225538>
2469
2470         Reviewed by Alexey Proskuryakov.
2471
2472         On-device testing requires that servers are started before ports set-up their
2473         test environments.
2474
2475         * Scripts/webkitpy/layout_tests/controllers/layout_test_runner.py:
2476         (LayoutTestRunner.__init__): Start servers when initializing LayoutTestRunner.
2477         (LayoutTestRunner.run_tests): Move the starting of servers to the initializer.
2478         * Scripts/webkitpy/layout_tests/controllers/manager.py:
2479         (Manager.__init__): Delay construction of the test runner until we can determine
2480         if servers need to be started.
2481         (Manager.run): Determine if servers need to be started and construct the test runner.
2482         (Manager._run_tests): Move the determination of servers to run into Manager.run.
2483
2484 2017-05-16  Adrian Perez de Castro  <aperez@igalia.com>
2485
2486         Unreviewed, adding myself to contributors.json
2487
2488         * Scripts/webkitpy/common/config/contributors.json:
2489
2490 2017-05-16  Claudio Saavedra  <csaavedra@igalia.com>
2491
2492         [GTK] Tests that always pass when run alone, but fail in the bots
2493         https://bugs.webkit.org/show_bug.cgi?id=168572
2494
2495         Reviewed by Michael Catanzaro.
2496
2497         PlatformWebView::viewSupportsOptions() is basically a comparison
2498         that checks that the passed options are the ones supported by the
2499         web view. There is no reason for them to be implemented for each
2500         platform differently. In fact doing so causes issues each time a
2501         new option is added, if the corresponding platform implementation
2502         is not updated accordingly.
2503
2504         A consequence of not updating the viewSupportOptions()
2505         implementations when new options are added is that tests that need
2506         these options might fail if they are executed after a test that
2507         didn't need the option, as the webview will be reused even if the
2508         option is not supported. This cannot be spotted when running the
2509         tests individually. See bug #165133 for other example of the same
2510         problem.
2511
2512         Remove the platform implementations and make the comparison a
2513         method of the TestOptions structure, so that the check is in one
2514         place. For the time being, only include in the comparison the
2515         options that were checked in the mac platform, which seem to be
2516         the only ones relevant this far (unless newer ones have also been
2517         forgotten).
2518
2519         * WebKitTestRunner/PlatformWebView.h:
2520         (WTR::PlatformWebView::viewSupportsOptions): Use the method
2521         defined below.
2522         * WebKitTestRunner/TestOptions.h:
2523         (WTR::TestOptions::hasSameInitializationOptions): Added.
2524         * WebKitTestRunner/gtk/PlatformWebViewGtk.cpp:
2525         (WTR::PlatformWebView::viewSupportsOptions): Deleted.
2526         * WebKitTestRunner/ios/PlatformWebViewIOS.mm:
2527         (WTR::PlatformWebView::viewSupportsOptions): Deleted.
2528         * WebKitTestRunner/mac/PlatformWebViewMac.mm:
2529         (WTR::PlatformWebView::viewSupportsOptions): Deleted.
2530         * WebKitTestRunner/wpe/PlatformWebViewWPE.cpp:
2531         (WTR::PlatformWebView::viewSupportsOptions): Deleted.
2532
2533 2017-05-15  Yusuke Suzuki  <utatane.tea@gmail.com>
2534
2535         [JSC] Build testapi in non Apple ports
2536         https://bugs.webkit.org/show_bug.cgi?id=172103
2537
2538         Reviewed by Filip Pizlo.
2539
2540         Now testapi is drived in JSCOnly, GTK and WPE ports too.
2541
2542         * Scripts/build-jsc:
2543         * Scripts/run-javascriptcore-tests:
2544
2545 2017-05-15  Youenn Fablet  <youenn@apple.com>
2546
2547         WPT test importer should not account for slow manual tests
2548         https://bugs.webkit.org/show_bug.cgi?id=172127
2549
2550         Reviewed by Ryosuke Niwa.
2551
2552         Making sure manual tests are not triggering updating tests-options.json file.
2553
2554         * Scripts/webkitpy/w3c/test_importer.py:
2555         (TestImporter.find_importable_tests):
2556         (TestImporter._already_identified_as_resource_file):
2557         (TestImporter.update_tests_options):
2558         * Scripts/webkitpy/w3c/test_importer_unittest.py:
2559         (test_manual_slow_test):
2560
2561 2017-05-15  Jonathan Bedard  <jbedard@apple.com>
2562
2563         webkitpy: Some versions of simctl do not place parenthesis around runtime identifiers
2564         https://bugs.webkit.org/show_bug.cgi?id=172142
2565
2566         Reviewed by Tim Horton.
2567
2568         * Scripts/webkitpy/xcode/simulator.py:
2569         (Simulator._parse_runtimes): Newer versions of simctl output do not put parenthesis
2570         around runtime identifiers.
2571         * Scripts/webkitpy/xcode/simulator_unittest.py: Add tests for new simctl output.
2572
2573 2017-05-15  Ryosuke Niwa  <rniwa@webkit.org>
2574
2575         Update ARES-6 plan file to use the latest version
2576         https://bugs.webkit.org/show_bug.cgi?id=172139
2577
2578         Reviewed by Keith Miller.
2579
2580         Include r216538.
2581
2582         * Scripts/webkitpy/benchmark_runner/data/plans/ares6.plan:
2583
2584 2017-05-15  Jeremy Jones  <jeremyj@apple.com>
2585
2586         Disable Picture In Picture API tests on unsupported platforms.
2587         https://bugs.webkit.org/show_bug.cgi?id=172125
2588         rdar://problem/32199477
2589
2590         Reviewed by Simon Fraser.
2591
2592         The callbacks and allowing picture-in-picture require new SPI.
2593
2594         * TestWebKitAPI/Tests/WebKit2Cocoa/PictureInPictureDelegate.mm:
2595
2596 2017-05-15  Brady Eidson  <beidson@apple.com>
2597
2598         [ios-simulator] API test WKWebView.ClearAppCache is failing.
2599         https://bugs.webkit.org/show_bug.cgi?id=172120
2600
2601         Unreviewed test gardening.
2602
2603         * TestWebKitAPI/Tests/WebKit2Cocoa/LocalStorageClear.mm:
2604         (TEST): ios-sim needs explicit deleting of the app cache paths that I'd removed in 216805.
2605           Restoring that code fixes this.
2606
2607 2017-05-15  Timothy Horton  <timothy_horton@apple.com>
2608
2609         Null deref under WebContentReader::readURL when interacting with a file URL
2610         https://bugs.webkit.org/show_bug.cgi?id=172045
2611         <rdar://problem/25880647>
2612
2613         Reviewed by Wenson Hsieh.
2614
2615         * TestWebKitAPI/Tests/ios/DataInteractionTests.mm:
2616         (TestWebKitAPI::TEST):
2617         The text of the file URL is pasted because a textual version of it gets
2618         onto the pasteboard. However, this test would have crashed before. Also
2619         tests that we don't make an <a>.
2620
2621 2017-05-14  Per Arne Vollan  <pvollan@apple.com>
2622
2623         [Win] fast/cookies/local-file-can-set-cookies.html is flaky.
2624         https://bugs.webkit.org/show_bug.cgi?id=172071
2625
2626         Reviewed by Alexey Proskuryakov.
2627
2628         * DumpRenderTree/win/DumpRenderTree.cpp:
2629         (resetWebPreferencesToConsistentValues):
2630
2631 2017-05-14  Chris Dumez  <cdumez@apple.com>
2632
2633         Drop PassRefPtr class from WTF
2634         https://bugs.webkit.org/show_bug.cgi?id=172091
2635
2636         Reviewed by Alex Christensen.
2637
2638         Drop API test coverage.
2639
2640         * TestWebKitAPI/Tests/WTF/Ref.cpp:
2641         (TestWebKitAPI::TEST):
2642         (TestWebKitAPI::passWithPassRefPtr): Deleted.
2643
2644 2017-05-13  Eric Carlson  <eric.carlson@apple.com>
2645
2646         [MediaStream] deviceId constraint doesn't work with getUserMedia
2647         https://bugs.webkit.org/show_bug.cgi?id=171877
2648         <rdar://problem/31899730>
2649
2650         Reviewed by Jer Noble.
2651
2652         The device ID hash salt is now required for getUserMedia to check deviceId constraint, so
2653         implement the "checkUserMediaPermission" callback.
2654         * TestWebKitAPI/Tests/WebKit2/UserMedia.cpp:
2655         (TestWebKitAPI::decidePolicyForUserMediaPermissionRequestCallBack):
2656         (TestWebKitAPI::checkUserMediaPermissionCallback):
2657         (TestWebKitAPI::TEST):
2658
2659         * TestWebKitAPI/Tests/WebKit2Cocoa/UserMediaDisabled.mm:
2660         (-[UserMediaUIDelegate _webView:checkUserMediaPermissionForURL:mainFrameURL:frameIdentifier:decisionHandler:]):
2661
2662 2017-05-13  Chris Dumez  <cdumez@apple.com>
2663
2664         Stop using RefPtr::release()
2665         https://bugs.webkit.org/show_bug.cgi?id=172074
2666
2667         Reviewed by Geoffrey Garen.
2668
2669         * TestWebKitAPI/Tests/WTF/RefPtr.cpp:
2670         (TestWebKitAPI::TEST):
2671
2672 2017-05-13  Commit Queue  <commit-queue@webkit.org>
2673
2674         Unreviewed, rolling out r216808.
2675         https://bugs.webkit.org/show_bug.cgi?id=172075
2676
2677         caused lldb to hang when debugging (Requested by smfr on
2678         #webkit).
2679
2680         Reverted changeset:
2681
2682         "Use Mach exceptions instead of signals where possible"
2683         https://bugs.webkit.org/show_bug.cgi?id=171865
2684         http://trac.webkit.org/changeset/216808
2685
2686 2017-05-12  Alex Christensen  <achristensen@webkit.org>
2687
2688         Rename WKContentExtension to WKContentRuleList
2689         https://bugs.webkit.org/show_bug.cgi?id=172053
2690         <rdar://problem/32141005>
2691
2692         Reviewed by Geoffrey Garen.
2693
2694         * TestWebKitAPI/Tests/WebKit2Cocoa/WKContentExtensionStore.mm:
2695         (WKContentRuleListStoreTest::SetUp):
2696         (TEST_F):
2697         (-[ContentRuleListDelegate webView:runJavaScriptAlertPanelWithMessage:initiatedByFrame:completionHandler:]):
2698         (WKContentExtensionStoreTest::SetUp): Deleted.
2699         (-[ContentExtensionDelegate webView:runJavaScriptAlertPanelWithMessage:initiatedByFrame:completionHandler:]): Deleted.
2700
2701 2017-05-12  Keith Miller  <keith_miller@apple.com>
2702
2703         Use Mach exceptions instead of signals where possible
2704         https://bugs.webkit.org/show_bug.cgi?id=171865
2705
2706         Reviewed by Mark Lam.
2707
2708         * TestWebKitAPI/Tests/WTF/ThreadMessages.cpp:
2709         (runThreadMessageTest):
2710         (TEST):
2711
2712 2017-05-12  Jeremy Jones  <jeremyj@apple.com>
2713
2714         Add objc version of WK2 UIPageClient setHasVideoInPictureInPicture and rename it to hasVideoInPictureInPictureDidChange.
2715         https://bugs.webkit.org/show_bug.cgi?id=172048
2716         rdar://problem/32163054
2717
2718         Reviewed by Simon Fraser.
2719
2720         Add a WKWebView test for hasVideoInPictureInPictureDidChange UIDelegate callback.
2721
2722         * TestWebKitAPI/Tests/WebKit2Cocoa/PictureInPictureDelegate.html:
2723         * TestWebKitAPI/Tests/WebKit2Cocoa/PictureInPictureDelegate.mm:
2724         (hasVideoInPictureInPictureDidChange):
2725         (-[PictureInPictureUIDelegate _webView:hasVideoInPictureInPictureDidChange:]):
2726         (-[PictureInPictureUIDelegate userContentController:didReceiveScriptMessage:]):
2727         (TestWebKitAPI::TEST):
2728
2729 2017-05-12  Brady Eidson  <beidson@apple.com>
2730
2731         REGRESSION (r216711): API test WKWebView.ClearAppCache is failing.
2732         https://bugs.webkit.org/show_bug.cgi?id=172030
2733
2734         Unreviewed - Test gardening
2735
2736         Try to resolve this once and for all by using the WebsiteDataStore API to nuke everything
2737         before the test starts.
2738
2739         * TestWebKitAPI/Tests/WebKit2Cocoa/LocalStorageClear.mm:
2740         (defaultWebsiteCacheDirectory):
2741         (defaultApplicationCacheDirectory):
2742         (TEST):
2743         (defaultWebsiteDataDirectory): Deleted.
2744
2745 2017-05-12  David Quesada  <david_quesada@apple.com>
2746
2747         Add SPI for overriding WKWebView's clipping behavior for _visibleContentRect
2748         https://bugs.webkit.org/show_bug.cgi?id=172000
2749         rdar://problem/32144756
2750
2751         Reviewed by Simon Fraser.
2752
2753         Added API tests to verify that WKWebView provides the expected value for
2754         _visibleContentRect in various configurations. (i.e. not inside a scrollview,
2755         inside a scrollview but not clipped, clipped by an ancestor scrollview,
2756         clipped by the webview's _enclosingViewForExposedRectComputation)
2757
2758         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
2759         * TestWebKitAPI/Tests/WebKit2Cocoa/VisibleContentRect.mm: Added.
2760         (-[TestWKWebViewWithEnclosingView _enclosingViewForExposedRectComputation]):
2761         (TestWebKitAPI::TEST):
2762
2763 2017-05-12  Brady Eidson  <beidson@apple.com>
2764
2765         REGRESSION (r216711): API test WKWebView.ClearAppCache is failing.
2766         https://bugs.webkit.org/show_bug.cgi?id=172030
2767
2768         Unreviewed - Test gardening, in effect...
2769
2770         More exploration as to why this continues to fail on the bots.
2771         
2772         This change should give us a smoking gun.
2773         
2774         * TestWebKitAPI/Tests/WebKit2Cocoa/LocalStorageClear.mm:
2775         (TEST):
2776
2777 2017-05-12  Hyungwook Lee  <hyungwook.lee@navercorp.com>
2778
2779         [GTK] Fix compile warnings in PlatformImageCairo.cpp
2780         https://bugs.webkit.org/show_bug.cgi?id=171850
2781
2782         Reviewed by Michael Catanzaro.
2783
2784         * ImageDiff/cairo/PlatformImageCairo.cpp:
2785         (ImageDiff::PlatformImage::createFromStdin):
2786         (ImageDiff::PlatformImage::writeAsPNGToStdout):
2787
2788 2017-05-12  Jeremy Jones  <jeremyj@apple.com>
2789
2790         Add UIClient callback for when picture-in-picture is activated.
2791         https://bugs.webkit.org/show_bug.cgi?id=172023
2792
2793         Reviewed by Simon Fraser.
2794
2795         Added a test for WKPageUIClientV10 setHasVideoInPictureInPicture.
2796
2797         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
2798         * TestWebKitAPI/Tests/WebKit2Cocoa/PictureInPictureDelegate.html: Added.
2799         * TestWebKitAPI/Tests/WebKit2Cocoa/PictureInPictureDelegate.mm: Added.
2800         (onLoadedCompletedCallback):
2801         (waitUntilOnLoadIsCompleted):
2802         (didFinishLoadForFrame):
2803         (setHasVideoInPictureInPicture):
2804         (TestWebKitAPI::TEST):
2805
2806 2017-05-12  Jonathan Bedard  <jbedard@apple.com>
2807
2808         Unreviewed follow-up to r216776.
2809
2810         * Scripts/webkitpy/port/base.py:
2811         (Port.path_to_crash_logs): Raise not implemented.
2812         * Scripts/webkitpy/port/test.py:
2813         (TestPort.path_to_crash_logs): Return results directory as the location of crash logs.
2814         * Scripts/webkitpy/port/win.py:
2815         (WinPort.path_to_crash_logs): Ditto.
2816
2817 2017-05-12  Alexey Proskuryakov  <ap@apple.com>
2818
2819         Bot watcher's dashboard shows results links twice sometimes
2820         https://bugs.webkit.org/show_bug.cgi?id=172043
2821
2822         Reviewed by Tim Horton.
2823
2824         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BuildbotTesterQueueView.js:
2825         (BuildbotTesterQueueView.prototype._presentPopoverForGenericTestFailures):
2826
2827 2017-05-12  Brady Eidson  <beidson@apple.com>
2828
2829         REGRESSION (r216711): API test WKWebView.ClearAppCache is failing.
2830         https://bugs.webkit.org/show_bug.cgi?id=172030
2831
2832         Unreviewed - Test gardening, in effect...
2833
2834         This failure is only being seen by the bots.
2835         
2836         I believe this test is utterly broken in the first place; when it checks the .wal file's
2837         size that is not actually an indicator that the records were deleted.
2838         
2839         But that isn't what's coming up as failure on the bots.
2840         
2841         This patch is an attempt to:
2842         1 - More forcefully clear the Website data directory of leftovers before the test starts.
2843         2 - Give an earlier indication of the failure that the bots are seeing, to possibly reveal more.
2844
2845         * TestWebKitAPI/Tests/WebKit2Cocoa/LocalStorageClear.mm:
2846         (defaultWebsiteDataDirectory):
2847         (defaultApplicationCacheDirectory):
2848         (TEST):
2849
2850 2017-05-12  Jonathan Bedard  <jbedard@apple.com>
2851
2852         webkitpy: Pass directory with crash logs into CrashLogs
2853         https://bugs.webkit.org/show_bug.cgi?id=172033
2854         <rdar://problem/32157616>
2855
2856         Reviewed by Daniel Bates.
2857
2858         Refactor CrashLogs and the callers of CrashLogs so that the port object owns
2859         the location of crash logs.
2860
2861         * Scripts/webkitpy/common/system/crashlogs.py:
2862         (CrashLogs.__init__): Pass mandatory crash_log_directory when constructing.
2863         (CrashLogs._find_newest_log_darwin): Use self._crash_log_directory instead of
2864         generating one.
2865         (CrashLogs._find_newest_log_win): Use self._crash_log_directory instead of
2866         self._results_directory.
2867         (CrashLogs._find_all_logs_darwin): Use self._crash_log_directory instead of
2868         generating one.
2869         (CrashLogs._log_directory_darwin): Moved to port.
2870         * Scripts/webkitpy/common/system/crashlogs_unittest.py: Update tests since the path
2871         to the crash log is no longer owned by CrashLogs.
2872         * Scripts/webkitpy/layout_tests/run_webkit_tests_integrationtest.py: Use the general
2873         directory for uploading crash logs. Note that crash logs are only supported on Mac
2874         and Windows.
2875         * Scripts/webkitpy/port/apple.py: Remove unneeded CrashLogs import.
2876         * Scripts/webkitpy/port/base.py:
2877         (Port.path_to_crash_logs): Unless ports declare otherwise, crash logs are assumed
2878         to be in the results directory.
2879         * Scripts/webkitpy/port/darwin.py:
2880         (DarwinPort.path_to_crash_logs): Moved from CrashLogs._log_directory_darwin.
2881         (DarwinPort._look_for_all_crash_logs_in_log_dir): Use port specific crash log path.
2882         (DarwinPort._get_crash_log): Ditto.
2883         * Scripts/webkitpy/port/darwin_testcase.py:
2884         (DarwinTest.test_crashlog_path): Test that the Darwin ports are correctly calculating
2885         the path to crash logs.
2886         * Scripts/webkitpy/port/ios_device.py:
2887         (IOSDevicePort.path_to_crash_logs): Currently, crash log retrieval is undefined for iOS.
2888         * Scripts/webkitpy/port/ios_device_unittest.py:
2889         (IOSDeviceTest.test_crashlog_path): Currently, crash log retrieval is undefined for iOS.
2890         * Scripts/webkitpy/port/ios_simulator.py: Remove unneeded CrashLogs import.
2891         * Scripts/webkitpy/port/mac.py: Ditto.
2892         * Scripts/webkitpy/port/test.py:
2893         (TestDriver.run_test): Use port specific crash log path when retrieving crash logs.
2894         * Scripts/webkitpy/port/win.py:
2895         (WinPort._get_crash_log): Ditto.
2896         * Scripts/webkitpy/tool/commands/queries.py:
2897         (execute): Construct a port object since this is the object which owns the path to crash logs.
2898
2899 2017-05-12  Carlos Garcia Campos  <cgarcia@igalia.com>
2900
2901         Unreviewed. Fix GTK+ test /webkit2/WebKitWebView/create-navigation-data after r216615.
2902
2903         In r216615 the custom code for window.open() was removed. The generated code now correctly handles the optional
2904         URL parameter using the default value "about:blank" when not provided.
2905
2906         * TestWebKitAPI/Tests/WebKit2Gtk/TestUIClient.cpp:
2907         (testWebViewCreateNavigationData):
2908
2909 2017-05-11  Youenn Fablet  <youenn@apple.com>
2910
2911         Allow WPT server to serve specific WebKit test
2912         https://bugs.webkit.org/show_bug.cgi?id=171479
2913
2914         Reviewed by Ryosuke Niwa.
2915
2916         Adding a new mount point to WPT server.
2917         It points to LayoutTests/http/wpt folder and is triggered on "/WebKit" urls.
2918
2919         Updating the webkitpy infrastructure to launch WPT server and do test url mapping for LayoutTests/wpt tests.
2920
2921         * Scripts/webkitpy/layout_tests/controllers/manager.py:
2922         (Manager.__init__):
2923         (Manager._is_http_test):
2924         (Manager._needs_web_platform_test):
2925         (Manager._run_tests):
2926         (Manager._is_web_platform_test): Deleted.
2927         * Scripts/webkitpy/layout_tests/servers/web_platform_test_launcher.py:
2928         (build_routes):
2929         (main):
2930         * Scripts/webkitpy/port/driver.py:
2931         (Driver):
2932         (Driver.is_webkit_specific_web_platform_test):
2933         (Driver.test_to_uri):
2934         (Driver._command_from_driver_input):
2935
2936 2017-05-11  Brady Eidson  <beidson@apple.com>
2937
2938         [WKWebsiteDataStore removeDataOfTypes:...] doesn't work for IndexedDB if the data store has a custom IDB path.
2939         <rdar://problem/30612463> and https://bugs.webkit.org/show_bug.cgi?id=171994
2940
2941         Reviewed by Andy Estes.
2942         Informal review by Maureen Daum.
2943
2944         * TestWebKitAPI/Tests/WebKit2Cocoa/WebsiteDataStoreCustomPaths.mm:
2945         (TEST):
2946
2947 2017-05-11  Joseph Pecoraro  <pecoraro@apple.com>
2948
2949         REGRESSION(r216217): lldb_webkit.py no longer prints out a WTFString, StringImpl needs to handle StringImplShape change
2950         https://bugs.webkit.org/show_bug.cgi?id=171989
2951
2952         Reviewed by Brian Burg.
2953
2954         * lldb/lldb_webkit.py:
2955         (WTFStringImplProvider.get_data8):
2956         (WTFStringImplProvider.get_data16):
2957         m_data8 and m_data16 are now part of the superclass StringImplShape
2958         instead of directly in StringImpl. So first get the shape by getting
2959         index 0, and the data properties are the same offset within that.
2960
2961 2017-05-11  Joseph Pecoraro  <pecoraro@apple.com>
2962
2963         Remove Vibration API
2964         https://bugs.webkit.org/show_bug.cgi?id=171766
2965
2966         Rubber-stamped by Alexey Proskuryakov.
2967
2968         * Scripts/webkitperl/FeatureList.pm:
2969
2970 2017-05-11  Carlos Alberto Lopez Perez  <clopez@igalia.com>
2971
2972         Add WPE release bots
2973         https://bugs.webkit.org/show_bug.cgi?id=171973
2974
2975         Reviewed by Žan Doberšek.
2976
2977         This adds a WPE Release Build bot (64-bit) and a WPE Release Test bot.
2978         It also adds a new WPE buildbot category.
2979
2980         * BuildSlaveSupport/build.webkit.org-config/config.json:
2981         * BuildSlaveSupport/build.webkit.org-config/master.cfg:
2982         (InstallWpeDependencies):
2983         (appendCustomBuildFlags):
2984         (Factory.__init__):
2985         (loadBuilderConfig):
2986         * BuildSlaveSupport/build.webkit.org-config/mastercfg_unittest.py:
2987         * BuildSlaveSupport/build.webkit.org-config/templates/root.html:
2988
2989 2017-05-09  Sam Weinig  <sam@webkit.org>
2990
2991         Remove support for legacy Notifications
2992         https://bugs.webkit.org/show_bug.cgi?id=171487
2993
2994         Reviewed by Jon Lee.
2995
2996         * DumpRenderTree/win/DRTDesktopNotificationPresenter.cpp:
2997         (DRTDesktopNotificationPresenter::checkNotificationPermission):
2998         * Scripts/webkitperl/FeatureList.pm:
2999         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
3000         Remove use and definition of ENABLE_LEGACY_NOTIFICATIONS.
3001
3002 2017-05-10  Michael Catanzaro  <mcatanzaro@igalia.com>
3003
3004         Remove user agent quirk for Slack
3005         https://bugs.webkit.org/show_bug.cgi?id=171869
3006
3007         Reviewed by Carlos Garcia Campos.
3008
3009         Remove the corresponding test.
3010
3011         * TestWebKitAPI/Tests/WebCore/UserAgentQuirks.cpp:
3012         (TestWebKitAPI::TEST):
3013
3014 2017-05-10  Commit Queue  <commit-queue@webkit.org>
3015
3016         Unreviewed, rolling out r216578.
3017         https://bugs.webkit.org/show_bug.cgi?id=171920
3018
3019         Broke the GTK+ build with Wayland enabled (Requested by KaL on
3020         #webkit).
3021
3022         Reverted changeset:
3023
3024         "[GTK] Bump GTK+ and its dependencies in jhbuild"
3025         https://bugs.webkit.org/show_bug.cgi?id=171918
3026         http://trac.webkit.org/changeset/216578
3027
3028 2017-05-10  Carlos Garcia Campos  <cgarcia@igalia.com>
3029
3030         [GTK] Bump GTK+ and its dependencies in jhbuild
3031         https://bugs.webkit.org/show_bug.cgi?id=171918
3032
3033         Reviewed by Carlos Alberto Lopez Perez.
3034
3035         * WebKitTestRunner/InjectedBundle/gtk/ActivateFontsGtk.cpp:
3036         (WTR::initializeGtkSettings):
3037         * gtk/jhbuild.modules:
3038         * gtk/patches/gtk+-configure-fix-detecting-CUPS-2.x.patch: Removed.
3039         * gtk/patches/librsvg-2.36.1-bump-up-config.guess-to-support-aarch64.patch: Removed.
3040
3041 2017-05-10  Don Olmstead  <don.olmstead@am.sony.com>
3042
3043         [Win] Set CMake args in build-webkit
3044         https://bugs.webkit.org/show_bug.cgi?id=171436
3045
3046         Reviewed by Per Arne Vollan.
3047
3048         * Scripts/build-webkit:
3049
3050 2017-05-10  Carlos Garcia Campos  <cgarcia@igalia.com>
3051
3052         ImageDiff: Add CG implementation for new ImageDiff
3053         https://bugs.webkit.org/show_bug.cgi?id=170608
3054
3055         Reviewed Alex Christensen.
3056
3057         * DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj:
3058         * DumpRenderTree/win/ImageDiffCairo.cpp: Removed.
3059         * DumpRenderTree/win/ImageDiffWin.cpp: Removed.
3060         * ImageDiff/CMakeLists.txt:
3061         * ImageDiff/Cairo.cmake:
3062         * ImageDiff/ImageDiff.cpp:
3063         (main):
3064         * ImageDiff/ImageDiff.xcodeproj/project.pbxproj:
3065         * ImageDiff/PlatformImage.cpp:
3066         * ImageDiff/PlatformImage.h:
3067         * ImageDiff/cairo/PlatformImageCairo.cpp:
3068         * ImageDiff/cg/ImageDiff.cpp: Removed.
3069         * ImageDiff/cg/PlatformImageCG.cpp: Added.
3070         (ImageDiff::PlatformImage::createFromStdin):
3071         (ImageDiff::PlatformImage::createFromDiffData):
3072         (ImageDiff::PlatformImage::PlatformImage):
3073         (ImageDiff::PlatformImage::~PlatformImage):
3074         (ImageDiff::PlatformImage::width):
3075         (ImageDiff::PlatformImage::height):
3076         (ImageDiff::PlatformImage::rowBytes):
3077         (ImageDiff::PlatformImage::hasAlpha):
3078         (ImageDiff::PlatformImage::pixels):
3079         (ImageDiff::PlatformImage::writeAsPNGToStdout):
3080
3081 2017-05-10  Zan Dobersek  <zdobersek@igalia.com>
3082
3083         Enable FTL JIT by default on AArch64
3084         https://bugs.webkit.org/show_bug.cgi?id=144039
3085
3086         Reviewed by Yusuke Suzuki.
3087
3088         * Scripts/build-jsc: Enable the FTL JIT option by default on ARM64.
3089         * Scripts/run-jsc-stress-tests: Unmark the ARM64 and Linux combination
3090         as an unsupported FTL platform.
3091         * Scripts/webkitdirs.pm:
3092         (isARM64): Returns 1 if the determined architecture is 'arm64'.
3093         * Scripts/webkitperl/FeatureList.pm: Enable FTL_JIT and WEBASSEMBLY on ARM64.
3094
3095 2017-05-09  Jonathan Bedard  <jbedard@apple.com>
3096
3097         webkitpy: Remove unneeded crash log retrieval, refactor Darwin crash retrieval
3098         https://bugs.webkit.org/show_bug.cgi?id=170857
3099         <rdar://problem/31635373>
3100
3101         Reviewed by Aakash Jain.
3102
3103         Since LayoutTestRelay has been removed, iOS Simulators and Macs can use the same
3104         code to search for crash logs.
3105
3106         * Scripts/webkitpy/port/darwin.py:
3107         (DarwinPort._get_crash_log): Moved from MacPort.
3108         * Scripts/webkitpy/port/darwin_testcase.py:
3109         (DarwinTest.test_get_crash_log): Moved from MacTest.
3110         * Scripts/webkitpy/port/ios_device.py:
3111         (IOSDevicePort._get_crash_log): Implement pass-through for iOS device, since iOS
3112         devices must search for crash-logs remotely.
3113         * Scripts/webkitpy/port/ios_simulator.py:
3114         (IOSSimulatorPort._get_crash_log): Deleted.
3115         * Scripts/webkitpy/port/ios_simulator_unittest.py:
3116         (IOSSimulatorTest.test_get_crash_log): Deleted.
3117         * Scripts/webkitpy/port/mac.py:
3118         (MacPort._get_crash_log): Moved to DarwinPort
3119         * Scripts/webkitpy/port/mac_unittest.py:
3120         (MacTest.test_get_crash_log): Moved to DarwinTest.
3121
3122 2017-05-09  Jonathan Bedard  <jbedard@apple.com>
3123
3124         build ImageDiff with host SDK from Make
3125         https://bugs.webkit.org/show_bug.cgi?id=171835
3126
3127         Reviewed by Alexey Proskuryakov.
3128
3129         ImageDiff should be built for the default SDK and default architecture when
3130         the SDKROOT is set to either iOS device or iOS simulator. Check the
3131         DO_NOT_BUILD_IMAGE_DIFF flag to skip the ImageDiff build.
3132
3133         * ImageDiff/Makefile: Use Mac SDK when building for iOS Simulator or iOS device.
3134         * Makefile: Do not build ImageDiff if the DO_NOT_BUILD_IMAGE_DIFF flag is set.
3135
3136 2017-05-09  Matt Lewis  <jlewis3@apple.com>
3137
3138         Unreviewed, adding myself to contributors.json
3139
3140         * Scripts/webkitpy/common/config/contributors.json:
3141
3142 2017-05-09  Jonathan Bedard  <jbedard@apple.com>
3143
3144         REGRESSION: ImageDiff not building with make
3145         https://bugs.webkit.org/show_bug.cgi?id=171788
3146
3147         Reviewed by Alex Christensen.
3148
3149         * Makefile: Build ImageDiff for all platforms.
3150
3151 2017-05-09  Fujii Hironori  <Hironori.Fujii@sony.com>
3152
3153         [Win] ImageDiff isn't built since Bug 168945
3154         https://bugs.webkit.org/show_bug.cgi?id=171847
3155
3156         Reviewed by Alex Christensen.
3157
3158         * CMakeLists.txt: Add 'ImageDiff' sub-directory to build if WIN32.
3159         * ImageDiff/ImageDiff.cpp: Include some header files to fix compilation errors.
3160         * ImageDiff/PlatformWin.cmake: Define USE_CAIRO if WinCairo port.
3161
3162 2017-05-09  Zan Dobersek  <zdobersek@igalia.com>
3163
3164         Upstream the WPE port
3165         https://bugs.webkit.org/show_bug.cgi?id=171110
3166
3167         Reviewed by Alex Christensen.
3168
3169         webkit-dev thread:
3170         https://lists.webkit.org/pipermail/webkit-dev/2017-April/028923.html
3171
3172         Add WPE support to various tooling scripts, TestWebKitAPI and WebKitTestRunner.
3173         In-file changes removed from this ChangeLog entry for brevity.
3174
3175         * BuildSlaveSupport/built-product-archive:
3176         * BuildSlaveSupport/test-result-archive:
3177         * CMakeLists.txt:
3178         * ImageDiff/PlatformWPE.cmake: Added.
3179         * Scripts/build-dumprendertree:
3180         * Scripts/build-webkit:
3181         * Scripts/build-webkittestrunner:
3182         * Scripts/update-webkit-libs-jhbuild:
3183         * Scripts/update-webkitwpe-libs: Added.
3184         * Scripts/webkitdirs.pm:
3185         * Scripts/webkitperl/FeatureList.pm:
3186         * Scripts/webkitpy/layout_tests/run_webkit_tests.py:
3187         * Scripts/webkitpy/port/factory.py:
3188         * Scripts/webkitpy/port/wpe.py: Added.
3189         * TestWebKitAPI/PlatformWPE.cmake: Added.
3190         * TestWebKitAPI/wpe/InjectedBundleControllerWPE.cpp: Copied from Source/WebKit2/Shared/DrawingAreaInfo.h.
3191         * TestWebKitAPI/wpe/PlatformUtilitiesWPE.cpp: Added.
3192         * TestWebKitAPI/wpe/main.cpp: Copied from Source/WebKit2/Shared/DrawingAreaInfo.h.
3193         * WebKitTestRunner/InjectedBundle/AccessibilityController.cpp:
3194         * WebKitTestRunner/InjectedBundle/AccessibilityController.h:
3195         * WebKitTestRunner/InjectedBundle/AccessibilityUIElement.cpp:
3196         * WebKitTestRunner/InjectedBundle/AccessibilityUIElement.h:
3197         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
3198         * WebKitTestRunner/InjectedBundle/TestRunner.h:
3199         * WebKitTestRunner/InjectedBundle/wpe/AccessibilityControllerWPE.cpp: Added.
3200         * WebKitTestRunner/InjectedBundle/wpe/AccessibilityUIElementWPE.cpp: Added.
3201         * WebKitTestRunner/InjectedBundle/wpe/ActivateFontsWPE.cpp: Added.
3202         * WebKitTestRunner/InjectedBundle/wpe/InjectedBundleWPE.cpp: Copied from Source/WebKit2/Shared/DrawingAreaInfo.h.
3203         * WebKitTestRunner/InjectedBundle/wpe/TestRunnerWPE.cpp: Copied from Source/WebKit2/Shared/DrawingAreaInfo.h.
3204         * WebKitTestRunner/PlatformWPE.cmake: Added.
3205         * WebKitTestRunner/PlatformWebView.h:
3206         * WebKitTestRunner/TestController.cpp:
3207         * WebKitTestRunner/wpe/EventSenderProxyWPE.cpp: Added.
3208         * WebKitTestRunner/wpe/HeadlessViewBackend.cpp: Added.
3209         * WebKitTestRunner/wpe/HeadlessViewBackend.h: Copied from Source/WebKit2/Shared/CoordinatedGraphics/threadedcompositor/CompositingRunLoop.h.
3210         * WebKitTestRunner/wpe/PlatformWebViewWPE.cpp: Added.
3211         * WebKitTestRunner/wpe/TestControllerWPE.cpp: Added.
3212         * WebKitTestRunner/wpe/main.cpp: Copied from Source/WebKit2/Shared/DrawingAreaInfo.h.
3213         * jhbuild/jhbuild-wrapper:
3214         * wpe/generate-inspector-gresource-manifest.py: Added.
3215         * wpe/jhbuild.modules: Added.
3216         * wpe/jhbuildrc: Added.
3217         * wpe/patches/cairo-egl-device-create-for-egl-surface.patch: Added.
3218         * wpe/patches/fontconfig-C-11-requires-a-space-between-literal-and-identifier.patch: Added.
3219         * wpe/patches/freetype6-2.4.11-truetype-font-height-fix.patch: Added.
3220         * wpe/patches/gdate-suppress-string-format-literal-warning.patch: Added.
3221         * wpe/patches/glib-warning-fix.patch: Added.
3222         * wpe/patches/gst-plugins-bad-0001-dtls-port-to-OpenSSL-1.1.0.patch: Added.
3223         * wpe/patches/gst-plugins-bad-0002-dtlscertificate-Fix-error-checking-in-RSA_generate_k.patch: Added.
3224         * wpe/patches/gst-plugins-good-Revert-qtdemux-expose-streams-with-first-moof-for-fr.patch: Added.
3225         * wpe/patches/gst-plugins-good-use-the-tfdt-decode-time.patch: Added.
3226         * wpe/patches/gstreamer-typefind-Only-push-a-CAPS-event-downstream-if-the-.patch: Added.
3227
3228 2017-05-08  Jonathan Bedard  <jbedard@apple.com>
3229
3230         Implement PlatformWebView::windowSnapshotImage and createBitmapContextFromWebView for iOS devices
3231         https://bugs.webkit.org/show_bug.cgi?id=169421
3232         <rdar://problem/30950171>
3233
3234         Reviewed by Tim Horton.
3235
3236         * DumpRenderTree/ios/PixelDumpSupportIOS.mm:
3237         (createBitmapContextFromWebView): Implement for IOSurface.
3238         * WebKitTestRunner/ios/PlatformWebViewIOS.mm:
3239         (WTR::PlatformWebView::windowSnapshotImage): Use snapshot API for device.
3240
3241 2017-05-08  Jonathan Bedard  <jbedard@apple.com>
3242
3243         buildbot: Cleanup simulators after running tests
3244         https://bugs.webkit.org/show_bug.cgi?id=171679
3245
3246         Reviewed by Aakash Jain.
3247
3248         simctl is partitioned for each user. Since kill-old-processes
3249         is run as root, we need to specify the buildbot user when tearing
3250         down simulators between steps.
3251
3252         * BuildSlaveSupport/build.webkit.org-config/master.cfg:
3253         (KillOldProcesses): Pass buildbot user to kill-old-processes.
3254         * BuildSlaveSupport/kill-old-processes:
3255         (main): Specify the user for simctl if one has been provided.
3256
3257 2017-05-08  Carlos Alberto Lopez Perez  <clopez@igalia.com>
3258
3259         REGRESSION(r216179): [GTK] Script install-dependencies misses liborc
3260         https://bugs.webkit.org/show_bug.cgi?id=171681
3261
3262         Reviewed by Carlos Garcia Campos.
3263
3264         * gtk/install-dependencies:
3265
3266 2017-05-08  Carlos Garcia Campos  <cgarcia@igalia.com>
3267
3268         Unreviewed. Fix GTK+ test /webkit2/WebKitConsoleMessage/network-error after r215556.
3269
3270         Glib uses now Unicode quotes in error messages.
3271
3272         * TestWebKitAPI/Tests/WebKit2Gtk/TestConsoleMessage.cpp:
3273         (testWebKitConsoleMessageNetworkError):
3274
3275 2017-05-08  Carlos Garcia Campos  <cgarcia@igalia.com>
3276
3277         Unreviewed. Fix GTK+ test /webkit2/WebKitWebView/javascript-dialogs after r215404.
3278
3279         Sending down+up keys is no longer enough to simulate a real user interaction after r215404, the key events now
3280         should be handled by the web process to be considered a user interaction. So, add an input to the HTML and send
3281         characters to the input. Also fix typo in the function name.
3282
3283         * TestWebKitAPI/Tests/WebKit2Gtk/TestUIClient.cpp:
3284         (testWebViewJavaScriptDialogs):
3285
3286 2017-05-07  Michael Catanzaro  <mcatanzaro@igalia.com>
3287
3288         [GTK] Cannot sign in with new Google sign-in page
3289         https://bugs.webkit.org/show_bug.cgi?id=171770
3290
3291         Unreviewed. This just adds a test.
3292
3293         * TestWebKitAPI/Tests/WebCore/UserAgentQuirks.cpp:
3294         (TestWebKitAPI::TEST):
3295
3296 2017-05-06  Simon Fraser  <simon.fraser@apple.com>
3297
3298         [iOS WK2] Make rotation tests more reliable
3299         https://bugs.webkit.org/show_bug.cgi?id=171778
3300
3301         Reviewed by Tim Horton.
3302
3303         Switching between "safari-style" rotation and normal rotation left state on the WKWebView
3304         that would cause later viewport-sensitive tests to fail. The WKWebView would be left
3305         with override layout parameters, and an override orientation, and these caused viewport
3306         size to leak into later tests, and WebCore orientation to not get reset correctly.
3307
3308         Also, WKWebView was unregistering for UIWindowDidRotateNotification notifications when
3309         an override orientation was set, and would never re-register, causing lost orientationchanged
3310         events.
3311
3312         Fix by exposing WKWebView SPI to clear the various bits of overide state. Also don't unregister
3313         from the UIWindowDidRotateNotification notification; it's already ignored anyway if it fires.
3314
3315         Also wait for a visible content rect update after resizing the WKWebVeiw between tests, to make sure
3316         the WebProcess is caught up before proceeding with the test.
3317
3318         * WebKitTestRunner/ios/PlatformWebViewIOS.mm:
3319         (-[PlatformWebViewController viewWillTransitionToSize:withTransitionCoordinator:]):
3320         * WebKitTestRunner/ios/TestControllerIOS.mm:
3321         (WTR::TestController::platformResetStateToConsistentValues):
3322         (WTR::TestController::platformConfigureViewForTest):
3323
3324 2017-05-06  Csaba Osztrogonác  <ossy@webkit.org>
3325
3326         [Mac][cmake] Buildfix after r216047
3327         https://bugs.webkit.org/show_bug.cgi?id=171769
3328
3329         Unreviewed buildfix.
3330
3331         * WebKitTestRunner/cocoa/TestRunnerWKWebView.mm:
3332
3333 2017-05-05  Brady Eidson  <beidson@apple.com>
3334
3335         API test WebKit2.WebsiteDataStoreCustomPaths is failing on ios-simulator.
3336         <rdar://problem/31977294> and https://bugs.webkit.org/show_bug.cgi?id=171513
3337
3338         Reviewed by Andy Estes.
3339
3340         * TestWebKitAPI/Tests/WebKit2Cocoa/WebsiteDataStoreCustomPaths.mm:
3341         (TEST):
3342
3343 2017-05-05  Brian Burg  <bburg@apple.com>
3344
3345         [Cocoa] Converting from WebCore::Cookie to NSHTTPCookie always marks cookies as session cookies
3346         https://bugs.webkit.org/show_bug.cgi?id=171748
3347         <rdar://problem/32027327>
3348
3349         Reviewed by Michael Catanzaro.
3350
3351         Remove temporary workaround now that the assertion failure is fixed.
3352
3353         * TestWebKitAPI/Tests/WebKit2Cocoa/WKHTTPCookieStore.mm:
3354         (TEST):
3355
3356 2017-05-05  Simon Fraser  <simon.fraser@apple.com>
3357
3358         Make it possible to test rotation in iOS WebKitTestRunner
3359         https://bugs.webkit.org/show_bug.cgi?id=171755
3360
3361         Reviewed by Tim Horton.
3362
3363         Add to UIScriptController:
3364             void simulateRotation(DeviceOrientation orientation, object callback);
3365             void simulateRotationLikeSafari(DeviceOrientation orientation, object callback);
3366
3367         The former just does a view resize, as a simple WKWebView app would do. The second does
3368         animation more like MobileSafari, using _begin/_endAnimatedResize. and associated override
3369         layout size and interface orientation. The two behaviors produce different resize and
3370         orientationchange events and sizes, and both need to be tested.
3371
3372         Rotation is initiated by a call on UIDevice, and responded to by the root view controller,
3373         which is now a custom subclass (PlatformWebViewController).
3374
3375         * DumpRenderTree/ios/UIScriptControllerIOS.mm:
3376         (WTR::UIScriptController::simulateRotation):
3377         (WTR::UIScriptController::simulateRotationLikeSafari):
3378         * DumpRenderTree/mac/UIScriptControllerMac.mm:
3379         (WTR::UIScriptController::simulateRotation):
3380         (WTR::UIScriptController::simulateRotationLikeSafari):
3381         * TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
3382         * TestRunnerShared/UIScriptContext/UIScriptController.cpp:
3383         (WTR::toDeviceOrientation):
3384         (WTR::UIScriptController::simulateRotation):
3385         (WTR::UIScriptController::simulateRotationLikeSafari):
3386         * TestRunnerShared/UIScriptContext/UIScriptController.h:
3387         * WebKitTestRunner/cocoa/TestRunnerWKWebView.h:
3388         * WebKitTestRunner/cocoa/TestRunnerWKWebView.mm:
3389         (-[TestRunnerWKWebView dealloc]):
3390         (-[TestRunnerWKWebView _didEndRotation]):
3391         * WebKitTestRunner/ios/PlatformWebViewIOS.mm:
3392         (-[PlatformWebViewController viewWillTransitionToSize:withTransitionCoordinator:]):
3393         (WTR::PlatformWebView::PlatformWebView):
3394         * WebKitTestRunner/ios/TestControllerIOS.mm:
3395         (WTR::TestController::platformResetStateToConsistentValues):
3396         * WebKitTestRunner/ios/UIScriptControllerIOS.mm:
3397         (WTR::toUIDeviceOrientation):
3398         (WTR::UIScriptController::simulateRotation):
3399         (WTR::UIScriptController::simulateRotationLikeSafari):
3400         (WTR::UIScriptController::platformClearAllCallbacks):
3401         * WebKitTestRunner/mac/UIScriptControllerMac.mm:
3402         (WTR::UIScriptController::simulateRotation):
3403         (WTR::UIScriptController::simulateRotationLikeSafari):
3404
3405 2017-05-05  Jonathan Bedard  <jbedard@apple.com>
3406
3407         Use ImageDiff built by host SDK and remove ImageDiff from DumpRenderTree
3408         https://bugs.webkit.org/show_bug.cgi?id=168945
3409         <rdar://problem/30745695>
3410
3411         Reviewed by David Kilzer.
3412
3413         Use ImageDiff built with the host machine's SDK and stop building ImageDiff with the
3414         target SDK. These two changes must happen simultaneously because some archives will
3415         clobber the ImageDiff from the host SDK with the ImageDiff from the target SDK.
3416
3417         * DumpRenderTree/mac/Configurations/ImageDiff.xcconfig: Remove ImageDiff from project.
3418         * DumpRenderTree/PlatformWin.cmake: Remove ImageDiff. Note that the CMakeLists.txt in the
3419         tools directory still includes ImageDiff.
3420         * DumpRenderTree/cg/ImageDiffCG.cpp: Removed.
3421         * DumpRenderTree/mac/Configurations/DumpRenderTree.xcconfig: Removed.
3422         * Scripts/webkitpy/port/darwin.py: 
3423         (DarwinPort._path_to_image_diff): Return the correct path to ImageDiff when building
3424         locally or when running archives.
3425         * Scripts/webkitpy/port/image_diff.py:
3426         (IOSSimulatorImageDiffer): Deleted.
3427         * Scripts/webkitpy/port/ios_simulator.py:
3428         (IOSSimulatorPort.diff_image): Deleted.
3429
3430 2017-05-05  Brian Burg  <bburg@apple.com>
3431
3432         API test WebKit2.WKHTTPCookieStore fails due to possible issue with handling non-session cookies
3433         https://bugs.webkit.org/show_bug.cgi?id=171748
3434
3435         Unreviewed test gardening.
3436
3437         The assertion failure will be investigated separately in order to avoid rolling out
3438         the fix for "secure" cookies. This assertion fails even without r216258 applied.
3439
3440         * TestWebKitAPI/Tests/WebKit2Cocoa/WKHTTPCookieStore.mm:
3441         (TEST):
3442
3443 2017-05-05  Jonathan Bedard  <jbedard@apple.com>
3444
3445         Unreviewed, rolling out r216260.
3446
3447         Breaks internal iOS testers
3448
3449         Reverted changeset:
3450
3451         "Use ImageDiff built by host SDK and remove ImageDiff from
3452         DumpRenderTree"
3453         https://bugs.webkit.org/show_bug.cgi?id=168945
3454         http://trac.webkit.org/changeset/216260
3455
3456 2017-05-05  Jonathan Bedard  <jbedard@apple.com>
3457
3458         Use ImageDiff built by host SDK and remove ImageDiff from DumpRenderTree
3459         https://bugs.webkit.org/show_bug.cgi?id=168945
3460         <rdar://problem/30745695>
3461
3462         Reviewed by David Kilzer.
3463
3464         Use ImageDiff built with the host machine's SDK and stop building ImageDiff with the
3465         target SDK. These two changes must happen simultaneously because some archives will
3466         clobber the ImageDiff from the host SDK with the ImageDiff from the target SDK.
3467
3468         * DumpRenderTree/mac/Configurations/ImageDiff.xcconfig: Remove ImageDiff from project.
3469         * DumpRenderTree/PlatformWin.cmake: Remove ImageDiff. Note that the CMakeLists.txt in the
3470         tools directory still includes ImageDiff.
3471         * DumpRenderTree/cg/ImageDiffCG.cpp: Removed.
3472         * DumpRenderTree/mac/Configurations/DumpRenderTree.xcconfig: Removed.
3473         * Scripts/webkitpy/port/darwin.py: 
3474         (DarwinPort._path_to_image_diff): Return the correct path to ImageDiff when building
3475         locally or when running archives.
3476         * Scripts/webkitpy/port/image_diff.py:
3477         (IOSSimulatorImageDiffer): Deleted.
3478         * Scripts/webkitpy/port/ios_simulator.py:
3479         (IOSSimulatorPort.diff_image): Deleted.
3480
3481 2017-05-05  Brian Burg  <bburg@apple.com>
3482
3483         [Cocoa] Converting from WebCore::Cookie to NSHTTPCookie always marks cookies as secure
3484         https://bugs.webkit.org/show_bug.cgi?id=171700
3485         <rdar://problem/32017975>
3486
3487         Reviewed by Brady Eidson.
3488
3489         Fix a mistake in the test that should have caught this bug.
3490
3491         * TestWebKitAPI/Tests/WebKit2Cocoa/WKHTTPCookieStore.mm:
3492         (TEST):
3493         The assertions that were meant to check round-tripping were actually checking
3494         the properties of the original cookie objects, not the round-tripped ones.
3495         This test now fails without the bugfix and passes when it is applied.
3496
3497 2017-05-05  Daniel Bates  <dabates@apple.com>
3498
3499         Use EXPECT_EQ() when comparing strings in TestWebKitAPI tests
3500         https://bugs.webkit.org/show_bug.cgi?id=171698
3501
3502         Reviewed by Darin Adler.
3503
3504         We should use EXPECT_EQ() instead of EXPECT_TRUE() to compare WTF::String() objects
3505         so that we get pretty diff output when the actual string differs from the expected
3506         string as opposed to seeing a boolean result. The former makes makes it straightforward
3507         to diagnose a regression without reading the code for the test or instrumenting it to
3508         determine the actual string that was compared.
3509
3510         * TestWebKitAPI/Tests/WTF/WTFString.cpp:
3511         (TestWebKitAPI::TEST):
3512         * TestWebKitAPI/Tests/WebCore/mac/GPUFunction.mm:
3513         (TestWebKitAPI::TEST_F):
3514         * TestWebKitAPI/Tests/WebCore/mac/GPULibrary.mm:
3515         (TestWebKitAPI::TEST_F):
3516
3517 2017-05-05  Chris Dumez  <cdumez@apple.com>
3518
3519         Rename webProcessDidCrashWithReason callback to webProcessDidTerminate and stop calling webProcessDidCrash for client terminations
3520         https://bugs.webkit.org/show_bug.cgi?id=171624
3521
3522         Reviewed by Dan Bernstein.
3523
3524         Extend API test coverage to cover crashes in addition to terminations requested by the client.
3525
3526         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
3527         * TestWebKitAPI/Tests/WebKit2/ProcessDidTerminate.cpp: Renamed from Tools/TestWebKitAPI/Tests/WebKit2/ProcessDidCrashWithReason.cpp.
3528         (TestWebKitAPI::webProcessWasTerminatedByClient):
3529         (TestWebKitAPI::webProcessCrashed):
3530         (TestWebKitAPI::TEST):
3531
3532 2017-05-04  Mark Lam  <mark.lam@apple.com>
3533
3534         DRT's setAudioResultCallback() and IDBRequest::setResult() need to acquire the JSLock.
3535         https://bugs.webkit.org/show_bug.cgi?id=171716
3536         <rdar://problem/30878027>
3537
3538         Reviewed by Saam Barati.
3539
3540         setAudioResultCallback() needs to acquire the JSLock before calling toJS() (which
3541         does JS conversion and therefore, potentially JS allocations) and accessing
3542         methods of internal JS data structures (which may do JS invocation, etc).
3543
3544         * DumpRenderTree/TestRunner.cpp:
3545         (setAudioResultCallback):
3546
3547 2017-05-05  Jonathan Bedard  <jbedard@apple.com>
3548
3549         buildbot: Cleanup simulators after running tests
3550         https://bugs.webkit.org/show_bug.cgi?id=171679
3551         <rdar://problem/31994361>
3552
3553         Reviewed by Aakash Jain.
3554
3555         We shutdown the simulator process between tests, but in some cases, this is not
3556         sufficient. Explicitly shutdown every booted simulator.
3557
3558         * BuildSlaveSupport/kill-old-processes:
3559         (main): Shutdown all booted simulators.
3560
3561 2017-05-05  Carlos Garcia Campos  <cgarcia@igalia.com>
3562
3563         [GTK] Assertion failure in Inspector::RemoteInspector::setRemoteInspectorClient when disposing WebKitWebContext
3564         https://bugs.webkit.org/show_bug.cgi?id=171644
3565
3566         Reviewed by Michael Catanzaro.
3567
3568         Check that only one WebKitWebContext can have automation enabled.
3569
3570         * TestWebKitAPI/Tests/WebKit2Gtk/TestAutomationSession.cpp:
3571         (testAutomationSessionRequestSession):
3572
3573 2017-05-05  Carlos Garcia Campos  <cgarcia@igalia.com>
3574
3575         [GTK] TestController timeout source callback should return G_SOURCE_REMOVE
3576         https://bugs.webkit.org/show_bug.cgi?id=171724
3577
3578         Reviewed by Michael Catanzaro.
3579
3580         It's currently returning CONTINUE which causes it to be called again even if the run loop has been stopped.
3581
3582         * WebKitTestRunner/gtk/TestControllerGtk.cpp:
3583         (WTR::timeoutSource):
3584
3585 2017-05-05  Carlos Garcia Campos  <cgarcia@igalia.com>
3586
3587         Unreviewed. Fix wrong assert after r215176.
3588
3589         Cairo surface received by computeMD5HashStringForCairoSurface() doesn't need to be ARGB32 since r215176, it
3590         could also be RGB24 when created from a web view snapshot.
3591
3592         * WebKitTestRunner/cairo/TestInvocationCairo.cpp:
3593         (WTR::computeMD5HashStringForCairoSurface):
3594
3595 2017-05-04  Brian Burg  <bburg@apple.com>
3596
3597         lldb_webkit.py should provide a type summary for WebCore::URL
3598         https://bugs.webkit.org/show_bug.cgi?id=171670
3599
3600         Reviewed by Jer Noble.
3601
3602         Just print out the underlying string using the WTFString provider.
3603
3604         * lldb/lldb_webkit.py:
3605         (__lldb_init_module):
3606         (WebCoreURL_SummaryProvider):
3607         (WebCoreURLProvider):
3608         (WebCoreURLProvider.__init__):
3609         (WebCoreURLProvider.to_string):
3610
3611 2017-05-04  Commit Queue  <commit-queue@webkit.org>
3612
3613         Unreviewed, rolling out r216206.
3614         https://bugs.webkit.org/show_bug.cgi?id=171714
3615
3616         Multiple LayoutTests crashing in Document::page() (Requested
3617         by ap on #webkit).
3618
3619         Reverted changeset:
3620
3621         "Remove support for legacy Notifications"
3622         https://bugs.webkit.org/show_bug.cgi?id=171487
3623         http://trac.webkit.org/changeset/216206
3624
3625 2017-05-04  Mark Lam  <mark.lam@apple.com>
3626
3627         API test WTF.StaticStringImpl crashing in TestWebKitAPI::WTF_StaticStringImpl_Test::TestBody() + 3188
3628         https://bugs.webkit.org/show_bug.cgi?id=171702
3629
3630         Reviewed by Filip Pizlo.
3631
3632         The test was supposed to use the MAKE_STATIC_STRING_IMPL macro.  I had previously
3633         changed it to instantiate an automatic StaticStringImpl (i.e. stack allocated) to
3634         confirm that the test will detect a regression.  Unfortunately, I forgot to
3635         change it back to using MAKE_STATIC_STRING_IMPL before I landed the test.
3636         This patch fixes that.
3637
3638         * TestWebKitAPI/Tests/WTF/StringImpl.cpp:
3639         (TestWebKitAPI::neverDestroyedString):
3640
3641 2017-05-04  Ryan Haddad  <ryanhaddad@apple.com>
3642
3643         Disable failing API test WebKit2.ResizeWithHiddenContentDoesNotHang.
3644         https://bugs.webkit.org/show_bug.cgi?id=170195
3645
3646         Unreviewed test gardening.
3647
3648         * TestWebKitAPI/Tests/WebKit2Cocoa/AnimatedResize.mm:
3649         (TEST):
3650
3651 2017-05-04  Don Olmstead  <don.olmstead@am.sony.com>
3652
3653         [Win] Remove redundant macros that are set in the CMake config
3654         https://bugs.webkit.org/show_bug.cgi?id=171571
3655
3656         Reviewed by Brent Fulgham.
3657
3658         * DumpRenderTree/config.h:
3659         * MiniBrowser/win/stdafx.h:
3660         * TestWebKitAPI/config.h:
3661
3662 2017-05-04  Said Abou-Hallawa  <sabouhallawa@apple.com>
3663
3664         Add testRunner.display() to force displaying the web page for testing
3665         https://bugs.webkit.org/show_bug.cgi?id=171694
3666
3667         Reviewed by Simon Fraser.
3668
3669         Unlike testRunner.displayAndTrackRepaints(), this new function forces 
3670         drawing the web page but without track repaints.
3671
3672         * DumpRenderTree/TestRunner.cpp:
3673         (displayCallback):
3674         (TestRunner::staticFunctions):
3675         * DumpRenderTree/TestRunner.h:
3676         * DumpRenderTree/mac/TestRunnerMac.mm:
3677         (TestRunner::display):
3678         * DumpRenderTree/win/TestRunnerWin.cpp:
3679         (TestRunner::display):
3680         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
3681         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
3682         (WTR::TestRunner::display):
3683         * WebKitTestRunner/InjectedBundle/TestRunner.h:
3684
3685 2017-05-04  Mark Lam  <mark.lam@apple.com>
3686
3687         NeverDestroyed<String>(ASCIILiteral(...)) is not thread safe.
3688         https://bugs.webkit.org/show_bug.cgi?id=171586
3689         <rdar://problem/31873190>
3690
3691         Reviewed by Yusuke Suzuki.
3692
3693         API test for exercising StaticStringImpl and the MAKE_STATIC_STRING_IMPL macro.
3694
3695         * TestWebKitAPI/Tests/WTF/StringImpl.cpp:
3696         (TestWebKitAPI::neverDestroyedString):
3697         (TestWebKitAPI::getNeverDestroyedStringAtStackDepth):
3698         (TestWebKitAPI::TEST):
3699
3700 2017-05-04  Wenson Hsieh  <wenson_hsieh@apple.com>
3701
3702         [WK2] Add support for keeping the selection in a focused editable element when dragging begins
3703         https://bugs.webkit.org/show_bug.cgi?id=171585
3704         <rdar://problem/31544320>
3705
3706         Reviewed by Beth Dakin and Zalan Bujtas.
3707
3708         Adds 1 new unit test and tweaks existing tests to check that when first responder status is lost after beginning
3709         a drag while editing, content is still moved (and not copied) when performing data interaction on a different
3710         element. ContentEditableMoveParagraphs checks that content can be shifted within a single element via a move
3711         operation rather than a copy.
3712
3713         See WebCore ChangeLog for more details.
3714
3715         Tests:  DataInteractionSimulator.ContentEditableToContentEditable
3716                 DataInteractionSimulator.ContentEditableToTextarea
3717                 DataInteractionSimulator.ContentEditableMoveParagraphs
3718                 DataInteractionSimulator.TextAreaToInput
3719
3720         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
3721         * TestWebKitAPI/Tests/WebKit2Cocoa/two-paragraph-contenteditable.html: Added.
3722         * TestWebKitAPI/Tests/ios/DataInteractionTests.mm:
3723         (TestWebKitAPI::TEST):
3724         * TestWebKitAPI/ios/DataInteractionSimulator.h:
3725         * TestWebKitAPI/ios/DataInteractionSimulator.mm:
3726         (-[DataInteractionSimulator initWithWebView:]):
3727         (-[DataInteractionSimulator dealloc]):
3728         (-[DataInteractionSimulator _advanceProgress]):
3729         (-[DataInteractionSimulator waitForInputSession]):
3730         (-[DataInteractionSimulator _webView:focusShouldStartInputSession:]):
3731         (-[DataInteractionSimulator _webView:didStartInputSession:]):
3732
3733 2017-05-04  Said Abou-Hallawa  <sabouhallawa@apple.com>
3734
3735         Rename TestRunner.display() to TestRunner::displayAndTrackRepaints()
3736         https://bugs.webkit.org/show_bug.cgi?id=171641
3737
3738         Reviewed by Simon Fraser.
3739
3740         The plan is to add back the TestRunner.display() which does the display
3741         only without track repaints.
3742
3743         * DumpRenderTree/DumpRenderTree.h:
3744         * DumpRenderTree/TestRunner.cpp:
3745         (displayAndTrackRepaintsCallback):
3746         (TestRunner::staticFunctions):
3747         (displayCallback): Deleted.
3748         (displayInvalidatedRegionCallback): Deleted.
3749         * DumpRenderTree/TestRunner.h:
3750         * DumpRenderTree/mac/DumpRenderTree.mm:
3751         (displayWebView):
3752         (displayAndTrackRepaintsWebView):
3753         * DumpRenderTree/mac/TestRunnerMac.mm:
3754         (TestRunner::displayAndTrackRepaints):
3755         (TestRunner::display): Deleted.
3756         * DumpRenderTree/win/TestRunnerWin.cpp:
3757         (TestRunner::displayAndTrackRepaints):
3758         (TestRunner::display): Deleted.
3759         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
3760         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
3761         (WTR::TestRunner::displayAndTrackRepaints):
3762         (WTR::TestRunner::display): Deleted.
3763         * WebKitTestRunner/InjectedBundle/TestRunner.h:
3764
3765 2017-05-04  Brady Eidson  <beidson@apple.com>
3766
3767         [ios-simulator] API test WebKit2.WebsiteDataStoreCustomPaths is failing.
3768         https://bugs.webkit.org/show_bug.cgi?id=171513
3769
3770         Unreviewed gardening.
3771
3772         * TestWebKitAPI/Tests/WebKit2Cocoa/WebsiteDataStoreCustomPaths.mm:
3773         (TEST): Skip the failing parts of the test on iOS for now.
3774
3775 2017-05-03  Jonathan Bedard  <jbedard@apple.com>
3776
3777         Make ImageDiff stand-alone
3778         https://bugs.webkit.org/show_bug.cgi?id=168939
3779
3780         Reviewed by David Kilzer.
3781
3782         Create ImageDiff without dependencies on bmalloc and WTF so that it exists as a
3783         stand-alone project. Note that this change does not eliminate the ImageDiff inside
3784         the DumpRenderTree project.
3785
3786         * ImageDiff/ImageDiff.xcodeproj: Added.
3787         * ImageDiff/ImageDiff.xcodeproj/project.pbxproj: Added.
3788         * ImageDiff/Makefile: Use ImageDiff project.
3789         * ImageDiff/PlatformMac.cmake: Added.
3790         * ImageDiff/PlatformWin.cmake: Added.
3791         * ImageDiff/cg: Added.
3792         * ImageDiff/cg/Configurations: Added.
3793         * ImageDiff/cg/Configurations/Base.xcconfig: Copied from Tools/DumpRenderTree/mac/Configurations/Base.xcconfig.
3794         * ImageDiff/cg/Configurations/DebugRelease.xcconfig: Copied from Tools/DumpRenderTree/mac/Configurations/DebugRelease.xcconfig.
3795         * ImageDiff/cg/Configurations/ImageDiff.xcconfig: Copied from Tools/DumpRenderTree/mac/Configurations/ImageDiff.xcconfig.
3796         * ImageDiff/cg/ImageDiff.cpp: Copied from Tools/DumpRenderTree/cg/ImageDiffCG.cpp.
3797         (createImageFromStdin): Stop using RetainPtr.
3798         (createDifferenceImage): Ditto.
3799         (main): Ditto.
3800         * Scripts/build-imagediff: Stop building WTF and bmalloc.
3801
3802 2017-05-04  Sam Weinig  <sam@webkit.org>
3803
3804         Remove support for legacy Notifications
3805         https://bugs.webkit.org/show_bug.cgi?id=171487
3806
3807         Reviewed by Jon Lee.
3808
3809         * DumpRenderTree/win/DRTDesktopNotificationPresenter.cpp:
3810         (DRTDesktopNotificationPresenter::checkNotificationPermission):
3811         * Scripts/webkitperl/FeatureList.pm:
3812         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
3813         Remove use and definition of ENABLE_LEGACY_NOTIFICATIONS.
3814
3815 2017-05-04  Andy Estes  <aestes@apple.com>
3816
3817         Give +testwebkitapi_configurationWithTestPlugInClassName: a shorter name
3818         https://bugs.webkit.org/show_bug.cgi?id=171673
3819
3820         Reviewed by Dan Bernstein.
3821
3822         * TestWebKitAPI/Tests/WebKit2Cocoa/AdditionalReadAccessAllowedURLs.mm:
3823         (TEST):
3824         * TestWebKitAPI/Tests/WebKit2Cocoa/BundleEditingDelegate.mm:
3825         (TEST):
3826         * TestWebKitAPI/Tests/WebKit2Cocoa/BundleParameters.mm:
3827         (TEST):
3828         * TestWebKitAPI/Tests/WebKit2Cocoa/BundleRangeHandle.mm:
3829         (TEST):
3830         * TestWebKitAPI/Tests/WebKit2Cocoa/CancelFontSubresource.mm:
3831         (TEST):
3832         * TestWebKitAPI/Tests/WebKit2Cocoa/ContentFiltering.mm:
3833         (configurationWithContentFilterSettings):
3834         (-[LazilyLoadPlatformFrameworksController init]):
3835         * TestWebKitAPI/Tests/WebKit2Cocoa/RemoteObjectRegistry.mm:
3836         (TEST):
3837         * TestWebKitAPI/Tests/WebKit2Cocoa/RenderedImageWithOptions.mm:
3838         (runTestWithWidth):
3839         * TestWebKitAPI/Tests/WebKit2Cocoa/UserContentWorld.mm:
3840         (TEST):
3841         * TestWebKitAPI/Tests/ios/DataInteractionTests.mm:
3842         (TestWebKitAPI::TEST):
3843         * TestWebKitAPI/WKWebViewConfigurationExtras.h:
3844         * TestWebKitAPI/WKWebViewConfigurationExtras.mm:
3845         (+[WKWebViewConfiguration _test_configurationWithTestPlugInClassName:]):
3846         (+[WKWebViewConfiguration testwebkitapi_configurationWithTestPlugInClassName:]): Renamed to
3847         +_test_configurationWithTestPlugInClassName:
3848
3849 2017-05-04  Eric Carlson  <eric.carlson@apple.com>
3850
3851         [MediaStream] Allow host application to enable/disable media capture
3852         https://bugs.webkit.org/show_bug.cgi?id=171292
3853         <rdar://problem/31821492>
3854
3855         Reviewed by Jer Noble.
3856
3857         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
3858         * TestWebKitAPI/Tests/WebKit2Cocoa/UserMediaDisabled.mm: Added.
3859         (-[UserMediaMessageHandler userContentController:didReceiveScriptMessage:]):
3860         (-[UserMediaUIDelegate _webView:requestUserMediaAuthorizationForDevices:url:mainFrameURL:decisionHandler:]):
3861         (-[UserMediaUIDelegate _webView:checkUserMediaPermissionForURL:mainFrameURL:frameIdentifier:decisionHandler:]):
3862         (MediaCaptureDisabledTest::SetUp):
3863         (MediaCaptureDisabledTest::loadTestAndWaitForMessage):
3864         (TEST_F):
3865         * TestWebKitAPI/Tests/WebKit2Cocoa/disableGetUserMedia.html: Added.
3866
3867 2017-05-04  Caio Lima  <ticaiolima@gmail.com>
3868
3869         Unreviewed, Adding self to contributors.json
3870
3871         * Scripts/webkitpy/common/config/contributors.json: Added name.
3872
3873 2017-05-04  Konstantin Tokarev  <annulen@yandex.ru>
3874
3875         Fix compilation with ICU 59.1
3876         https://bugs.webkit.org/show_bug.cgi?id=171612
3877
3878         Reviewed by Mark Lam.
3879
3880         ICU 59.1 has broken source compatibility. Now it defines UChar as
3881         char16_t, which does not allow automatic type conversion from unsigned
3882         short in C++ code.
3883
3884         * TestRunnerShared/UIScriptContext/UIScriptContext.cpp:
3885         (UIScriptContext::tryToCompleteUIScriptForCurrentParentCallback):
3886
3887 2017-05-04  Andy Estes  <aestes@apple.com>
3888
3889         [Cocoa] Add an optional width parameter to -[WKWebProcessPlugInNodeHandle renderedImageWithOptions:]
3890         https://bugs.webkit.org/show_bug.cgi?id=171646
3891         <rdar://problem/30306321>
3892
3893         Reviewed by Tim Horton.
3894
3895         * TestWebKitAPI/Tests/WebKit2Cocoa/RenderedImageWithOptions.mm:
3896         (runTestWithWidth):
3897         (TEST):
3898         (-[RenderedImageWithOptionsObject didRenderImageWithSize:]): Deleted.
3899         * TestWebKitAPI/Tests/WebKit2Cocoa/RenderedImageWithOptionsPlugIn.mm:
3900         (-[RenderedImageWithOptionsPlugIn webProcessPlugIn:didCreateBrowserContextController:]):
3901         (-[RenderedImageWithOptionsPlugIn webProcessPlugInBrowserContextController:didFinishLoadForFrame:]):
3902         (-[RenderedImageWithOptionsPlugIn renderImageWithWidth:completionHandler:]):
3903         * TestWebKitAPI/Tests/WebKit2Cocoa/RenderedImageWithOptionsProtocol.h:
3904
3905 2017-05-04  Adrian Perez de Castro  <aperez@igalia.com>
3906
3907         [GTK] Fontconfig 2.11.2 in JHBuild does not build with glibc 2.25+ or gperf 3.1+
3908         https://bugs.webkit.org/show_bug.cgi?id=171649
3909
3910         Reviewed by Carlos Garcia Campos.
3911
3912         Add two patches picked from the upstream repository to fix building of
3913         the Fontconfig module in JHBuild. Additionally, this needed a patch to
3914         add "autogen.sh" as it is not included in release tarballs. Also:
3915         building the module with srcdir!=builddir prevents "fcobjshash.gperf"
3916         being regenerated (which is needed) so this is disabled for the
3917         Fontconfig module.
3918
3919         * gtk/jhbuild.modules:
3920         * gtk/patches/fontconfig-2.11.1-add-autogen.patch: Added.
3921         * gtk/patches/fontconfig-Avoid-conflicts-with-integer-width-macros-from-TS-18661-1-2014.patch: Added.
3922         * gtk/patches/fontconfig-Fix-the-build-issue-with-gperf-3.1.patch: Added.
3923
3924 2017-05-04  Commit Queue  <commit-queue@webkit.org>
3925
3926         Unreviewed, rolling out r216172.
3927         https://bugs.webkit.org/show_bug.cgi?id=171654
3928
3929         FTBFS for iOS due to missing WebPageProxy::stopMediaCapture()
3930         implementation. (Requested by ddkilzer on #webkit).
3931
3932         Reverted changeset:
3933
3934         "[MediaStream] Allow host application to enable/disable media
3935         capture"
3936         https://bugs.webkit.org/show_bug.cgi?id=171292
3937         http://trac.webkit.org/changeset/216172
3938
3939 2017-05-04  Carlos Garcia Campos  <cgarcia@igalia.com>
3940
3941         [GTK] Bump GStreamer version to 1.10.4 in jhbuild
3942         https://bugs.webkit.org/show_bug.cgi?id=171595
3943
3944         Reviewed by Xabier Rodriguez-Calvar.
3945
3946         * gtk/jhbuild.modules:
3947         * gtk/patches/gst-plugins-bad-0001-dtls-port-to-OpenSSL-1.1.0.patch: Removed.
3948         * gtk/patches/gst-plugins-bad-0002-dtlscertificate-Fix-error-checking-in-RSA_generate_k.patch: Removed.
3949         * gtk/patches/gst-plugins-good-0001-rtpbin-pipeline-gets-an-EOS-when-any-rtpsources-byes.patch: Removed.
3950         * gtk/patches/gst-plugins-good-0002-rtpbin-avoid-generating-errors-when-rtcp-messages-ar.patch: Removed.
3951         * gtk/patches/gst-plugins-good-0004-qtdemux-add-context-for-a-preferred-protection.patch:
3952         * gtk/patches/gst-plugins-good-Revert-qtdemux-expose-streams-with-first-moof-for-fr.patch: Removed.
3953         * gtk/patches/gst-plugins-good-use-the-tfdt-decode-time.patch: Removed.
3954
3955 2017-05-03  Saam Barati  <sbarati@apple.com>
3956
3957         How we build polymorphic cases is wrong when making a call from Wasm
3958         https://bugs.webkit.org/show_bug.cgi?id=171527
3959
3960         Reviewed by JF Bastien.
3961
3962         * Scripts/run-jsc-stress-tests:
3963
3964 2017-05-03  Eric Carlson  <eric.carlson@apple.com>
3965
3966         [MediaStream] Allow host application to enable/disable media capture
3967         https://bugs.webkit.org/show_bug.cgi?id=171292
3968         <rdar://problem/31821492>
3969
3970         Reviewed by Jer Noble.
3971
3972         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
3973         * TestWebKitAPI/Tests/WebKit2Cocoa/UserMediaDisabled.mm: Added.
3974         (-[UserMediaMessageHandler userContentController:didReceiveScriptMessage:]):
3975         (-[UserMediaUIDelegate _webView:requestUserMediaAuthorizationForDevices:url:mainFrameURL:decisionHandler:]):
3976         (-[UserMediaUIDelegate _webView:checkUserMediaPermissionForURL:mainFrameURL:frameIdentifier:decisionHandler:]):
3977         (MediaCaptureDisabledTest::SetUp):
3978         (MediaCaptureDisabledTest::loadTestAndWaitForMessage):
3979         (TEST_F):
3980         * TestWebKitAPI/Tests/WebKit2Cocoa/disableGetUserMedia.html: Added.
3981
3982 2017-05-03  John Wilander  <wilander@apple.com>
3983
3984         Resource Load Statistics: Remove all statistics for modifiedSince website data removals
3985         https://bugs.webkit.org/show_bug.cgi?id=171584
3986         <rdar://problem/24702576>
3987
3988         Reviewed by Brent Fulgham.
3989
3990         New function to call the clear function that takes a modifiedSince parameter.
3991
3992         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
3993         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
3994         (WTR::TestRunner::statisticsClearInMemoryAndPersistentStoreModifiedSinceHours):
3995         * WebKitTestRunner/InjectedBundle/TestRunner.h:
3996         * WebKitTestRunner/TestController.cpp:
3997         (WTR::TestController::statisticsClearInMemoryAndPersistentStoreModifiedSinceHours):
3998         * WebKitTestRunner/TestController.h:
3999         * WebKitTestRunner/TestInvocation.cpp:
4000         (WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):
4001
4002 2017-05-03  Commit Queue  <commit-queue@webkit.org>
4003
4004         Unreviewed, rolling out r216160 and r216161.
4005         https://bugs.webkit.org/show_bug.cgi?id=171640
4006
4007         These changes broke the iOS build. (Requested by mlewis13 on
4008         #webkit).
4009
4010         Reverted changesets:
4011
4012         "[MediaStream] Allow host application to enable/disable media
4013         capture"
4014         https://bugs.webkit.org/show_bug.cgi?id=171292
4015         http://trac.webkit.org/changeset/216160
4016
4017         "[MediaStream] Allow host application to enable/disable media
4018         capture"
4019         https://bugs.webkit.org/show_bug.cgi?id=171292
4020         http://trac.webkit.org/changeset/216161
4021
4022 2017-05-03  Eric Carlson  <eric.carlson@apple.com>
4023
4024         [MediaStream] Allow host application to enable/disable media capture
4025         https://bugs.webkit.org/show_bug.cgi?id=171292
4026         <rdar://problem/31821492>
4027
4028         Reviewed by Jer Noble.
4029
4030         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
4031         * TestWebKitAPI/Tests/WebKit2Cocoa/UserMediaDisabled.mm: Added.
4032         (-[UserMediaMessageHandler userContentController:didReceiveScriptMessage:]):
4033         (-[UserMediaUIDelegate _webView:requestUserMediaAuthorizationForDevices:url:mainFrameURL:decisionHandler:]):
4034         (-[UserMediaUIDelegate _webView:checkUserMediaPermissionForURL:mainFrameURL:frameIdentifier:decisionHandler:]):
4035         (MediaCaptureDisabledTest::SetUp):
4036         (MediaCaptureDisabledTest::loadTestAndWaitForMessage):
4037         (TEST_F):
4038         * TestWebKitAPI/Tests/WebKit2Cocoa/disableGetUserMedia.html: Added.
4039
4040 2017-04-26  Jiewen Tan  <jiewen_tan@apple.com>
4041
4042         [WebCrypto] Add an api test for testing wrapping/unwrapping serialized crypto keys
4043         https://bugs.webkit.org/show_bug.cgi?id=171350
4044         <rdar://problem/28600836>
4045
4046         Patched by Brady Eidson.
4047
4048         Reviewed by Brent Fulgham.
4049
4050         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
4051         * TestWebKitAPI/Tests/WebKit2/NavigationClientDefaultCrypto.cpp: Added.
4052         (TestWebKitAPI::runJavaScriptAlert):
4053         (TestWebKitAPI::decidePolicyForNavigationAction):
4054         (TestWebKitAPI::decidePolicyForNavigationResponse):
4055         (TestWebKitAPI::TEST):
4056         * TestWebKitAPI/Tests/WebKit2/navigation-client-default-crypto.html: Added.
4057
4058 2017-05-03  Simon Fraser  <simon.fraser@apple.com>
4059
4060         Have WKWebView call _updateVisibleContentRects for the current transaction if possible, rather than always delaying
4061         https://bugs.webkit.org/show_bug.cgi?id=171619
4062         https://bugs.webkit.org/show_bug.cgi?id=170195
4063
4064         Reviewed by Tim Horton.
4065
4066         Re-enable WebKit2.ResizeWithHiddenContentDoesNotHang.
4067
4068         * TestWebKitAPI/Tests/WebKit2Cocoa/AnimatedResize.mm:
4069         (TEST):
4070
4071 2017-05-03  Michael Catanzaro  <mcatanzaro@igalia.com>
4072
4073         YouTube user agent quirk breaks new YouTube
4074         https://bugs.webkit.org/show_bug.cgi?id=171603
4075
4076         Reviewed by Carlos Garcia Campos.
4077
4078         Remove the YouTube quirk test.
4079
4080         * TestWebKitAPI/Tests/WebCore/UserAgentQuirks.cpp:
4081         (TestWebKitAPI::TEST):
4082
4083 2017-05-03  Said Abou-Hallawa  <sabouhallawa@apple.com>
4084
4085         Async image decoding should be disabled for snapshots, printing and preview
4086         https://bugs.webkit.org/show_bug.cgi?id=171467
4087
4088         Reviewed by Simon Fraser.
4089
4090         Add a API test for snapshotting with large images. Ensure the images are
4091         drawn correctly which implies they should have been synchronously decoded.
4092
4093         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
4094         * TestWebKitAPI/Tests/WebKit2/large-red-square-image.html: Added.
4095         * TestWebKitAPI/Tests/WebKit2Cocoa/WKWebViewSnapshot.mm:
4096         (TEST):
4097
4098 2017-05-03  Chris Dumez  <cdumez@apple.com>
4099
4100         [WK2] Extend processDidCrash delegate to let the client know the reason for the crash
4101         https://bugs.webkit.org/show_bug.cgi?id=171565
4102         <rdar://problem/31204417>
4103
4104         Reviewed by Sam Weinig.
4105
4106         Add API test coverage.
4107
4108         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
4109         * TestWebKitAPI/Tests/WebKit2/ProcessDidCrashWithReason.cpp: Added.
4110         (TestWebKitAPI::didFinishNavigation):
4111         (TestWebKitAPI::didCrashWithReason):
4112         (TestWebKitAPI::TEST):
4113
4114 2017-05-02  David Kilzer  <ddkilzer@apple.com>
4115
4116         check-webkit-style should also keep js-test-post[-async].js in sync
4117         <https://webkit.org/b/171568>
4118
4119         Reviewed by Joseph Pecoraro.
4120
4121         * Scripts/webkitpy/style/checker.py:
4122         (_NEVER_SKIPPED_JS_FILES): Add new list that just contains
4123         JavaScript files not to be skipped.
4124         (_NEVER_SKIPPED_FILES): Update to use _NEVER_SKIPPED_JS_FILES.
4125         (CheckerDispatcher._create_checker): Update to use
4126         _NEVER_SKIPPED_JS_FILES.
4127
4128         * Scripts/webkitpy/style/checkers/jstest.py:
4129         (ALL_JS_TEST_FUNCTION_FILES): Rename from ALL_JS_TEST_FILES.
4130         This is the list of files containing functions that need to be
4131         kept in sync.
4132         (KEEP_JS_TEST_FILES_IN_SYNC): Change to list-of-lists format so
4133         we can keep more sets of files in sync between
4134         LayoutTests/resources and LayoutTests/http/tests/resources.
4135         (JSTestChecker.check): Update to use KEEP_JS_TEST_FILES_IN_SYNC
4136         as list of lists.  Update for ALL_JS_TEST_FUNCTION_FILES rename.
4137         (JSTestChecker.check_js_test_files): Add 'file_group' argument
4138         for list of files to check instead of using
4139         KEEP_JS_TEST_FILES_IN_SYNC.
4140         (JSTestChecker.check_js_test_functions): Update for
4141         ALL_JS_TEST_FUNCTION_FILES rename.
4142
4143         * Scripts/webkitpy/style/checkers/jstest_unittest.py:
4144         (JSTestCheckerTestCase):
4145         (JSTestCheckerTestCase.test_map_functions_to_dict):
4146         - Add test case for map_functions_to_dict() in jstest.py.
4147
4148 2017-05-02  Aakash Jain  <aakash_jain@apple.com>
4149
4150         ews should indicate in logs when it fails to fetch the attachment
4151         https://bugs.webkit.org/show_bug.cgi?id=171583
4152
4153         Reviewed by Alexey Proskuryakov.
4154
4155         * Scripts/webkitpy/common/net/bugzilla/bugzilla.py:
4156         (Bugzilla.fetch_attachment): Added log statement.
4157
4158 2017-05-02  David Kilzer  <ddkilzer@apple.com>
4159
4160         Rolling out jstest_unittest.py so it can be reviewed
4161
4162         Follow-up fix for:
4163         check-webkit-style should keep JavaScript test functions in sync
4164         <https://webkit.org/b/171424>
4165
4166         * Scripts/webkitpy/style/checkers/jstest_unittest.py: Remove.
4167
4168 2017-05-02  David Kilzer  <ddkilzer@apple.com>
4169
4170         check-webkit-style should keep JavaScript test functions in sync
4171         <https://webkit.org/b/171424>
4172
4173         Reviewed by Joseph Pecoraro.
4174
4175         Add a new JSTestChecker for check-webkit-style that keeps these
4176         two files in sync:
4177
4178             LayoutTests/http/tests/resources/js-test-pre.js
4179             LayoutTests/resources/js-test-pre.js
4180
4181         And keeps implementations of shouldBe(), shouldNotBe(),
4182         shouldNotThrow(), and shouldThrow() in sync across multiple
4183         files (with the ability to add more functions later):
4184
4185             JSTests/stress/resources/standalone-pre.js
4186             LayoutTests/http/tests/resources/js-test-pre.js
4187             LayoutTests/resources/js-test-pre.js
4188             LayoutTests/resources/js-test.js
4189             LayoutTests/resources/standalone-pre.js
4190
4191         * Scripts/webkitpy/style/checker.py: Remove unused import.  Add
4192         import for JSTestChecker.
4193         (_NEVER_SKIPPED_FILES): Add array of file names that are never
4194         skipped regardless of other rules.
4195         (_all_categories): Add JSTestChecker categories.
4196         (CheckerDispatcher.should_skip_without_warning): Use
4197         _NEVER_SKIPPED_FILES.
4198         (CheckerDispatcher._create_checker): Return JSTestChecker for
4199         the files to check.
4200
4201         * Scripts/webkitpy/style/checkers/jstest.py: Add.
4202         (map_functions_to_dict): Parse JavaScript source by splitting on
4203         /^function\s+/ regex.  This is good enough for the sanity checks
4204         to keep function implementations in sync.
4205         (strip_blank_lines_and_comments): Strips blank lines and lines
4206         with comments from the end of a chunk of text representing a
4207         function.
4208         (JSTestChecker): New checker.
4209         (JSTestChecker.__init__):
4210         (JSTestChecker.check):
4211         (JSTestChecker.check_js_test_files): Keeps whole files in sync.
4212         (JSTestChecker.check_js_test_functions): Keeps individual
4213         functions in sync.
4214
4215         * Scripts/webkitpy/style/checkers/jstest_unittest.py: Add test
4216         case.
4217         (JSTestTestCase):
4218         (JSTestTestCase.test_map_functions_to_dict):
4219
4220 2017-05-02  Joanmarie Diggs  <jdiggs@igalia.com>
4221
4222         AX: Update implementation of aria-orientation
4223         https://bugs.webkit.org/show_bug.cgi?id=171166
4224
4225         Reviewed by Chris Fleizach.
4226
4227         Return "AXUnknownOrientation" when ATK_STATE_VERTICAL and ATK_STATE_HORIZONTAL
4228         are both absent from the state set. Before we were returning an empty string
4229         which was not consistent with what the Mac port does, thus making shared tests
4230         harder.
4231
4232         * WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
4233         (WTR::AccessibilityUIElement::orientation):
4234
4235 2017-05-01  David Kilzer  <ddkilzer@apple.com>
4236
4237         Stop using sprintf() in JavaScriptCore debugger
4238         <https://webkit.org/b/171512>
4239
4240         Reviewed by Keith Miller.
4241
4242         * Scripts/webkitpy/style/checker.py:
4243         (_PATH_RULES_SPECIFIER): Ignore some formatting checkers since
4244         Source/JavaScriptCore/disassembler/udis86/ is generated code.
4245
4246 2017-05-01  Timothy Horton  <timothy_horton@apple.com>
4247
4248         Expose viewport-fit instead of clip-to-safe-area
4249         https://bugs.webkit.org/show_bug.cgi?id=171503
4250         <rdar://problem/31918249>
4251
4252         Reviewed by Simon Fraser.
4253
4254         * DumpRenderTree/ios/UIScriptControllerIOS.mm:
4255         (WTR::UIScriptController::setSafeAreaInsets):
4256         (WTR::UIScriptController::setObscuredInsets): Deleted.
4257         * TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
4258         * TestRunnerShared/UIScriptContext/UIScriptController.cpp:
4259         (WTR::UIScriptController::setSafeAreaInsets):
4260         (WTR::UIScriptController::setObscuredInsets): Deleted.
4261         * TestRunnerShared/UIScriptContext/UIScriptController.h:
4262         * WebKitTestRunner/cocoa/TestRunnerWKWebView.h:
4263         * WebKitTestRunner/cocoa/TestRunnerWKWebView.mm:
4264         (-[TestRunnerWKWebView setOverrideSafeAreaInsets:]):
4265         (-[TestRunnerWKWebView _safeAreaInsetsForFrame:inSuperview:]):
4266         * WebKitTestRunner/ios/TestControllerIOS.mm:
4267         (WTR::TestController::platformResetStateToConsistentValues):
4268         * WebKitTestRunner/ios/UIKitSPI.h:
4269         * WebKitTestRunner/ios/UIScriptControllerIOS.mm:
4270         (WTR::UIScriptController::setSafeAreaInsets):