WorkQueueGeneric's platformInvalidate() can deadlock when called on the RunLoop's...
[WebKit-https.git] / Tools / ChangeLog
1 2017-01-03  Yusuke Suzuki  <utatane.tea@gmail.com>
2
3         WorkQueueGeneric's platformInvalidate() can deadlock when called on the RunLoop's thread
4         https://bugs.webkit.org/show_bug.cgi?id=166645
5
6         Reviewed by Carlos Garcia Campos.
7
8         * TestWebKitAPI/Tests/WTF/WorkQueue.cpp:
9         (TestWebKitAPI::TEST):
10
11 2017-01-03  Andy Estes  <aestes@apple.com>
12
13         Place all the Cocoa WebCore API tests in the same directory
14         https://bugs.webkit.org/show_bug.cgi?id=166673
15
16         Reviewed by Michael Catanzaro.
17
18         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
19         * TestWebKitAPI/Tests/WebCore/cocoa/SerializedCryptoKeyWrap.mm: Renamed from Tools/TestWebKitAPI/Tests/WebCore/SerializedCryptoKeyWrap.mm.
20         * TestWebKitAPI/Tests/WebCore/cocoa/URLExtras.mm: Renamed from Tools/TestWebKitAPI/Tests/Cocoa/URLExtras.mm.
21         * TestWebKitAPI/Tests/WebCore/cocoa/WebCoreNSURLSession.mm: Renamed from Tools/TestWebKitAPI/Tests/WebCore/WebCoreNSURLSession.mm.
22
23 2017-01-03  Tim Horton  <timothy_horton@apple.com>
24
25         NSSpellChecker's recordResponse isn't called for unseen automatic corrections
26         https://bugs.webkit.org/show_bug.cgi?id=166450
27         <rdar://problem/29447824>
28
29         Reviewed by Darin Adler.
30
31         * DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj:
32         * DumpRenderTree/TestRunner.cpp:
33         (TestRunner::staticFunctions):
34         * DumpRenderTree/mac/TestRunnerMac.mm:
35         (setSpellCheckerLoggingEnabledCallback):
36         * DumpRenderTree/win/TestRunnerWin.cpp:
37         (setSpellCheckerLoggingEnabledCallback):
38         * DumpRenderTree/mac/DumpRenderTree.mm:
39         (resetWebViewToConsistentStateBeforeTesting):
40         * DumpRenderTree/mac/DumpRenderTreeSpellChecker.h: Added.
41         * DumpRenderTree/mac/DumpRenderTreeSpellChecker.mm: Added.
42         (stringForCorrectionResponse):
43         (drt_NSSpellChecker_recordResponseToCorrection):
44         (swizzleNSSpellCheckerMethodsIfNeeded):
45         (setSpellCheckerLoggingEnabled):
46         Add a new testRunner method, setSpellCheckerLoggingEnabled, which, when
47         set to true, logs to stdout (which ends up in the test result) whenever
48         NSSpellChecker recordResponse:toCorrection:forWord:language:inSpellDocumentWithTag:
49         is called, and then calls the original method. It is reset to false between tests.
50
51 2017-01-03  Sam Weinig  <sam@webkit.org>
52
53         Make WTF::Expected support Ref template parameters
54         https://bugs.webkit.org/show_bug.cgi?id=166662
55
56         Reviewed by Alex Christensen.
57
58         * TestWebKitAPI/Tests/WTF/Expected.cpp:
59         (TestWebKitAPI::TEST):
60         Add tests for using Ref with Expected.
61
62 2017-01-03  Michael Catanzaro  <mcatanzaro@igalia.com>
63
64         [GTK] Expose WebKitSecurityOrigin API
65         https://bugs.webkit.org/show_bug.cgi?id=166632
66
67         Reviewed by Carlos Garcia Campos.
68
69         * TestWebKitAPI/Tests/WebKit2Gtk/CMakeLists.txt:
70         * TestWebKitAPI/Tests/WebKit2Gtk/TestWebKitSecurityOrigin.cpp: Added.
71         (testSecurityOriginBasicConstructor):
72         (testSecurityOriginURIConstructor):
73         (testSecurityOriginDefaultPort):
74         (testSecurityOriginFileURI):
75         (testSecurityOriginDataURI):
76         (beforeAll):
77         (afterAll):
78
79 2017-01-03  Carlos Garcia Campos  <cgarcia@igalia.com>
80
81         [GTK] HTTP auth layout tests are flaky
82         https://bugs.webkit.org/show_bug.cgi?id=158919
83
84         Reviewed by Michael Catanzaro.
85
86         * gtk/jhbuild.modules: Update libsoup to version 2.57.1.
87         * gtk/jhbuildrc: Stop passing --enable-introspection unconditionally to all modules. We don't really need
88         introspection for the dependencies in the internal build, and it makes newer libsoup build fail because of
89         missing valac in the bots.
90
91 2017-01-03  Carlos Garcia Campos  <cgarcia@igalia.com>
92
93         REGRESSION(r173753): [GTK] Source/WebKit is distributed in tarballs
94         https://bugs.webkit.org/show_bug.cgi?id=165797
95
96         Reviewed by Michael Catanzaro.
97
98         Move directory ruleset after all exclude rules of Source rulset.
99
100         * gtk/manifest.txt.in:
101
102 2017-01-02  Yusuke Suzuki  <utatane.tea@gmail.com>
103
104         Leverage Substring to create new AtomicStringImpl for StaticStringImpl and SymbolImpl
105         https://bugs.webkit.org/show_bug.cgi?id=166636
106
107         Reviewed by Darin Adler.
108
109         * TestWebKitAPI/Tests/WTF/StringImpl.cpp:
110         (TestWebKitAPI::TEST):
111
112 2017-01-02  Manuel Rego Casasnovas  <rego@igalia.com>
113
114         [GTK] WebCore/CSSParser unit test is not being built
115         https://bugs.webkit.org/show_bug.cgi?id=166492
116
117         Reviewed by Michael Catanzaro.
118
119         This test was introduced in r175930, but we were not building
120         it on GTK+ port since r176015.
121         This patch marks the test to be built again on GTK+.
122         JFTR, the test is passing right now.
123
124         * TestWebKitAPI/PlatformGTK.cmake: Add CSSParser.cpp test file and use
125         ADD_WHOLE_ARCHIVE_TO_LIBRARIES to avoid linking errors.
126
127 2017-01-02  Chris Fleizach  <cfleizach@apple.com>
128
129         AX: Expose block quote level to iOS API
130         https://bugs.webkit.org/show_bug.cgi?id=166629
131         <rdar://problem/29834793>
132
133         Reviewed by Darin Adler.
134
135         * DumpRenderTree/ios/AccessibilityUIElementIOS.mm:
136         (AccessibilityUIElement::numberAttributeValue):
137         * WebKitTestRunner/InjectedBundle/ios/AccessibilityUIElementIOS.mm:
138         (WTR::AccessibilityUIElement::numberAttributeValue):
139
140 2016-12-31  Michael Catanzaro  <mcatanzaro@igalia.com>
141
142         SecurityOrigin::create triplet constructor does not canonicalize port
143         https://bugs.webkit.org/show_bug.cgi?id=166624
144
145         Reviewed by Daniel Bates.
146
147         * TestWebKitAPI/PlatformGTK.cmake:
148         * TestWebKitAPI/PlatformWin.cmake:
149         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
150         * TestWebKitAPI/Tests/WebCore/SecurityOrigin.cpp: Added.
151         (TestWebKitAPI::SecurityOriginTest::SetUp):
152         (TestWebKitAPI::TEST_F):
153
154 2016-12-30  Michael Catanzaro  <mcatanzaro@igalia.com>
155
156         [GTK] Improve user agent construction
157         https://bugs.webkit.org/show_bug.cgi?id=142074
158
159         Reviewed by Carlos Garcia Campos.
160
161         * TestWebKitAPI/Tests/WebCore/UserAgentQuirks.cpp:
162         (TestWebKitAPI::assertUserAgentForURLHasChromeBrowserQuirk):
163         (TestWebKitAPI::assertUserAgentForURLHasFirefoxBrowserQuirk):
164         (TestWebKitAPI::assertUserAgentForURLHasLinuxPlatformQuirk):
165         (TestWebKitAPI::assertUserAgentForURLHasMacPlatformQuirk):
166         (TestWebKitAPI::TEST):
167
168 2016-12-27  Michael Catanzaro  <mcatanzaro@igalia.com>
169
170         [GTK] Improve user agent construction
171         https://bugs.webkit.org/show_bug.cgi?id=142074
172
173         Reviewed by Carlos Garcia Campos.
174
175         * TestWebKitAPI/Tests/WebCore/UserAgentQuirks.cpp:
176         (TestWebKitAPI::TEST):
177
178 2016-12-23  Simon Fraser  <simon.fraser@apple.com>
179
180         REGRESSION (r209299): Selection is broken when you zoom in webpage using trackpad
181         https://bugs.webkit.org/show_bug.cgi?id=166472
182         rdar://problem/29675551
183
184         Reviewed by Tim Horton.
185
186         These changes are necessary to allow the mouse to leave the WTR window while
187         drag-scrolling, to test autoscroll. Previously, we were never calling -mouseDragged
188         (which DRT does); we'd always go through mouseMoved, which hits an early return
189         in WebViewImpl::mouseMoved() when the point is outside the view.
190
191         * WebKitTestRunner/mac/EventSenderProxy.mm:
192         (WTR::EventSenderProxy::mouseMoveTo):
193
194 2016-12-23  Andy Estes  <aestes@apple.com>
195
196         [iOS] Fix some crashing webarchive tests
197         https://bugs.webkit.org/show_bug.cgi?id=166470
198
199         Reviewed by Andreas Kling.
200
201         Tests that use TestRunner.dumpDOMAsWebArchive() crashed on iOS due to a stub implementation
202         of WebArchiveDumpSupport in WebKitTestRunner. The Mac implementation works fine on iOS too,
203         so this change uses that on both platforms.
204
205         * WebKitTestRunner/Configurations/InjectedBundle.xcconfig: Removed
206         WebArchiveDumpSupportMac.mm from EXCLUDED_SOURCE_FILE_NAMES.
207         * WebKitTestRunner/InjectedBundle/cocoa/WebArchiveDumpSupportCocoa.mm: Renamed from
208         Tools/WebKitTestRunner/mac/WebArchiveDumpSupportMac.mm.
209         * WebKitTestRunner/PlatformMac.cmake:
210         * WebKitTestRunner/WebKitTestRunner.xcodeproj/project.pbxproj:
211         * WebKitTestRunner/ios/WebArchiveDumpSupportIOS.mm: Removed.
212
213 2016-12-22  Saam Barati  <sbarati@apple.com>
214
215         WebAssembly: Silence the output of the spec-tests
216         https://bugs.webkit.org/show_bug.cgi?id=166417
217
218         Reviewed by Mark Lam.
219
220         * Scripts/run-jsc-stress-tests:
221
222 2016-12-22  Zhuo Li  <zachli@apple.com>
223
224         [Cocoa] SPI for setloadsImagesAutomatically.
225         https://bugs.webkit.org/show_bug.cgi?id=166401.
226
227         Reviewed by Darin Adler.
228
229         * TestWebKitAPI/Tests/WebKit2Cocoa/Preferences.mm:
230         (TEST): Test the _setLoadsImagesAutomatically SPI. By default,
231         _loadsImagesAutomatically returns YES.
232
233 2016-12-22  Wenson Hsieh  <wenson_hsieh@apple.com>
234
235         fast/events/ios/viewport-shrink-to-fit-allows-double-tap.html is flaky/order dependent
236         https://bugs.webkit.org/show_bug.cgi?id=161328
237         <rdar://problem/28475977>
238
239         Reviewed by Darin Adler.
240
241         Running a test that scales the viewport and listens to a didEndZooming callback (such as
242         viewport-shrink-to-fit-allows-double-tap.html) immediately after a test that may begin to trigger viewport
243         scaling as the test completes (such as viewport-device-width-at-initial-scale-fast-clicks.html) may result in
244         the didEndZooming callback of the latter test being fired early due to the previous test triggering a zoom
245         animation. Ideally, -[WKScrollView _stopScrollingAndZoomingAnimations], which is called when committing the page
246         load, should prevent this from happening, but from reading documentation and code inspection, this is not
247         intended to fire any associated delegate methods or notifications of the UIScrollView, instead deferring them
248         for later. Instead, what we need in this case is to clear out any started but not yet completed animations after
249         we finish running a test and before we load the next test.
250
251         One way to do this is to remove all animations from the WKScrollView's layer, and the layers of its children,
252         recursively. Doing so causes scrollViewDidEndZooming:withView:atScale: to fire at the end of the runloop if the
253         previous test started zooming and then finished before zooming completed. Since this happens before the next
254         test has a chance to run UI-side scripts, we won't end up firing this callback prematurely during the next test.
255
256         * WebKitTestRunner/ios/TestControllerIOS.mm:
257         (WTR::TestController::platformResetStateToConsistentValues):
258
259 2016-12-22  Jer Noble  <jer.noble@apple.com>
260
261         Muted media element playback should not interrupt other audio playback
262         https://bugs.webkit.org/show_bug.cgi?id=166347
263
264         Reviewed by Eric Carlson.
265
266         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
267         * TestWebKitAPI/Tests/WebKit/ios/AudioSessionCategoryIOS.mm:
268         (TestWebKitAPI::TEST):
269         * TestWebKitAPI/Tests/WebKit/ios/video-with-muted-audio.html: Added.
270
271 2016-12-22  Alejandro G. Castro  <alex@igalia.com>
272
273         [WebRTC] Add support for runtime PeeConnection setting, required after r209757
274         https://bugs.webkit.org/show_bug.cgi?id=166346
275
276         Reviewed by Carlos Garcia Campos.
277
278         Enable WebRTC by default to simplify testing.
279
280         * MiniBrowser/gtk/main.c:
281         (main):
282
283 2016-12-21  Alexey Proskuryakov  <ap@apple.com>
284
285         REGRESSION: API test failure: WKWebView.LocalStorageClear
286         https://bugs.webkit.org/show_bug.cgi?id=166032
287         <rdar://problem/29758423>
288
289         Reviewed by Simon Fraser.
290
291         Add an @autoreleasepool around the code that allocates then clears the WKWebView, 
292         to ensure that the view is destroyed before the callback fires.
293
294         * TestWebKitAPI/Tests/WebKit2Cocoa/LocalStorageClear.mm:
295         (TEST):
296
297 2016-12-21  Saam Barati  <sbarati@apple.com>
298
299         WebAssembly: Import spec tests
300         https://bugs.webkit.org/show_bug.cgi?id=166395
301
302         Rubber stamped by Keith Miller.
303
304         * Scripts/run-jsc-stress-tests:
305
306 2016-12-21  Alexey Proskuryakov  <ap@apple.com>
307
308         REGRESSION: API test failure: _WKDownload.OriginatingWebView
309         https://bugs.webkit.org/show_bug.cgi?id=166033
310         <rdar://problem/29758428>
311
312         Reviewed by Simon Fraser.
313
314         Add an @autoreleasepool around the code that allocates the WKWebView, 
315         so that it can be destroyed by removing the last reference in _downloadDidStart.
316
317         * TestWebKitAPI/Tests/WebKit2Cocoa/Download.mm:
318         (TEST):
319
320 2016-12-21  Daniel Bates  <dabates@apple.com>
321
322         WebKitTestRunner: Add comment to TestRunner::setCanOpenWindows()
323         https://bugs.webkit.org/show_bug.cgi?id=166356
324
325         Add comment in TestRunner::setCanOpenWindows() to elaborate further on its purpose
326         as a means to allow a test to explicit allow an embedding client to open a new windows
327         such that the default behavior is for the embedding client to forbid such an action.
328         The test plugins/get-url-with-blank-target.html assumes this default behavior though
329         it is currently skipped on WebKit2 because questions were raised in the patch for
330         <https://bugs.webkit.org/show_bug.cgi?id=43389> about its correctness and usefulness.
331         We will need to implement TestRunner::setCanOpenWindows() should we decide to unskip
332         this test.
333
334         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
335         (WTR::TestRunner::setCanOpenWindows):
336
337 2016-12-20  Simon Fraser  <simon.fraser@apple.com>
338
339         REGRESSION: API test failure: WKWebView.EvaluateJavaScriptBlockCrash
340         https://bugs.webkit.org/show_bug.cgi?id=166031
341
342         Reviewed by Tim Horton.
343         
344         Add an @autoreleasepool around the code that allocates then clears the WKWebView, 
345         to ensure that the view is destroyed before the callback fires.
346
347         * TestWebKitAPI/Tests/WebKit2Cocoa/WKWebViewEvaluateJavaScript.mm:
348
349 2016-12-20  Megan Gardner  <megan_gardner@apple.com>
350
351         Throw Exception when test doesn't clean up HID Events properly
352         https://bugs.webkit.org/show_bug.cgi?id=166271
353
354         Reviewed by Simon Fraser.
355
356         Add in a check when UIScriptController is deleted to make sure that the HID event
357         callback dictionary is empty. If it is not, and a HID event is hit, this will cause
358         the program to crash without any good information. Crashes are race-y, and will still
359         happen with malformed test, but the information will be much more helpful. 
360
361         * DumpRenderTree/ios/UIScriptControllerIOS.mm:
362         (WTR::UIScriptController::checkForClean):
363         * TestRunnerShared/UIScriptContext/UIScriptContext.cpp:
364         (UIScriptContext::~UIScriptContext):
365         * TestRunnerShared/UIScriptContext/UIScriptController.cpp:
366         (WTR::UIScriptController::checkForClean):
367         * TestRunnerShared/UIScriptContext/UIScriptController.h:
368         * WebKitTestRunner/ios/HIDEventGenerator.h:
369         * WebKitTestRunner/ios/HIDEventGenerator.mm:
370         (-[HIDEventGenerator checkHIDCallbacksClear]):
371         * WebKitTestRunner/ios/TestControllerIOS.mm:
372         * WebKitTestRunner/ios/UIScriptControllerIOS.mm:
373         (WTR::UIScriptController::checkForClean):
374
375 2016-12-20  Andy Estes  <aestes@apple.com>
376
377         [Cocoa] REGRESSION (r209558): Calling decisionHandler multiple times in webView:decidePolicyForNavigationAction:decisionHandler: leads to a crash
378         https://bugs.webkit.org/show_bug.cgi?id=165992
379
380         Reviewed by Brady Eidson.
381
382         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
383         * TestWebKitAPI/Tests/WebKit2Cocoa/DuplicateCompletionHandlerCalls.mm: Added.
384         (expectException):
385         (-[DuplicateCompletionHandlerCallsDelegate webView:decidePolicyForNavigationAction:decisionHandler:]):
386         (-[DuplicateCompletionHandlerCallsDelegate webView:decidePolicyForNavigationResponse:decisionHandler:]):
387         (-[DuplicateCompletionHandlerCallsDelegate webView:runJavaScriptAlertPanelWithMessage:initiatedByFrame:completionHandler:]):
388         (-[DuplicateCompletionHandlerCallsDelegate webView:runJavaScriptConfirmPanelWithMessage:initiatedByFrame:completionHandler:]):
389         (-[DuplicateCompletionHandlerCallsDelegate webView:runJavaScriptTextInputPanelWithPrompt:defaultText:initiatedByFrame:completionHandler:]):
390         (-[DuplicateCompletionHandlerCallsDelegate _webView:decideDatabaseQuotaForSecurityOrigin:currentQuota:currentOriginUsage:currentDatabaseUsage:expectedUsage:decisionHandler:]):
391         (-[DuplicateCompletionHandlerCallsDelegate _webView:willSubmitFormValues:userObject:submissionHandler:]):
392         (TEST):
393         * TestWebKitAPI/Tests/WebKit2Cocoa/duplicate-completion-handler-calls.html: Added.
394
395 2016-12-20  Dean Jackson  <dino@apple.com>
396
397         Remove INDIE_UI
398         https://bugs.webkit.org/show_bug.cgi?id=165881
399         <rdar://problem/29672532>
400
401         Reviewed by Simon Fraser.
402
403         The Indie UI work has been discontinued.
404
405         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
406
407 2016-12-19  Yusuke Suzuki  <utatane.tea@gmail.com>
408
409         [ES6] Enable ES6 Modules
410         https://bugs.webkit.org/show_bug.cgi?id=165849
411
412         Reviewed by Geoffrey Garen.
413
414         * DumpRenderTree/mac/DumpRenderTree.mm:
415         (resetWebPreferencesToConsistentValues):
416         * DumpRenderTree/win/DumpRenderTree.cpp:
417         (resetWebPreferencesToConsistentValues):
418         * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
419         (WTR::InjectedBundle::beginTesting):
420         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
421         (WTR::TestRunner::setES6ModulesEnabled): Deleted.
422         * WebKitTestRunner/InjectedBundle/TestRunner.h:
423
424 2016-12-19  Ryan Haddad  <ryanhaddad@apple.com>
425
426         Repurpose bots and clean up dashboard.
427         https://bugs.webkit.org/show_bug.cgi?id=166045
428
429         Reviewed by Lucas Forschler.
430
431         * BuildSlaveSupport/build.webkit.org-config/config.json:
432         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BubbleQueueServer.js:
433         (BubbleQueueServer):
434         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/Dashboard.js:
435         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/WebKitBuildbot.js:
436         (WebKitBuildbot):
437         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Styles/Main.css:
438         (table.queue-grid tr.platform.mac-os-x-yosemite img.logo): Deleted.
439
440 2016-12-19  Michael Catanzaro  <mcatanzaro@igalia.com>
441
442         [CMake] TestWebKitAPIBase links to itself
443         https://bugs.webkit.org/show_bug.cgi?id=165985
444
445         Reviewed by Alex Christensen.
446
447         Fix CMake warning about a target linking to itself, which makes no sense.
448
449         * TestWebKitAPI/CMakeLists.txt:
450
451 2016-12-19  Michael Catanzaro  <mcatanzaro@igalia.com>
452
453         [GTK] GtkDoc build should be quieter
454         https://bugs.webkit.org/show_bug.cgi?id=165994
455
456         Reviewed by Carlos Garcia Campos.
457
458         Make it not print by default.
459
460         * gtk/generate-gtkdoc:
461         (get_generator_for_config):
462         (generate_doc):
463         * gtk/gtkdoc.py:
464         (GTKDoc._run_command):
465         (GTKDoc._copy_doc_files_to_output_dir):
466
467 2016-12-18  Simon Fraser  <simon.fraser@apple.com>
468
469         Expose a way for MiniBrowser to simulate header and footer banners
470         https://bugs.webkit.org/show_bug.cgi?id=166005
471
472         Reviewed by Wenson Hsieh.
473         
474         Add a MiniBrowser menu item and setting to toggle adding space for header and footer
475         banners. This only works in WebKit2.
476         
477         We need to reset these on each navigation, since newly created FrameViews
478         don't re-fetch the header and footer height stored on Page.
479         
480         Also fix the signature of webView:didFinishNavigation: to follow API changes,
481         as well as fixing webViewWebContentProcessDidTerminate:
482
483         * MiniBrowser/mac/SettingsController.h:
484         * MiniBrowser/mac/SettingsController.m:
485         (-[SettingsController _populateMenu]):
486         (-[SettingsController validateMenuItem:]):
487         (-[SettingsController toggleReserveSpaceForBanners:]):
488         (-[SettingsController isSpaceReservedForBanners]):
489         * MiniBrowser/mac/WK2BrowserWindowController.m:
490         (-[WK2BrowserWindowController didChangeSettings]):
491         (-[WK2BrowserWindowController webView:didFinishNavigation:]):
492         (-[WK2BrowserWindowController webViewWebContentProcessDidTerminate:]):
493         (-[WK2BrowserWindowController webView:didFinishLoadingNavigation:]): Deleted.
494         (-[WK2BrowserWindowController _webViewWebProcessDidCrash:]): Deleted.
495
496 2016-12-17  Simon Fraser  <simon.fraser@apple.com>
497
498         Fix iOS test results after r209967.
499         
500         Subtracting out the status bar height was erroneously happening for all tests,
501         not just for flexible viewport tests.
502         
503         Fix by plumbing WebViewSizingMode through resizeTo() and setWindowFrame().
504
505         * WebKitTestRunner/PlatformWebView.h:
506         * WebKitTestRunner/TestController.cpp:
507         (WTR::TestController::resetStateToConsistentValues):
508         * WebKitTestRunner/efl/PlatformWebViewEfl.cpp:
509         (WTR::PlatformWebView::resizeTo):
510         (WTR::PlatformWebView::setWindowFrame):
511         * WebKitTestRunner/gtk/PlatformWebViewGtk.cpp:
512         (WTR::PlatformWebView::resizeTo):
513         (WTR::PlatformWebView::setWindowFrame):
514         * WebKitTestRunner/ios/PlatformWebViewIOS.mm:
515         (WTR::PlatformWebView::resizeTo):
516         (WTR::PlatformWebView::setWindowFrame):
517         * WebKitTestRunner/ios/TestControllerIOS.mm:
518         (WTR::TestController::platformConfigureViewForTest):
519         * WebKitTestRunner/mac/PlatformWebViewMac.mm:
520         (WTR::PlatformWebView::resizeTo):
521         (WTR::PlatformWebView::setWindowFrame):
522
523 2016-12-17  Joonghun Park  <jh718.park@samsung.com>
524
525         [EFL] bump EFL version to 1.18.4
526         https://bugs.webkit.org/show_bug.cgi?id=166004
527
528         Reviewed by Gyuyoung Kim.
529
530         * efl/jhbuild.modules: Use efl-1.18.4 instead of 1.18.1.
531
532 2016-12-17  Wenson Hsieh  <wenson_hsieh@apple.com>
533
534         Visual viewports: bottom fixed elements disappear behind the keyboard
535         https://bugs.webkit.org/show_bug.cgi?id=165983
536         <rdar://problem/29409852>
537
538         Reviewed by Simon Fraser.
539
540         Add support for UIScriptController.inputViewBounds, which UI-side scripts may use to fetch the bounding rect of
541         the keyboard when it is up.
542
543         * DumpRenderTree/ios/UIScriptControllerIOS.mm:
544         (WTR::UIScriptController::inputViewBounds):
545         * TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
546         * TestRunnerShared/UIScriptContext/UIScriptController.cpp:
547         (WTR::UIScriptController::inputViewBounds):
548         * TestRunnerShared/UIScriptContext/UIScriptController.h:
549         * WebKitTestRunner/ios/PlatformWebViewIOS.mm:
550         (WTR::viewRectForWindowRect):
551
552         Previously, we accounted for the status bar height by translating the entire web view down by the height of the
553         status bar. However, we did not shrink the height of the web view itself, which means that for tests which
554         involve scrolling past the end of the document, the bottom strip of the web view is out of bounds of the window.
555
556         (WTR::PlatformWebView::PlatformWebView):
557         (WTR::PlatformWebView::setWindowFrame):
558         * WebKitTestRunner/ios/UIScriptControllerIOS.mm:
559         (WTR::UIScriptController::inputViewBounds):
560
561 2016-12-16  Ryosuke Niwa  <rniwa@webkit.org>
562
563         Deleting a character converted from pinyin after an image causes a Safari crash
564         https://bugs.webkit.org/show_bug.cgi?id=165839
565         <rdar://problem/27951933>
566
567         Reviewed by Wenson Hsieh.
568
569         Add a WebKit API test to call attributedSubstringForProposedRange on a WKWebView
570         while the proposed range contains an image. This should not cause a WebProcess to crash
571         or send an invalid message to the UIProcess.
572
573         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
574         * TestWebKitAPI/Tests/WebKit2/chinese-character-with-image.html: Added.
575         * TestWebKitAPI/Tests/WebKit2/mac/AttributedSubstringForProposedRangeWithImage.mm: Added.
576         (TestWebKitAPI::didFinishLoadForFrame):
577         (TestWebKitAPI::processDidCrash):
578         (TestWebKitAPI::invalidMessageFunction):
579         (TestWebKitAPI::WebKit2.AttributedSubstringForProposedRangeWithImage):
580
581 2016-12-16  Wenson Hsieh  <wenson_hsieh@apple.com>
582
583         Visual viewports: carets and selection UI are incorrectly positioned when editing fixed elements
584         https://bugs.webkit.org/show_bug.cgi?id=165767
585         <rdar://problem/29602382>
586
587         Reviewed by Simon Fraser.
588
589         Introduces two new UIScriptController methods: doAfterWebPageIsInStableState and textSelectionCaretRect. See
590         WebKit2 ChangeLog for more details.
591
592         * DumpRenderTree/ios/UIScriptControllerIOS.mm:
593         (WTR::UIScriptController::doAfterNextStablePresentationUpdate):
594         (WTR::UIScriptController::textSelectionCaretRect):
595         * DumpRenderTree/mac/UIScriptControllerMac.mm:
596         (WTR::UIScriptController::doAfterNextStablePresentationUpdate):
597         * TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
598         * TestRunnerShared/UIScriptContext/UIScriptController.cpp:
599         (WTR::UIScriptController::doAfterNextStablePresentationUpdate):
600         (WTR::UIScriptController::textSelectionCaretRect):
601         * TestRunnerShared/UIScriptContext/UIScriptController.h:
602         * WebKitTestRunner/cocoa/TestRunnerWKWebView.mm:
603         (-[TestRunnerWKWebView _setStableStateOverride:]):
604
605         Force the WKWebView to update its visible content rects when changing the stable state override.
606
607         * WebKitTestRunner/ios/UIScriptControllerIOS.mm:
608         (WTR::toNSDictionary):
609         (WTR::UIScriptController::doAfterNextStablePresentationUpdate):
610         (WTR::UIScriptController::selectionRangeViewRects):
611         (WTR::UIScriptController::textSelectionCaretRect):
612         * WebKitTestRunner/mac/UIScriptControllerMac.mm:
613         (WTR::UIScriptController::doAfterNextStablePresentationUpdate):
614
615 2016-12-15  Brent Fulgham  <bfulgham@apple.com>
616
617         Arguments called in wrong order
618         https://bugs.webkit.org/show_bug.cgi?id=165923
619
620         Reviewed by Simon Fraser.
621
622         The 'audioDeviceUIDs' array is being passed to the argument that expects video devices,
623         and the 'videoDeviceUIDs' array is being passed to the audo device argument. Fix this.
624
625         * TestWebKitAPI/Tests/WebKit2/UserMedia.cpp:
626         (TestWebKitAPI::decidePolicyForUserMediaPermissionRequestCallBack): The
627         order of arguments to WKUserMediaPermissionRequestAllow are flipped.
628
629 2016-12-16  Hunseop Jeong  <hs85.jeong@samsung.com>
630
631         [EFL] Disable non-srcdir builds for failing libraries
632         https://bugs.webkit.org/show_bug.cgi?id=165896
633
634         Reviewed by Gyuyoung Kim.
635
636         * efl/jhbuild.modules: Set non srcdir builds to no
637
638 2016-12-15  Daniel Bates  <dabates@apple.com>
639
640         check-style should not complain about code in icu directories
641         https://bugs.webkit.org/show_bug.cgi?id=53929
642
643         Reviewed by Darin Adler.
644
645         Skip style checking of imported ICU headers to avoid a deluge of style issues
646         as they do not conform to the WebKit Code Style guideline. We want to preserve
647         the formatting of these headers so as to make it straightforward to merge
648         changes to them, if necessary.
649
650         * Scripts/webkitpy/style/checker.py:
651
652 2016-12-15  Alexey Proskuryakov  <ap@apple.com>
653
654         Move JSC testers from Yosemite to Sierra
655         https://bugs.webkit.org/show_bug.cgi?id=165925
656
657         Reviewed by Lucas Forschler.
658
659         * BuildSlaveSupport/build.webkit.org-config/config.json:
660         * BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/WebKitBuildbot.js:
661         (WebKitBuildbot):
662
663 2016-12-15  Megan Gardner  <megan_gardner@apple.com>
664
665         Add coordinate space to event streams and streamline tests
666         https://bugs.webkit.org/show_bug.cgi?id=165119
667
668         Reviewed by Simon Fraser.
669
670         Update event streams to allow for both content and global coordinate space.
671         Update example script to more accurately show all the available options.
672
673         * TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
674         * WebKitTestRunner/ios/HIDEventGenerator.h:
675         * WebKitTestRunner/ios/HIDEventGenerator.mm:
676         * WebKitTestRunner/ios/UIScriptControllerIOS.mm:
677         (WTR::convertCoordinates):
678         (WTR::UIScriptController::sendEventStream):
679
680 2016-12-15  Claudio Saavedra  <csaavedra@igalia.com>
681
682         [GTK] Ensure gst* docs are not built with update-webkitgtk-libs
683         https://bugs.webkit.org/show_bug.cgi?id=165855
684
685         Reviewed by Philippe Normand.
686
687         GStreamer's autogen.sh enables gtk-doc always so we end up building
688         docs even if we disable them. Use the configure script instead, since
689         we build from packages and these include it already.
690
691         * gtk/jhbuild.modules: Use shipped configure instead of autogen.sh for
692         upstream gstreamer packages.
693
694 2016-12-15  Alex Christensen  <achristensen@webkit.org>
695
696         REGRESSION (r208902) Null pointer dereference in wkIsPublicSuffix
697         https://bugs.webkit.org/show_bug.cgi?id=165885
698         <rdar://problem/29476917>
699
700         Reviewed by Darin Adler.
701
702         * TestWebKitAPI/Tests/WebCore/URLParser.cpp:
703         (TestWebKitAPI::utf16String): Deleted.
704         * TestWebKitAPI/Tests/mac/PublicSuffix.mm:
705         (TestWebKitAPI::TEST_F):
706         * TestWebKitAPI/WTFStringUtilities.h:
707         (utf16String):
708         Moved from URLParser to share with other tests.
709
710 2016-12-14  Ryosuke Niwa  <rniwa@webkit.org>
711
712         iOS: An element with tabindex is not focusable unless there is no mouse event handler
713         https://bugs.webkit.org/show_bug.cgi?id=165843
714
715         Reviewed by Antti Koivisto.
716
717         Add testRunner.isWebKit2 which is always true in WebKitTestRunner.
718         Without this, it's really hard to reliably differentiate DumpRenderTree and WebKitTestRunner,
719         and DumpRenderTree's runUIScript would hit an assertion :(
720
721         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
722         * WebKitTestRunner/InjectedBundle/TestRunner.h:
723         (WTR::TestRunner::isWebKit2):
724
725 2016-12-14  Brady Eidson  <beidson@apple.com>
726
727         IndexedDB 2.0: Massively speedup IDBIndex.get().
728         https://bugs.webkit.org/show_bug.cgi?id=165802
729
730         Reviewed by Alex Christensen.
731
732         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
733         * TestWebKitAPI/Tests/WebKit2Cocoa/IDBIndexUpgradeToV2.html: Added.
734         * TestWebKitAPI/Tests/WebKit2Cocoa/IDBIndexUpgradeToV2.mm: Added.
735         * TestWebKitAPI/Tests/WebKit2Cocoa/IndexUpgrade.blob: Added.
736         * TestWebKitAPI/Tests/WebKit2Cocoa/IndexUpgrade.sqlite3: Added.
737
738 2016-12-14  Carlos Alberto Lopez Perez  <clopez@igalia.com>
739
740         [GTK][EFL] Update the JHBuild version.
741         https://bugs.webkit.org/show_bug.cgi?id=165838
742
743         Reviewed by Michael Catanzaro.
744
745         * jhbuild/jhbuild-wrapper: This new version fixes a bug with the
746         usage of the JHBUILD_MIRROR feature with git repositories.
747
748 2016-12-14  Carlos Alberto Lopez Perez  <clopez@igalia.com>
749
750         [GTK] Yasm is needed for building the JHBuild after r208940
751         https://bugs.webkit.org/show_bug.cgi?id=165837
752
753         Reviewed by Alejandro G. Castro.
754
755         * gtk/install-dependencies: Yasm is needed for building libvpx.
756
757 2016-12-14  Youenn Fablet  <youenn@apple.com>
758
759         Test infrastructure should allow to filter out text output before doing a comparison with the baseline
760         https://bugs.webkit.org/show_bug.cgi?id=161310
761
762         Reviewed by Ryosuke Niwa.
763
764         Adding --dump-jsconsolelog-in-stderr test option for DRT and WTR.
765         When set, WTR and DRT output JS console log in the stderr and not the test output.
766         This allows removing potentially flaky information while still being able to read it for investigation.
767
768         Updated webkitpy infrastructure to use this test option in case of DumpJSConsoleLogInStdErr modifier.
769
770         Changes are covered by updating a fetch test to output console log and set its option to --dump-jsconsolelog-in-stderr in TestExpectations.
771         This test should have this option when fetch API will start logging resource loader errors.
772
773         * DumpRenderTree/DumpRenderTree.h:
774         (TestCommand::TestCommand): Deleted.
775         * DumpRenderTree/DumpRenderTreeCommon.cpp:
776         (parseInputLine):
777         * DumpRenderTree/TestRunner.h:
778         (TestRunner::setDumpJSConsoleLogInStdErr):
779         (TestRunner::dumpJSConsoleLogInStdErr):
780         * DumpRenderTree/mac/DumpRenderTree.mm:
781         (runTest):
782         * DumpRenderTree/mac/UIDelegate.mm:
783         (-[UIDelegate webView:addMessageToConsole:withSource:]):
784         * DumpRenderTree/win/DumpRenderTree.cpp:
785         (runTest):
786         * DumpRenderTree/win/UIDelegate.cpp:
787         (UIDelegate::webViewAddMessageToConsole):
788         * Scripts/webkitpy/layout_tests/models/test_expectations.py:
789         (TestExpectationParser._tokenize_line):
790         * Scripts/webkitpy/port/driver.py:
791         (Driver._command_from_driver_input):
792         * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
793         (WTR::InjectedBundle::didReceiveMessageToPage):
794         (WTR::InjectedBundle::dumpToStdErr):
795         * WebKitTestRunner/InjectedBundle/InjectedBundle.h:
796         (WTR::InjectedBundle::dumpJSConsoleLogInStdErr):
797         * WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
798         (WTR::InjectedBundlePage::willAddMessageToConsole):
799         * WebKitTestRunner/TestController.cpp:
800         (WTR::parseInputLine):
801         (WTR::TestController::runTest):
802         (WTR::TestCommand::TestCommand): Deleted.
803         * WebKitTestRunner/TestInvocation.cpp:
804         (WTR::TestInvocation::invoke):
805         (WTR::TestInvocation::didReceiveMessageFromInjectedBundle):
806         * WebKitTestRunner/TestInvocation.h:
807         (WTR::TestInvocation::setDumpJSConsoleLogInStdErr):
808
809
810 2016-12-14  Enrique Ocaña González  <eocanha@igalia.com>
811
812         REGRESSION(r207879-207891): [GStreamer] Introduced many layout test failures and crashes, bots exiting early
813         https://bugs.webkit.org/show_bug.cgi?id=164022
814
815         Reviewed by Xabier Rodriguez-Calvar.
816
817         * Scripts/webkitperl/FeatureList.pm:
818           Re-enable MEDIA_SOURCE for the GTK+ port.
819
820 2016-12-13  Alex Christensen  <achristensen@webkit.org>
821
822         Fix CMake build.
823
824         * DumpRenderTree/PlatformMac.cmake:
825         Define NS_RETURNS_RETAINED as nothing for now.
826
827 2016-12-13  Jer Noble  <jer.noble@apple.com>
828
829         Fullscreen in WebKit2 does not restore topContentInset upon exiting; leaves top of page not visible
830         https://bugs.webkit.org/show_bug.cgi?id=165697
831
832         Reviewed by Tim Horton.
833
834         * TestWebKitAPI/Tests/WebKit2Cocoa/FullscreenTopContentInset.mm:
835         (TestWebKitAPI::TEST):
836
837 2016-12-13  Andy Estes  <aestes@apple.com>
838
839         [Cocoa] Implement -shouldInsertText: on WKWebProcessPlugInEditingDelegate
840         https://bugs.webkit.org/show_bug.cgi?id=165785
841         <rdar://problem/26929398>
842
843         Reviewed by Darin Adler.
844
845         * TestWebKitAPI/Tests/WebKit2Cocoa/BundleEditingDelegate.mm:
846         (-[BundleEditingDelegateRemoteObject shouldInsertText:replacingRange:givenAction:]): Added
847         expectations for the text, range, and action.
848         (TEST): Set the "EditingDelegateShouldInsertText" bundle parameter to NO so that the plug-in
849         will return NO in -_webProcessPlugInBrowserContextController:willInsertText:. Added a
850         plain-text string to the pasteboard, executed a paste action, and verified that the selected
851         text in the web view did not change.
852         * TestWebKitAPI/Tests/WebKit2Cocoa/BundleEditingDelegatePlugIn.mm:
853         (-[BundleEditingDelegatePlugIn webProcessPlugIn:didCreateBrowserContextController:]): Set
854         _editingDelegateShouldInsertText according to the "EditingDelegateShouldInsertText" bundle
855         parameter.
856         (-[BundleEditingDelegatePlugIn _webProcessPlugInBrowserContextController:shouldInsertText:replacingRange:givenAction:]):
857         Added. Called -shouldInsertText:replacingRange:givenAction: on the remote object proxy
858         and returned the value of _editingDelegateShouldInsertText.
859         * TestWebKitAPI/Tests/WebKit2Cocoa/BundleEditingDelegateProtocol.h: Declared
860         -shouldInsertText:replacingRange:givenAction:.
861
862 2016-12-13  Chris Dumez  <cdumez@apple.com>
863
864         Unreviewed, rolling out r209544.
865
866         Looks like r209489 did not cause the performance regression
867         after all
868
869         Reverted changeset:
870
871         "Unreviewed, rolling out r209489."
872         https://bugs.webkit.org/show_bug.cgi?id=165550
873         http://trac.webkit.org/changeset/209544
874
875 2016-12-12  Sam Weinig  <sam@webkit.org>
876
877         [WebIDL] Remove use of Dictionary in ApplePaySession
878         https://bugs.webkit.org/show_bug.cgi?id=165787
879
880         Reviewed by Anders Carlsson.
881
882         * WebKitTestRunner/cocoa/TestControllerCocoa.mm:
883         (WTR::initializeWebViewConfiguration):
884         (WTR::TestController::platformCreateWebView):
885         Enable ApplePay for the tests (where supported).
886
887 2016-12-13  Eric Carlson  <eric.carlson@apple.com>
888
889         Annotate MediaStream and WebRTC idl with EnabledAtRuntime flag
890         https://bugs.webkit.org/show_bug.cgi?id=165251
891
892         Reviewed by Youenn Fablet.
893
894         * TestWebKitAPI/Tests/WebKit2/EnumerateMediaDevices.cpp:
895         (TestWebKitAPI::TEST): Enable MediaStream, create web view from the page group upon which
896         the preferences have been set.
897
898 2016-12-08  Antti Koivisto  <antti@apple.com>
899
900         Enable network cache speculative revalidation in MiniBrowser
901         https://bugs.webkit.org/show_bug.cgi?id=165616
902
903         Reviewed by Darin Adler.
904
905         Match Safari. Also add a menu item to disable it.
906
907         * MiniBrowser/mac/AppDelegate.m:
908         (defaultConfiguration):
909         * MiniBrowser/mac/SettingsController.h:
910         * MiniBrowser/mac/SettingsController.m:
911         (-[SettingsController _populateMenu]):
912         (-[SettingsController validateMenuItem:]):
913         (-[SettingsController networkCacheSpeculativeRevalidationDisabled]):
914         (-[SettingsController toggleNetworkCacheSpeculativeRevalidationDisabled:]):
915
916 2016-12-12  Alexey Proskuryakov  <ap@apple.com>
917
918         ChangeLogs become readonly after resolving a conflict
919         https://bugs.webkit.org/show_bug.cgi?id=165440
920         rdar://problem/29491002
921
922         Reviewed by Darin Adler.
923
924         * Scripts/resolve-ChangeLogs: (resolveChangeLog): Set correct permissions when
925         moving the file.
926
927 2016-12-12  Filip Pizlo  <fpizlo@apple.com>
928
929         Re-enable collectContinuously since it doesn't crash anymore
930
931         Rubber stamped by Michael Saboff.
932
933         * Scripts/run-jsc-stress-tests:
934
935 2016-12-11  Konstantin Tokarev  <annulen@yandex.ru>
936
937         Unreviewed attempt to fix EFL and Mac/cmake builds after r209665.
938         https://bugs.webkit.org/show_bug.cgi?id=165686
939
940         * DumpRenderTree/CMakeLists.txt: WebKit2 should precede other target
941         so that right config.h comes first in include path.
942
943 2016-12-11  Dave Hyatt  <hyatt@apple.com>
944
945         [CSS Parser] Make sure content extensions initialize AtomicString
946         https://bugs.webkit.org/show_bug.cgi?id=165737
947
948         Reviewed by Darin Adler.
949
950         * TestWebKitAPI/Tests/WebCore/ContentExtensions.cpp:
951         (TestWebKitAPI::makeBackend):
952
953 2016-12-08  Dave Hyatt  <hyatt@apple.com>
954
955         [CSS Parser] Remove the old CSS Parser
956         https://bugs.webkit.org/show_bug.cgi?id=165645
957
958         Reviewed by Daniel Bates.
959
960         * TestWebKitAPI/Tests/WebCore/CSSParser.cpp:
961         (TestWebKitAPI::TEST):
962
963 2016-12-10  Konstantin Tokarev  <annulen@yandex.ru>
964
965         [cmake] Include WTF, JSC, and WebCore headers automatically to targers using them
966         https://bugs.webkit.org/show_bug.cgi?id=165686
967
968         Reviewed by Michael Catanzaro.
969
970         This change reduces duplication of include path lists between modules,
971         and reduces future need for fixes like r209605 (broken build because of
972         WebCore header suddenly becoming used in WebKit2).
973
974         * DumpRenderTree/CMakeLists.txt:
975         * DumpRenderTree/PlatformMac.cmake:
976         * ImageDiff/CMakeLists.txt:
977         * MiniBrowser/gtk/CMakeLists.txt:
978         * MiniBrowser/mac/CMakeLists.txt:
979         * MiniBrowser/win/CMakeLists.txt:
980         * TestWebKitAPI/CMakeLists.txt:
981         * TestWebKitAPI/PlatformEfl.cmake:
982         * TestWebKitAPI/PlatformJSCOnly.cmake:
983         * TestWebKitAPI/PlatformMac.cmake:
984         * TestWebKitAPI/Tests/WebKit2Gtk/CMakeLists.txt:
985         * WebKitTestRunner/CMakeLists.txt:
986         * WebKitTestRunner/PlatformGTK.cmake:
987         * WebKitTestRunner/PlatformMac.cmake:
988
989 2016-12-09  Csaba Osztrogonác  <ossy@webkit.org>
990
991         Unreviewed buildfix after r209630.
992
993         * Scripts/build-jsc: Remove building the non-existing testWASM.
994
995 2016-12-09  Eric Carlson  <eric.carlson@apple.com>
996
997         Annotate MediaStream and WebRTC idl with EnabledAtRuntime flag
998         https://bugs.webkit.org/show_bug.cgi?id=165251
999
1000         Reviewed by Dean Jackson.
1001
1002         Based on a patch by Dr Alex Gouaillard <agouaillard@gmail.com>
1003
1004         * DumpRenderTree/mac/DumpRenderTree.mm:
1005         (resetWebPreferencesToConsistentValues): Enable MediaStream and PeerConnection.
1006
1007         * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
1008         (WTR::InjectedBundle::beginTesting): Ditto.
1009
1010         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
1011         (WTR::TestRunner::setMediaStreamEnabled): New.
1012         (WTR::TestRunner::setPeerConnectionEnabled): New.
1013         * WebKitTestRunner/InjectedBundle/TestRunner.h:
1014
1015 2016-12-09  Brady Eidson  <beidson@apple.com> 
1016  
1017         Re-landing:
1018         Add _WKIconLoadingDelegate SPI. 
1019         https://bugs.webkit.org/show_bug.cgi?id=164894 
1020  
1021         Reviewed by Alex Christensen. 
1022         
1023         Add MiniBrowser support for this new SPI, configurable with a setting. 
1024  
1025         * MiniBrowser/mac/SettingsController.h: 
1026         * MiniBrowser/mac/SettingsController.m: 
1027         (-[SettingsController _populateMenu]): 
1028         (-[SettingsController validateMenuItem:]): 
1029         (-[SettingsController loadsAllSiteIcons]): 
1030         (-[SettingsController toggleLoadsAllSiteIcons:]): 
1031         * MiniBrowser/mac/WK2BrowserWindowController.m: 
1032         (-[WK2BrowserWindowController awakeFromNib]): 
1033         (-[WK2BrowserWindowController webView:shouldLoadIconWithParameters:completionHandler:]): 
1034
1035 2016-12-09  Ryan Haddad  <ryanhaddad@apple.com>
1036
1037         Fix the 32-bit build.
1038
1039         Unreviewed build fix.
1040
1041         * MiniBrowser/mac/SettingsController.h:
1042
1043 2016-12-09  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
1044
1045         Fedora also needs a PHP7 config file alternative
1046         https://bugs.webkit.org/show_bug.cgi?id=165606
1047
1048         Reviewed by Michael Catanzaro.
1049
1050         * Scripts/webkitpy/port/base.py:
1051         (Port._is_fedora_php_version_7): check for the php7 library.
1052         (Port._fedora_php_version): get the appropriate filename for Fedora.
1053         (Port._apache_config_file_name_for_platform):
1054
1055 2016-12-09  Ryan Haddad  <ryanhaddad@apple.com>
1056
1057         Complete the revert of r208865.
1058         https://bugs.webkit.org/show_bug.cgi?id=164894
1059
1060         Unreviewed build fix.
1061
1062         * MiniBrowser/mac/SettingsController.h:
1063         * MiniBrowser/mac/SettingsController.m:
1064         (-[SettingsController _populateMenu]):
1065         (-[SettingsController validateMenuItem:]):
1066         (-[SettingsController loadsAllSiteIcons]): Deleted.
1067         (-[SettingsController toggleLoadsAllSiteIcons:]): Deleted.
1068         * MiniBrowser/mac/WK2BrowserWindowController.m:
1069         (-[WK2BrowserWindowController awakeFromNib]):
1070         (-[WK2BrowserWindowController webView:shouldLoadIconWithParameters:completionHandler:]): Deleted.
1071
1072 2016-12-09  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
1073
1074         [GTK] Force GDK backend to x11 when running with XvfbDriver
1075         https://bugs.webkit.org/show_bug.cgi?id=165612
1076
1077         Reviewed by Michael Catanzaro.
1078
1079         When the developer is running a Wayland session, GDK may get confused
1080         and try to use its Wayland backend (which is higher priority) instead.
1081         This ensures it will use the appropriate backend when running under
1082         Xvfb.
1083
1084         * Scripts/webkitpy/port/gtk.py:
1085         (GtkPort.setup_environ_for_server): when running with XvfbDriver,
1086         force GDK_BACKEND to x11.
1087
1088 2016-12-08  Keith Miller  <keith_miller@apple.com>
1089
1090         Add 64-bit signed LEB decode method
1091         https://bugs.webkit.org/show_bug.cgi?id=165630
1092
1093         Reviewed by Ryosuke Niwa.
1094
1095         Add tests for LEB int64 and uint64 decode since I guess
1096         I forgot to add tests before.
1097
1098         * TestWebKitAPI/Tests/WTF/LEBDecoder.cpp:
1099         (TestWebKitAPI::testUInt32LEBDecode):
1100         (TestWebKitAPI::TEST):
1101         (TestWebKitAPI::testUInt64LEBDecode):
1102         (TestWebKitAPI::testInt32LEBDecode):
1103         (TestWebKitAPI::testInt64LEBDecode):
1104         (TestWebKitAPI::testUnsignedLEBDecode): Deleted.
1105
1106 2016-12-08  Filip Pizlo  <fpizlo@apple.com>
1107
1108         Make it easy to enable --force-collectContinuously
1109         https://bugs.webkit.org/show_bug.cgi?id=165638
1110
1111         Reviewed by Keith Miller.
1112
1113         * Scripts/run-javascriptcore-tests:
1114         (runJSCStressTests):
1115
1116 2016-12-08  Filip Pizlo  <fpizlo@apple.com>
1117
1118         Disable the collectContinuously mode until I investigate failures.
1119
1120         Rubber stamped by Keith Miller.
1121         
1122         I'm seeing collectContinuously crashes on some platforms. Disabling that testing mode
1123         while I investigate.
1124
1125         * Scripts/run-jsc-stress-tests:
1126
1127 2016-12-08  Alex Christensen  <achristensen@webkit.org>
1128
1129         REGRESSION (URL parser): Relative URLs aren’t resolved correctly when the base URL is an applewebdata: URL
1130         https://bugs.webkit.org/show_bug.cgi?id=165621
1131
1132         Reviewed by Dan Bernstein.
1133
1134         * TestWebKitAPI/Tests/WebCore/URLParser.cpp:
1135         (TestWebKitAPI::TEST_F):
1136
1137 2016-12-06  Filip Pizlo  <fpizlo@apple.com>
1138
1139         Concurrent GC should be stable enough to land enabled
1140         https://bugs.webkit.org/show_bug.cgi?id=164990
1141
1142         Reviewed by Geoffrey Garen.
1143         
1144         Add a new mode that runs GC continuously. Also made eager modes run GC continuously.
1145         
1146         It's clear that this works just fine in release, but I'm still trying to figure out if it's
1147         safe for debug. It might be too slow for debug.
1148
1149         * Scripts/run-jsc-stress-tests:
1150
1151 2016-12-08  Alex Christensen  <achristensen@webkit.org>
1152
1153         Add SPI for sending WebsiteSettings to WebProcess during navigation
1154         https://bugs.webkit.org/show_bug.cgi?id=165517
1155         <rdar://29341068>
1156
1157         Reviewed by Anders Carlsson.
1158
1159         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
1160         * TestWebKitAPI/Tests/WebKit2/contentBlockerCheck.html: Added.
1161         * TestWebKitAPI/Tests/WebKit2Cocoa/WebsitePolicies.mm: Added.
1162         (-[WebsitePoliciesDelegate webView:decidePolicyForNavigationAction:decisionHandler:]):
1163         (-[WebsitePoliciesDelegate _webView:decidePolicyForNavigationAction:decisionHandler:]):
1164         (-[WebsitePoliciesDelegate webView:runJavaScriptAlertPanelWithMessage:initiatedByFrame:completionHandler:]):
1165         (TEST):
1166
1167 2016-12-08  Chris Dumez  <cdumez@apple.com>
1168
1169         Unreviewed, rolling out r209489.
1170
1171         Likely caused large regressions on JetStream, Sunspider and
1172         Speedometer
1173
1174         Reverted changeset:
1175
1176         "Add system trace points for JavaScript VM entry/exit"
1177         https://bugs.webkit.org/show_bug.cgi?id=165550
1178         http://trac.webkit.org/changeset/209489
1179
1180 2016-12-08  Keith Miller  <keith_miller@apple.com>
1181
1182         Move LEB tests to API tests
1183         https://bugs.webkit.org/show_bug.cgi?id=165586
1184
1185         Reviewed by Saam Barati.
1186
1187         Move the tests from testWasm.cpp and make them functions
1188         rather than macros.
1189
1190         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
1191         * TestWebKitAPI/Tests/WTF/LEBDecoder.cpp: Added.
1192         (TestWebKitAPI::testUnsignedLEBDecode):
1193         (TestWebKitAPI::TEST):
1194         (TestWebKitAPI::testInt32LEBDecode):
1195
1196 2016-12-08  Chris Dumez  <cdumez@apple.com>
1197
1198         Support running the layout tests offline
1199         https://bugs.webkit.org/show_bug.cgi?id=165534
1200
1201         Reviewed by Ryosuke Niwa.
1202
1203         * Scripts/webkitpy/common/system/autoinstall.py:
1204         (AutoInstaller._download_to_stream):
1205         getcode() returns None for file URLs so handle this.
1206
1207         * Scripts/webkitpy/layout_tests/servers/web_platform_test_server.py:
1208         (WebPlatformTestServer._install_modules):
1209         Deal with local path in the json file and resolve them into file URLs
1210         before using AutoInstall.
1211
1212 2016-12-08  Alex Christensen  <achristensen@webkit.org>
1213
1214         Fix CMake build.
1215
1216         * DumpRenderTree/PlatformMac.cmake:
1217         Remove CheckedMalloc.cpp after r209516.
1218
1219 2016-12-07  Mark Lam  <mark.lam@apple.com>
1220
1221         DumpRenderTree should stop using CheckedMalloc.
1222         https://bugs.webkit.org/show_bug.cgi?id=165563
1223         <rdar://problem/28945820>
1224
1225         Reviewed by Geoffrey Garen.
1226
1227         1. WebKitTestRunner does not have equivalent behavior to that which is implemented
1228            in CheckedMalloc.
1229         2. bmalloc does not honor the settings of CheckedMalloc.
1230
1231         The only time CheckedMalloc comes into play is when DRT uses gmalloc or system
1232         malloc.  As a result, DRT exhibits different behavior from the normal way we run
1233         our tests.  We should obsolete CheckedMalloc and make DRT behave consistently
1234         with WKTR.
1235
1236         * DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj:
1237         * DumpRenderTree/mac/CheckedMalloc.cpp: Removed.
1238         * DumpRenderTree/mac/CheckedMalloc.h: Removed.
1239         * DumpRenderTree/mac/DumpRenderTree.mm:
1240         (prepareConsistentTestingEnvironment):
1241
1242 2016-12-07  Dean Jackson  <dino@apple.com>
1243
1244         Remove runtime toggle for pointer-lock
1245         https://bugs.webkit.org/show_bug.cgi?id=165577
1246         <rdar://problems/29566996>
1247
1248         Reviewed by Jon Lee.
1249
1250         Remove any runtime calls to check if pointer-lock is enabled. It's
1251         either compiled in or out.
1252
1253         * DumpRenderTree/mac/DumpRenderTree.mm:
1254         (resetWebPreferencesToConsistentValues):
1255         * WebKitTestRunner/TestController.cpp:
1256         (WTR::TestController::resetPreferencesToConsistentValues):
1257
1258 2016-12-07  Eric Carlson  <eric.carlson@apple.com>
1259
1260         [MediaStream][Mac] Revoke sandbox extensions when capture ends
1261         https://bugs.webkit.org/show_bug.cgi?id=165476
1262
1263         Reviewed by Brady Eidson.
1264         
1265         Add a test which loads a page that calls navigator.mediaDevices.enumerateDevices, kills the
1266         page, and loads the same page again to ensure that the WK2 UserMediaPermissionRequestManagerProxy
1267         is reset and recreated when a web page exits and is reloaded.
1268
1269         * TestWebKitAPI/PlatformGTK.cmake:
1270         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
1271         * TestWebKitAPI/Tests/WebKit2/EnumerateMediaDevices.cpp: Added.
1272         (TestWebKitAPI::checkUserMediaPermissionCallback):
1273         (TestWebKitAPI::TEST):
1274         * TestWebKitAPI/Tests/WebKit2/enumerateMediaDevices.html: Added.
1275
1276 2016-12-07  Jeremy Jones  <jeremyj@apple.com>
1277
1278         One esc to exit fullscreen and pointer lock
1279         https://bugs.webkit.org/show_bug.cgi?id=165416
1280         rdar://problem/29430711
1281
1282         Reviewed by Jer Noble.
1283
1284         Implement WKPageUIClientV8 for pointer lock support.
1285         Add "escape" key support in EventSenderProxy.
1286
1287         * WebKitTestRunner/TestController.cpp:
1288         (WTR::requestPointerLock):
1289         (WTR::TestController::createOtherPage):
1290         (WTR::TestController::createWebViewWithOptions):
1291         * WebKitTestRunner/mac/EventSenderProxy.mm:
1292         (WTR::EventSenderProxy::keyDown):
1293
1294 2016-12-07  Simon Fraser  <simon.fraser@apple.com>
1295
1296         Add system trace points for JavaScript VM entry/exit
1297         https://bugs.webkit.org/show_bug.cgi?id=165550
1298
1299         Reviewed by Tim Horton.
1300
1301         Add trace points for entry/exit into/out of the JS VM.
1302
1303         * Tracing/SystemTracePoints.plist:
1304
1305 2016-12-07  ChangSeok Oh  <changseok@webkit.org>
1306
1307         [GTK] Cannot build GTK+ with CUPS 2.* versions
1308         https://bugs.webkit.org/show_bug.cgi?id=163591
1309
1310         Reviewed by Michael Catanzaro.
1311
1312         GTK+ build has failed on the system which CUPS 2.x is installed in. GTK+ 3.16.4
1313         does not assume to use the recent CUPS thus it fails to detect the CUPS in configuration.
1314         GTK+ upstream fixed this issue but it is not easy to apply the original patch to our
1315         old gtk+ since it requires not only bumping up glib accordingly and its consequence
1316         causes many printing test failures. So, I propose to fix the configuration issue by
1317         applying the change to the configure file directly. By doing this, we don't need to
1318         upgrade glib and worry about any test failures as a consequence of the upgraded glib.
1319
1320         * gtk/jhbuild.modules:
1321         * gtk/patches/gtk+-configure-fix-detecting-CUPS-2.x.patch: Added.
1322
1323 2016-12-07  Simon Fraser  <simon.fraser@apple.com>
1324
1325         Fix use of enum in a WK2 C SPI header.
1326         rdar://problem/28725583
1327
1328         Followup to correctly prefix the enum values.
1329
1330         * WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
1331         (WTR::InjectedBundlePage::prepare):
1332
1333 2016-12-07  Simon Fraser  <simon.fraser@apple.com>
1334
1335         Fix use of enum in a WK2 C SPI header.
1336         rdar://problem/28725583
1337
1338         Reviewed by Dan Bernstein.
1339
1340         Use correct enum style for a C SPI header and fix the callers.
1341
1342         * WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
1343         (WTR::InjectedBundlePage::prepare):
1344
1345 2016-12-07  Wenson Hsieh  <wenson_hsieh@apple.com>
1346
1347         Add a new project for recording and playing back editing commands in editable web content
1348         https://bugs.webkit.org/show_bug.cgi?id=165114
1349         <rdar://problem/29408135>
1350
1351         Reviewed by Beth Dakin.
1352
1353         Adds a new Xcode project containing work towards rewinding and playing back editing commands. This work is
1354         wrapped in an Xcode project to take advantage of the XCTest framework. To manually test recording, open the
1355         capture test harness, edit the contenteditable body, and then hit cmd-S. This downloads a .json file which may
1356         then be dragged into the playback test harness.
1357
1358         Also adds 3 new unit tests in EditingHistoryTests/RewindAndPlaybackTests.m. These tests carry out the following
1359         steps:
1360
1361         1. Load the capture harness and perform test-specific editing on the web view.
1362         2. Let originalState be a dump of the DOM at this point in time.
1363         3. Extract the JSON-serialized editing history data and load the playback harness with this data.
1364         4. Rewind all editing to the beginning.
1365         5. Playback all editing to the end.
1366         6. Dump the state of the DOM. This should be identical to originalState.
1367
1368         * EditingHistory/EditingHistory.xcodeproj/project.pbxproj: Added.
1369         * EditingHistory/EditingHistory/Info.plist: Added.
1370         * EditingHistory/EditingHistory/Resources/CaptureHarness.html: Added.
1371         * EditingHistory/EditingHistory/Resources/DOMTestingUtil.js: Added.
1372         * EditingHistory/EditingHistory/Resources/PlaybackHarness.html: Added.
1373         * EditingHistory/EditingHistory/TestRunner.h: Added.
1374         * EditingHistory/EditingHistory/TestRunner.m: Added.
1375         (injectedMessageEventHandlerScript):
1376         (-[TestRunner init]):
1377         (-[TestRunner deleteBackwards:]):
1378         (-[TestRunner typeString:]):
1379         (-[TestRunner bodyElementSubtree]):
1380         (-[TestRunner bodyTextContent]):
1381         (-[TestRunner editingHistoryJSON]):
1382         (-[TestRunner loadPlaybackTestHarnessWithJSON:]):
1383         (-[TestRunner numberOfUpdates]):
1384         (-[TestRunner jumpToUpdateIndex:]):
1385         (-[TestRunner expectEvents:afterPerforming:]):
1386         (-[TestRunner loadCaptureTestHarness]):
1387         (-[TestRunner setTextObfuscationEnabled:]):
1388         (-[TestRunner isDoneWaitingForPendingEvents]):
1389         (-[TestRunner userContentController:didReceiveScriptMessage:]):
1390
1391         The TestRunner provides utilities that a unit test should use to drive the test forward (e.g. loading harnesses)
1392         or inspect the state of the loaded page (e.g. extracting JSON editing history data from the capture harness).
1393
1394         * EditingHistory/EditingHistory/TestUtil.h: Added.
1395         * EditingHistory/EditingHistory/TestUtil.m: Added.
1396         (waitUntilWithTimeout):
1397         (waitUntil):
1398
1399         Provides utilities for running tests. For now, this is just spinning the runloop on a given condition.
1400
1401         * EditingHistory/EditingHistory/WKWebViewAdditions.h: Added.
1402         * EditingHistory/EditingHistory/WKWebViewAdditions.m: Added.
1403         (-[WKWebView loadPageFromBundleNamed:]):
1404         (-[WKWebView typeCharacter:]):
1405         (-[WKWebView keyPressWithCharacters:keyCode:]):
1406         (-[WKWebView stringByEvaluatingJavaScriptFromString:]):
1407
1408         Provides utilities for simulating interaction in a web view.
1409
1410         * EditingHistory/EditingHistory/main.m: Added.
1411         (main):
1412         * EditingHistory/EditingHistoryTests/Info.plist: Added.
1413         * EditingHistory/EditingHistoryTests/RewindAndPlaybackTests.m: Added.
1414         (-[RewindAndPlaybackTests setUp]):
1415         (-[RewindAndPlaybackTests tearDown]):
1416         (-[RewindAndPlaybackTests testTypingSingleLineOfText]):
1417         (-[RewindAndPlaybackTests testTypingMultipleLinesOfText]):
1418         (-[RewindAndPlaybackTests testTypingAndDeletingText]):
1419         (-[RewindAndPlaybackTests rewindAndPlaybackEditingInPlaybackTestHarness]):
1420         (-[RewindAndPlaybackTests originalBodySubtree:isEqualToFinalSubtree:]):
1421
1422 2016-12-07  Philippe Normand  <pnormand@igalia.com>
1423
1424         [GTK][jhbuild] missing dependency on libvpx in gst-plugins-good
1425         https://bugs.webkit.org/show_bug.cgi?id=165525
1426
1427         Reviewed by Carlos Garcia Campos.
1428
1429         * gtk/jhbuild.modules: gst-plugins-good should depend on the
1430         libvpx package built within jhbuild.
1431
1432 2016-12-07  Philippe Normand  <pnormand@igalia.com>
1433
1434         [GTK][jhbuild] gst-plugins-bad fails to build with OpenSSL 1.1.0
1435         https://bugs.webkit.org/show_bug.cgi?id=165520
1436
1437         Reviewed by Carlos Garcia Campos.
1438
1439         * gtk/jhbuild.modules: Added missing dependency on openh264 in
1440         gst-plugins-bad, along with 2 upstream patches fixing the build
1441         against OpenSSL 1.1.0.
1442         * gtk/patches/gst-plugins-bad-0001-dtls-port-to-OpenSSL-1.1.0.patch: Added.
1443         * gtk/patches/gst-plugins-bad-0002-dtlscertificate-Fix-error-checking-in-RSA_generate_k.patch: Added.
1444
1445 2016-12-06  Alexey Proskuryakov  <ap@apple.com>
1446
1447         Correct SDKROOT values in xcconfig files
1448         https://bugs.webkit.org/show_bug.cgi?id=165487
1449         rdar://problem/29539209
1450
1451         Reviewed by Dan Bernstein.
1452
1453         Fix suggested by Dan Bernstein.
1454
1455         * ContentExtensionTester/Configurations/DebugRelease.xcconfig:
1456         * DumpRenderTree/mac/Configurations/DebugRelease.xcconfig:
1457         * MiniBrowser/Configurations/DebugRelease.xcconfig:
1458         * TestWebKitAPI/Configurations/DebugRelease.xcconfig:
1459         * WebEditingTester/Configurations/DebugRelease.xcconfig:
1460         * WebKitTestRunner/Configurations/DebugRelease.xcconfig:
1461
1462 2016-12-06  Daniel Bates  <dabates@apple.com>
1463
1464         WebKitTestRunner: Plugins are disabled in new windows
1465         https://bugs.webkit.org/show_bug.cgi?id=165410
1466
1467         Reviewed by Alex Christensen.
1468
1469         Currently WebKitTestRunner only enables plugins in the main window. So, a test that opens
1470         a new window and loads a plugin will fail. We should enable plugins in all windows by
1471         default. Moreover toggling testRunner.setPluginsEnabled() should effect all windows.
1472
1473         Making these changes is a step towards running plugins/open-and-close-window-with-plugin.html
1474         in WebKitTestRunner (we still need to fix <https://bugs.webkit.org/show_bug.cgi?id=46714>) and
1475         will make the behavior of WebKitTestRunner more closely match the behavior DumpRenderTree.
1476
1477         * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
1478         (WTR::InjectedBundle::beginTesting): Call TestRunner::setPluginsEnabled() instead of
1479         WKBundleSetPluginsEnabled().
1480         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
1481         (WTR::TestRunner::setPluginsEnabled): Take a similar approach as TestRunner::setXSSAuditorEnabled()
1482         and make use of WKBundleOverrideBoolPreferenceForTestRunner().
1483
1484 2016-12-05  Dean Jackson  <dino@apple.com>
1485
1486         pointer lock needs to be feature detectable
1487         https://bugs.webkit.org/show_bug.cgi?id=165426
1488         <rdar://problem/29486715>
1489
1490         Reviewed by Antoine Quint.
1491
1492         Expose the comment line to turn on/off pointer lock.
1493
1494         * DumpRenderTree/TestOptions.h:
1495         * DumpRenderTree/TestOptions.mm:
1496         (TestOptions::TestOptions):
1497         * DumpRenderTree/mac/DumpRenderTree.mm:
1498         (resetWebPreferencesToConsistentValues):
1499         * WebKitTestRunner/TestController.cpp:
1500         (WTR::TestController::resetPreferencesToConsistentValues):
1501         (WTR::updateTestOptionsFromTestHeader):
1502         * WebKitTestRunner/TestOptions.h:
1503         * WebKitTestRunner/ios/PlatformWebViewIOS.mm:
1504         (WTR::PlatformWebView::viewSupportsOptions):
1505         * WebKitTestRunner/mac/PlatformWebViewMac.mm:
1506         (WTR::PlatformWebView::viewSupportsOptions):
1507
1508 2016-12-05  Jonathan Bedard  <jbedard@apple.com>
1509
1510         Make it possible to use an existing simulator instance for one-off testing
1511         https://bugs.webkit.org/show_bug.cgi?id=164568
1512         <rdar://problem/29189133>
1513
1514         Reviewed by Daniel Bates.
1515
1516         With this patch, if a simulator is currently running on the machine and
1517         '--dedicated-simulators' is not passed into the application, only one simulator
1518         instance will be used, and this instance will be the existing instance.
1519         If no simulator is running or '--dedicated-simulators' is passed to the script,
1520         previous behavior will be used.
1521
1522         * Scripts/webkitpy/layout_tests/run_webkit_tests.py:
1523         (parse_args):
1524         * Scripts/webkitpy/port/ios.py:
1525         (IOSSimulatorPort.__init__): Logic for enabling usage of currently running simulator.
1526         (IOSSimulatorPort._create_simulators): Only create simulators when needed, don't reset already running simulators.
1527         (IOSSimulatorPort.setup_test_run): Don't open already running simulators.
1528         (IOSSimulatorPort._quit_ios_simulator): Only quit simulators if we manage them.
1529         (IOSSimulatorPort.clean_up_test_run): Only clean up simulators if we manage them. 
1530         (IOSSimulatorPort._using_dedicated_simulators): True if simulators need to be managed, false if using an existing instance.
1531         (IOSSimulatorPort.device_id_for_worker_number): Access currently running simulator if not managing devices.
1532         * Scripts/webkitpy/xcode/simulator.py:
1533         (Simulator.refresh): Check if xcode_simctl_list returned None instead of a generator.
1534         (Simulator.current_device): Get currently running device.
1535
1536 2016-12-05  Dan Bernstein  <mitz@apple.com>
1537
1538         Disable a crashing test on iOS.
1539
1540         * TestWebKitAPI/Tests/WebKit2Cocoa/BundleEditingDelegate.mm:
1541
1542 2016-12-04  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
1543
1544         Fix a build break on EFL since r209303.
1545
1546         Unreviewed build fix.
1547
1548         * Scripts/webkitperl/FeatureList.pm: Disable SS Device Adaptation temporarily.
1549
1550 2016-12-03  Yusuke Suzuki  <utatane.tea@gmail.com>
1551
1552         Refactor SymbolImpl layout
1553         https://bugs.webkit.org/show_bug.cgi?id=165247
1554
1555         Reviewed by Darin Adler.
1556
1557         * TestWebKitAPI/Tests/WTF/StringImpl.cpp:
1558         (TestWebKitAPI::TEST):
1559
1560 2016-12-03  Dan Bernstein  <mitz@apple.com>
1561
1562         Fixed the build after r209307.
1563
1564         * TestWebKitAPI/Tests/WebKit2Cocoa/BundleEditingDelegate.mm:
1565         (TEST):
1566
1567 2016-12-03  Dan Bernstein  <mitz@apple.com>
1568
1569         [Cocoa] Expose InjectedBundlePageEditorClient via the Objective-C bundle SPI
1570         https://bugs.webkit.org/show_bug.cgi?id=165276
1571         <rdar://problem/29467040>
1572
1573         Reviewed by Darin Adler.
1574
1575         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
1576         * TestWebKitAPI/Tests/WebKit2Cocoa/BundleEditingDelegate.mm: Added.
1577         (-[BundleEditingDelegateRemoteObject willWriteToPasteboard:]):
1578         (-[BundleEditingDelegateRemoteObject didWriteToPasteboard]):
1579         (TEST):
1580         * TestWebKitAPI/Tests/WebKit2Cocoa/BundleEditingDelegatePlugIn.mm: Added.
1581         (-[BundleEditingDelegatePlugIn webProcessPlugIn:didCreateBrowserContextController:]):
1582         (-[BundleEditingDelegatePlugIn _webProcessPlugInBrowserContextController:willWriteRangeToPasteboard:]):
1583         (-[BundleEditingDelegatePlugIn _webProcessPlugInBrowserContextController:pasteboardDataForRange:]):
1584         (-[BundleEditingDelegatePlugIn _webProcessPlugInBrowserContextControllerDidWriteToPasteboard:]):
1585         * TestWebKitAPI/Tests/WebKit2Cocoa/BundleEditingDelegateProtocol.h: Added.
1586
1587 2016-12-02  Andy Estes  <aestes@apple.com>
1588
1589         [Cocoa] Adopt the PRODUCT_BUNDLE_IDENTIFIER build setting
1590         https://bugs.webkit.org/show_bug.cgi?id=164492
1591
1592         Reviewed by Dan Bernstein.
1593
1594         * DumpRenderTree/TestNetscapePlugIn/mac/Info.plist: Changed CFBundleIdentifier's value from
1595         com.apple.testnetscapeplugin to ${PRODUCT_BUNDLE_IDENTIFIER}.
1596         * DumpRenderTree/ios/Info.plist: Changed CFBundleIdentifier's value from
1597         org.webkit.DumpRenderTree to ${PRODUCT_BUNDLE_IDENTIFIER}.
1598         * DumpRenderTree/mac/Configurations/DumpRenderTreeApp.xcconfig: Set
1599         PRODUCT_BUNDLE_IDENTIFIER to org.webkit.DumpRenderTree.
1600         * DumpRenderTree/mac/Configurations/TestNetscapePlugIn.xcconfig: Set
1601         PRODUCT_BUNDLE_IDENTIFIER to com.apple.testnetscapeplugin.
1602         * MiniBrowser/Configurations/MiniBrowser.xcconfig: Set PRODUCT_BUNDLE_IDENTIFIER to
1603         org.webkit.$(PRODUCT_NAME:rfc1034identifier).
1604         * MiniBrowser/Configurations/MiniBrowserBundle.xcconfig: Set PRODUCT_BUNDLE_IDENTIFIER to
1605         com.apple.$(PRODUCT_NAME:rfc1034identifier).
1606         * MiniBrowser/mac/Bundle/Info.plist: Changed CFBundleIdentifier's value from
1607         com.apple.${PRODUCT_NAME:rfc1034identifier} to ${PRODUCT_BUNDLE_IDENTIFIER}.
1608         * MiniBrowser/mac/Info.plist: Changed CFBundleIdentifier's value from
1609         org.webkit.${PRODUCT_NAME} to ${PRODUCT_BUNDLE_IDENTIFIER}.
1610         * TestWebKitAPI/Configurations/InjectedBundle.xcconfig: Set INFOPLIST_FILE to
1611         InjectedBundle-Info.plist and set PRODUCT_BUNDLE_IDENTIFIER to
1612         com.apple.$(PRODUCT_NAME:rfc1034identifier).
1613         * TestWebKitAPI/Configurations/WebProcessPlugIn.xcconfig: Set PRODUCT_BUNDLE_IDENTIFIER to
1614         com.apple.$(PRODUCT_NAME:rfc1034identifier).
1615         * TestWebKitAPI/InjectedBundle-Info.plist: Changed CFBundleIdentifier's value from
1616         com.yourcompany.${PRODUCT_NAME:rfc1034identifier} to ${PRODUCT_BUNDLE_IDENTIFIER}.
1617         * TestWebKitAPI/cocoa/WebProcessPlugIn/Info.plist: Added a CFBundleIdentifier key with the
1618         value ${PRODUCT_BUNDLE_IDENTIFIER}.
1619         * WebKitTestRunner/Configurations/InjectedBundle.xcconfig: Set INFOPLIST_FILE to
1620         InjectedBundle-Info.plist and set PRODUCT_BUNDLE_IDENTIFIER to
1621         com.apple.WebKitTestRunner.InjectedBundle.
1622         * WebKitTestRunner/Configurations/WebKitTestRunnerApp.xcconfig: Set
1623         PRODUCT_BUNDLE_IDENTIFIER to org.webkit.$(PRODUCT_NAME:rfc1034identifier).
1624         * WebKitTestRunner/InjectedBundle-Info.plist: Changed CFBundleIdentifier's value from
1625         com.apple.WebKitTestRunner.InjectedBundle to ${PRODUCT_BUNDLE_IDENTIFIER}.
1626         * WebKitTestRunner/WebKitTestRunnerApp/WebKitTestRunnerApp-Info.plist: Changed
1627         CFBundleIdentifier's value from org.webkit.${PRODUCT_NAME:rfc1034identifier} to
1628         ${PRODUCT_BUNDLE_IDENTIFIER}.
1629
1630 2016-12-02  Brady Eidson  <beidson@apple.com>
1631
1632         Make IndexedDB.WebProcessKillIDBCleanup even more reliable.
1633         https://bugs.webkit.org/show_bug.cgi?id=165330
1634
1635         Reviewed by Alex Christensen.
1636
1637         The test currently nulls out a RetainPtr<WKWebView> to try to destroy the view and kill the process.
1638
1639         Problem is that doesn't reliably destroy the view.
1640         We should explicitly kill the process instead.
1641
1642         Also, by relocating when we kill the process, we can better test behavior of the IndexedDB mechanism.
1643         e.g. We explicitly confirm that a second WebProcess can simultaneously attach to the same unique database as the first.
1644
1645         * TestWebKitAPI/Tests/WebKit2Cocoa/WebProcessKillIDBCleanup.mm:
1646         (TEST):
1647
1648 2016-12-02  Commit Queue  <commit-queue@webkit.org>
1649
1650         Unreviewed, rolling out r209136.
1651         https://bugs.webkit.org/show_bug.cgi?id=165337
1652
1653         broke 36 webkitpy tests (Requested by mcatanzaro on #webkit).
1654
1655         Reverted changeset:
1656
1657         "Make it possible to use an existing simulator instance for
1658         one-off testing"
1659         https://bugs.webkit.org/show_bug.cgi?id=164568
1660         http://trac.webkit.org/changeset/209136
1661
1662 2016-12-02  Chris Dumez  <cdumez@apple.com>
1663
1664         [Mac][WK1] Implement new HTML interactive form validation user interface
1665         https://bugs.webkit.org/show_bug.cgi?id=164483
1666
1667         Reviewed by Simon Fraser.
1668
1669         Add support for UIScriptController's contentsOfUserInterfaceItem("validationBubble")
1670         on Mac DRT as this is needed by the HTML form validation layout tests.
1671
1672         * DumpRenderTree/mac/UIScriptControllerMac.mm:
1673         (WTR::UIScriptController::contentsOfUserInterfaceItem):
1674
1675 2016-12-02  Brady Eidson  <beidson@apple.com>
1676
1677         IndexedDB.IndexedDBMultiProcess and IndexedDB.WebProcessKillIDBCleanup sometimes timeout.
1678         https://bugs.webkit.org/show_bug.cgi?id=160780 and https://bugs.webkit.org/show_bug.cgi?id=161001
1679
1680         Reviewed by Alexey Proskuryakov.
1681
1682         These tests had "run-loop races."
1683         
1684         The test spins the runloop waiting for one message.
1685         Two messages might come in from the WebProcess in short succession, and both be delivered to the
1686         UIProcess in the same spin of the runloop.
1687
1688         Therefore by the time the test stops spinning the runloop, notified that a message was received,
1689         the first message has been overwritten by the second.
1690
1691         These tests are fixed by queueing the incoming messages instead of just storing one.
1692
1693         * TestWebKitAPI/Tests/WebKit2Cocoa/IndexedDBMultiProcess.mm:
1694         (-[IndexedDBMPMessageHandler userContentController:didReceiveScriptMessage:]):
1695         (getNextMessage):
1696         (TEST):
1697
1698         * TestWebKitAPI/Tests/WebKit2Cocoa/WebProcessKillIDBCleanup.mm:
1699         (-[IndexedDBWebProcessKillMessageHandler userContentController:didReceiveScriptMessage:]):
1700         (getNextMessage):
1701         (TEST):
1702
1703 2016-12-01  Jiewen Tan  <jiewen_tan@apple.com>
1704
1705         Add a runtime flag for SubtleCrypto
1706         https://bugs.webkit.org/show_bug.cgi?id=164982
1707
1708         Reviewed by Brent Fulgham.
1709
1710         * DumpRenderTree/mac/DumpRenderTree.mm:
1711         (resetWebPreferencesToConsistentValues):
1712         * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
1713         (WTR::InjectedBundle::beginTesting):
1714         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
1715         (WTR::TestRunner::setSubtleCryptoEnabled):
1716         * WebKitTestRunner/InjectedBundle/TestRunner.h:
1717
1718 2016-12-01  Alexey Proskuryakov  <ap@apple.com>
1719
1720         Remove webkitpy dependency on Eliza
1721         https://bugs.webkit.org/show_bug.cgi?id=164979
1722
1723         Reviewed by Daniel Bates.
1724
1725         This module is not on pypi, so installing it is a challenge. The jokes feel pretty old too!
1726
1727         * Scripts/webkitpy/thirdparty/__init__.py:
1728         * Scripts/webkitpy/thirdparty/__init___unittest.py: Changed mock import hook to
1729         test buildbot instead of eliza.
1730         * Scripts/webkitpy/tool/bot/ircbot.py:
1731         * Scripts/webkitpy/tool/bot/ircbot_unittest.py:
1732
1733 2016-12-01  Beth Dakin  <bdakin@apple.com>
1734
1735         Force clicking tests fail on some machines
1736         https://bugs.webkit.org/show_bug.cgi?id=165263
1737
1738         Reviewed by Tim Horton.
1739
1740         Initialize com.apple.trackpad.forceClick to 1 so that we don’t have to depend on 
1741         the user account having this feature enabled. 
1742         * WebKitTestRunner/InjectedBundle/mac/InjectedBundleMac.mm:
1743         (WTR::InjectedBundle::platformInitialize):
1744         * WebKitTestRunner/mac/main.mm:
1745         (setDefaultsToConsistentValuesForTesting):
1746
1747 2016-12-01  Yusuke Suzuki  <utatane.tea@gmail.com>
1748
1749         Introduce StringImpl::StaticStringImpl with constexpr constructor
1750         https://bugs.webkit.org/show_bug.cgi?id=165093
1751
1752         Reviewed by Darin Adler.
1753
1754         * TestWebKitAPI/Tests/WTF/StringImpl.cpp:
1755         (TestWebKitAPI::TEST):
1756
1757 2016-11-30  Antoine Quint  <graouts@apple.com>
1758
1759         [Modern Media Controls] Add an HTML comment flag to turn the feature on
1760         https://bugs.webkit.org/show_bug.cgi?id=165226
1761
1762         Reviewed by Dean Jackson.
1763
1764         Add a new flag to turn Modern Media Controls on in the test runners.
1765
1766         * DumpRenderTree/TestOptions.h:
1767         * DumpRenderTree/TestOptions.mm:
1768         (TestOptions::TestOptions):
1769         * DumpRenderTree/mac/DumpRenderTree.mm:
1770         (resetWebPreferencesToConsistentValues):
1771         * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
1772         (WTR::InjectedBundle::beginTesting):
1773         * WebKitTestRunner/TestController.cpp:
1774         (WTR::TestController::resetPreferencesToConsistentValues):
1775         (WTR::updateTestOptionsFromTestHeader):
1776         * WebKitTestRunner/TestOptions.h:
1777         * WebKitTestRunner/ios/PlatformWebViewIOS.mm:
1778         (WTR::PlatformWebView::viewSupportsOptions):
1779         * WebKitTestRunner/mac/PlatformWebViewMac.mm:
1780         (WTR::PlatformWebView::viewSupportsOptions):
1781
1782 2016-11-30  Said Abou-Hallawa  <sabouhallawa@apple.com>
1783
1784         Add separate settings and preferences to enable/disable async decoding for large images and animated images
1785         https://bugs.webkit.org/show_bug.cgi?id=165177
1786
1787         Reviewed by Simon Fraser.
1788         
1789         Pref and a menu item to toggle async image decoding settings for WebKits 1 and 2.
1790
1791         * MiniBrowser/mac/SettingsController.h:
1792         * MiniBrowser/mac/SettingsController.m:
1793         (-[SettingsController _populateMenu]):
1794         (-[SettingsController validateMenuItem:]):
1795         (-[SettingsController toggleLargeImageAsyncDecodingEnabled:]):
1796         (-[SettingsController largeImageAsyncDecodingEnabled]):
1797         (-[SettingsController toggleAnimatedImageAsyncDecodingEnabled:]):
1798         (-[SettingsController animatedImageAsyncDecodingEnabled]):
1799         (-[SettingsController toggleAsyncImageDecodingEnabled:]): Deleted.
1800         (-[SettingsController asyncImageDecodingEnabled]): Deleted.
1801         * MiniBrowser/mac/WK1BrowserWindowController.m:
1802         (-[WK1BrowserWindowController didChangeSettings]):
1803         * MiniBrowser/mac/WK2BrowserWindowController.m:
1804         (-[WK2BrowserWindowController didChangeSettings]):
1805
1806 2016-11-30  Jonathan Bedard  <jbedard@apple.com>
1807
1808         Make it possible to use an existing simulator instance for one-off testing
1809         https://bugs.webkit.org/show_bug.cgi?id=164568
1810         <rdar://problem/29189133>
1811
1812         Reviewed by Daniel Bates.
1813
1814         With this patch, if a simulator is currently running on the machine and
1815         '--dedicated-simulators' is not passed into the application, only one simulator
1816         instance will be used, and this instance will be the existing instance.
1817         If no simulator is running or '--dedicated-simulators' is passed to the script,
1818         previous behavior will be used.
1819
1820         * Scripts/webkitpy/layout_tests/run_webkit_tests.py:
1821         (parse_args):
1822         * Scripts/webkitpy/port/ios.py:
1823         (IOSSimulatorPort.__init__): Logic for enabling usage of currently running simulator.
1824         (IOSSimulatorPort._create_simulators): Only create simulators when needed, don't reset already running simulators.
1825         (IOSSimulatorPort.setup_test_run): Don't open already running simulators.
1826         (IOSSimulatorPort._quit_ios_simulator): Only quit simulators if we manage them.
1827         (IOSSimulatorPort.clean_up_test_run): Only clean up simulators if we manage them. 
1828         (IOSSimulatorPort._using_dedicated_simulators): True if simulators need to be managed, false if using an existing instance.
1829         (IOSSimulatorPort.device_id_for_worker_number): Access currently running simulator if not managing devices.
1830         * Scripts/webkitpy/xcode/simulator.py:
1831         (Simulator.current_device): Get currently running device.
1832
1833 2016-11-29  Carlos Alberto Lopez Perez  <clopez@igalia.com>
1834
1835         [Linux] run-benchmark should be able to execute the benchmarks with more browsers.
1836         https://bugs.webkit.org/show_bug.cgi?id=164792
1837
1838         Reviewed by Michael Catanzaro.
1839
1840         This removes the GTKBrowserDriver (and the platform 'gtk') from the run-benchmark script,
1841         and adds a new LinuxBrowserDriver with a platform 'linux'.
1842
1843         It add also drivers for Chrome (Chromium), Firefox, Epiphany and MiniBrowser-GTK (previously MiniBrowser).
1844
1845         The detection of the platform is now done automatically, so it is not longer needed to pass a "--platform" parameter.
1846
1847         The tracking of the browser process is now more robust, we track the pid of the browser process and we only try to
1848         kill the ones that were executed by this script, instead of doing a 'killall $browser' (like before).
1849         We also check for browser process childs and we kill them if they are still alive after the main browser process has been killed.
1850         This depends on psutil, so this will only be done if psutil is installed.
1851
1852         * BuildSlaveSupport/build.webkit.org-config/master.cfg:
1853         (RunBenchmarkTests.start): The platform is now autodetected and the MiniBrowser driver is renamed to MiniBrowser-GTK.
1854         * Scripts/webkitpy/benchmark_runner/benchmark_runner.py:
1855         (BenchmarkRunner._run_benchmark): Fix a bug that caused close_browsers to be called twice. Its already called inside BenchmarkRunner._run_one_test.
1856         * Scripts/webkitpy/benchmark_runner/browser_driver/linux_browser_driver.py: Added.
1857         (LinuxBrowserDriver): Implement base class that has all the needed functionality for driving the browsers.
1858         (LinuxBrowserDriver.__init__):
1859         (LinuxBrowserDriver.prepare_env):
1860         (LinuxBrowserDriver.restore_env):
1861         (LinuxBrowserDriver.close_browsers): Made the dependency on psutil optional (because it was listed as such on the README file <Tools/Scripts/webkitpy/benchmark_runner/README.md>)
1862         (LinuxBrowserDriver.launch_url):
1863         (LinuxBrowserDriver._get_first_executable_path_from_list):
1864         (LinuxBrowserDriver._screen_size):
1865         * Scripts/webkitpy/benchmark_runner/browser_driver/linux_chrome_driver.py: Copied from Tools/Scripts/webkitpy/benchmark_runner/browser_driver/gtk_minibrowser_driver.py.
1866         (LinuxChromeDriver):
1867         (LinuxChromeDriver.launch_url):
1868         * Scripts/webkitpy/benchmark_runner/browser_driver/linux_epiphany_driver.py: Renamed from Tools/Scripts/webkitpy/benchmark_runner/browser_driver/gtk_browser_driver.py.
1869         (EpiphanyBrowserDriver):
1870         (EpiphanyBrowserDriver.launch_url):
1871         * Scripts/webkitpy/benchmark_runner/browser_driver/linux_firefox_driver.py: Copied from Tools/Scripts/webkitpy/benchmark_runner/browser_driver/gtk_minibrowser_driver.py.
1872         (LinuxFirefoxDriver):
1873         (LinuxFirefoxDriver.launch_url):
1874         * Scripts/webkitpy/benchmark_runner/browser_driver/linux_minibrowsergtk_driver.py: Renamed from Tools/Scripts/webkitpy/benchmark_runner/browser_driver/gtk_minibrowser_driver.py.
1875         (GTKMiniBrowserDriver):
1876         (GTKMiniBrowserDriver.launch_url):
1877         * Scripts/webkitpy/benchmark_runner/http_server_driver/simple_http_server_driver.py:
1878         (SimpleHTTPServerDriver):
1879         * Scripts/webkitpy/benchmark_runner/run_benchmark.py:
1880         (getplatform):
1881         (getdefaultbrowser):
1882         (parse_args):
1883         * Scripts/webkitpy/benchmark_runner/utils.py:
1884         (load_subclasses): The loading of subclasses was still (even after r196979) sensitive to the order in which the modules are loaded.
1885         We have to ensure that the files containing subclasses of the base_class_file are loaded after the base_class_file,
1886         we can do that by matching against the base_class_file pattern when the list is created.
1887
1888 2016-11-29  Andy Estes  <aestes@apple.com>
1889
1890         [Cocoa] Enable two clang warnings recommended by Xcode
1891         https://bugs.webkit.org/show_bug.cgi?id=164498
1892
1893         Reviewed by Mark Lam.
1894
1895         * DumpRenderTree/mac/Configurations/Base.xcconfig: Enabled CLANG_WARN_INFINITE_RECURSION and CLANG_WARN_SUSPICIOUS_MOVE.
1896         * MiniBrowser/Configurations/Base.xcconfig: Ditto.
1897         * TestWebKitAPI/Configurations/Base.xcconfig: Ditto.
1898         * WebKitTestRunner/Configurations/Base.xcconfig: Ditto.
1899
1900 2016-11-29  Eric Carlson  <eric.carlson@apple.com>
1901
1902         [MediaStream] Don't request user permission for a device if it has already been granted in the current browsing context
1903         https://bugs.webkit.org/show_bug.cgi?id=164760
1904         <rdar://problem/29261266>
1905
1906         Reviewed by Youenn Fablet.
1907         
1908         Allow scripts to determine the number of times the user has been prompted for capture device access.
1909
1910         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
1911         * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
1912         (WTR::InjectedBundle::setUserMediaPersistentPermissionForOrigin):
1913         (WTR::InjectedBundle::userMediaPermissionRequestCountForOrigin):
1914         (WTR::InjectedBundle::resetUserMediaPermissionRequestCountForOrigin):
1915         (WTR::InjectedBundle::setUserMediaPermissionForOrigin): Deleted.
1916         * WebKitTestRunner/InjectedBundle/InjectedBundle.h:
1917         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
1918         (WTR::TestRunner::setUserMediaPersistentPermissionForOrigin):
1919         (WTR::TestRunner::userMediaPermissionRequestCountForOrigin):
1920         (WTR::TestRunner::resetUserMediaPermissionRequestCountForOrigin):
1921         (WTR::TestRunner::setUserMediaPermissionForOrigin): Deleted.
1922         * WebKitTestRunner/InjectedBundle/TestRunner.h:
1923         * WebKitTestRunner/TestController.cpp:
1924         (WTR::TestController::resetStateToConsistentValues):
1925         (WTR::OriginSettings::incrementRequestCount):
1926         (WTR::OriginSettings::resetRequestCount):
1927         (WTR::OriginSettings::requestCount):
1928         (WTR::TestController::saltForOrigin):
1929         (WTR::TestController::setUserMediaPersistentPermissionForOrigin):
1930         (WTR::TestController::handleCheckOfUserMediaPermissionForOrigin):
1931         (WTR::TestController::settingsForOrigin):
1932         (WTR::TestController::userMediaPermissionRequestCountForOrigin):
1933         (WTR::TestController::resetUserMediaPermissionRequestCountForOrigin):
1934         (WTR::TestController::decidePolicyForUserMediaPermissionRequestIfPossible):
1935         (WTR::TestController::setUserMediaPermissionForOrigin): Deleted.
1936         * WebKitTestRunner/TestController.h:
1937         * WebKitTestRunner/TestInvocation.cpp:
1938         (WTR::TestInvocation::didReceiveMessageFromInjectedBundle):
1939         (WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):
1940
1941 2016-11-29  Simon Fraser  <simon.fraser@apple.com>
1942
1943         intersection-observer-entry-interface.html test fails on the bots
1944         https://bugs.webkit.org/show_bug.cgi?id=165133
1945
1946         Reviewed by Darin Adler.
1947         
1948         Tests that enabled Intersection Observer via <!-- webkit-test-runner [ enableIntersectionObserver=true ] -->
1949         would fail sometimes, because TestController::ensureViewSupportsOptionsForTest() failed to check
1950         to see if this option required creating a new web view, so would just use the old view without
1951         even resetting preferences.
1952         
1953         In general, TestController doesn't distinguish properly between options that require the creation
1954         of a new view (like mock scrollbars), and those that can be simply reset as resetPreferencesToConsistentValues()
1955         does.
1956         
1957         Do the easy fix of having viewSupportsOptions() check options.enableIntersectionObserver. We should probably
1958         just call resetPreferencesToConsistentValues() even when re-use the same view.
1959         
1960         * WebKitTestRunner/TestController.cpp:
1961         (WTR::TestController::resetPreferencesToConsistentValues):
1962         * WebKitTestRunner/ios/PlatformWebViewIOS.mm:
1963         (WTR::PlatformWebView::viewSupportsOptions):
1964         * WebKitTestRunner/mac/PlatformWebViewMac.mm:
1965         (WTR::PlatformWebView::viewSupportsOptions):
1966
1967 2016-11-28  Ryan Haddad  <ryanhaddad@apple.com>
1968
1969         Unreviewed, rolling out r209008.
1970
1971         This change appears to have caused two fast/mediastrem
1972         LayoutTests to fail.
1973
1974         Reverted changeset:
1975
1976         "[MediaStream] Don't request user permission for a device if
1977         it has already been granted in the current browsing context"
1978         https://bugs.webkit.org/show_bug.cgi?id=164760
1979         http://trac.webkit.org/changeset/209008
1980
1981 2016-11-28  Daniel Bates  <dabates@apple.com>
1982
1983         Teach webkitpy how to read CSSProperties.json r209001
1984         https://bugs.webkit.org/show_bug.cgi?id=165108
1985
1986         Reviewed by Simon Fraser.
1987
1988         Fix webkitpy logic so that it can read CSS property names from CSSProperties.json following r209001.
1989
1990         Following r209001 CSSPropertyNames.in no longer exists as it was replaced with CSSProperties.json.
1991         We need to modify the webkitpy machinery that processed CSSPropertyNames.in to process CSSProperties.json.
1992
1993         * Scripts/webkitpy/w3c/test_converter.py:
1994         (_W3CTestConverter.__init__): Make self._css_property_file and self._css_property_value_file local
1995         variables as it is unnecessary for them to be instance variables. Call read_webkit_prefixed_css_property_list()
1996         to read the property names from file CSSProperties.json. Call legacy_read_webkit_prefixed_css_property_list() to
1997         read CSS keyword values from CSSValueKeywords.in.
1998         (_W3CTestConverter.read_webkit_prefixed_css_property_list): Added.
1999         (_W3CTestConverter):
2000         (_W3CTestConverter.legacy_read_webkit_prefixed_css_property_list): Renamed from read_webkit_prefixed_css_property_list.
2001         * Scripts/webkitpy/w3c/test_importer_unittest.py:
2002         (TestImporterTest.test_harnesslinks_conversion): Substitute CSSProperties.json for CSSPropertyNames.in.
2003
2004 2016-11-28  Eric Carlson  <eric.carlson@apple.com>
2005
2006         [MediaStream] Don't request user permission for a device if it has already been granted in the current browsing context
2007         https://bugs.webkit.org/show_bug.cgi?id=164760
2008         <rdar://problem/29261266>
2009
2010         Reviewed by Youenn Fablet.
2011         
2012         Allow scripts to determine the number of times the user has been prompted for capture device access.
2013
2014         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
2015         * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
2016         (WTR::InjectedBundle::setUserMediaPersistentPermissionForOrigin):
2017         (WTR::InjectedBundle::userMediaPermissionRequestCountForOrigin):
2018         (WTR::InjectedBundle::resetUserMediaPermissionRequestCountForOrigin):
2019         (WTR::InjectedBundle::setUserMediaPermissionForOrigin): Deleted.
2020         * WebKitTestRunner/InjectedBundle/InjectedBundle.h:
2021         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
2022         (WTR::TestRunner::setUserMediaPersistentPermissionForOrigin):
2023         (WTR::TestRunner::userMediaPermissionRequestCountForOrigin):
2024         (WTR::TestRunner::resetUserMediaPermissionRequestCountForOrigin):
2025         (WTR::TestRunner::setUserMediaPermissionForOrigin): Deleted.
2026         * WebKitTestRunner/InjectedBundle/TestRunner.h:
2027         * WebKitTestRunner/TestController.cpp:
2028         (WTR::TestController::resetStateToConsistentValues):
2029         (WTR::OriginSettings::incrementRequestCount):
2030         (WTR::OriginSettings::resetRequestCount):
2031         (WTR::OriginSettings::requestCount):
2032         (WTR::TestController::saltForOrigin):
2033         (WTR::TestController::setUserMediaPersistentPermissionForOrigin):
2034         (WTR::TestController::handleCheckOfUserMediaPermissionForOrigin):
2035         (WTR::TestController::settingsForOrigin):
2036         (WTR::TestController::userMediaPermissionRequestCountForOrigin):
2037         (WTR::TestController::resetUserMediaPermissionRequestCountForOrigin):
2038         (WTR::TestController::decidePolicyForUserMediaPermissionRequestIfPossible):
2039         (WTR::TestController::setUserMediaPermissionForOrigin): Deleted.
2040         * WebKitTestRunner/TestController.h:
2041         * WebKitTestRunner/TestInvocation.cpp:
2042         (WTR::TestInvocation::didReceiveMessageFromInjectedBundle):
2043         (WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):
2044
2045 2016-11-18  Jer Noble  <jer.noble@apple.com>
2046
2047         Add some performance tests for various aspects of media loading and playback.
2048         https://bugs.webkit.org/show_bug.cgi?id=164977
2049
2050         Reviewed by Darin Adler.
2051
2052         Allow callers to pass in extra alias/directory pairs to run-webkit-httpd.
2053
2054         * Scripts/run-webkit-httpd:
2055         (parse_args):
2056         (main):
2057
2058 2016-11-27  Simon Fraser  <simon.fraser@apple.com>
2059
2060         Another fix for CMake.
2061
2062         * DumpRenderTree/TestOptions.h:
2063         * DumpRenderTree/TestOptions.mm:
2064
2065 2016-11-26  Simon Fraser  <simon.fraser@apple.com>
2066
2067         Better fix for the Mac CMake build.
2068
2069         * DumpRenderTree/PlatformMac.cmake:
2070
2071 2016-11-26  Simon Fraser  <simon.fraser@apple.com>
2072
2073         Attempt to fix Mac CMake build.
2074
2075         * DumpRenderTree/PlatformMac.cmake:
2076
2077 2016-11-26  Yusuke Suzuki  <utatane.tea@gmail.com>
2078
2079         [WTF] Import std::optional reference implementation as WTF::Optional
2080         https://bugs.webkit.org/show_bug.cgi?id=164199
2081
2082         Reviewed by Saam Barati and Sam Weinig.
2083
2084         Use WTF::Optional::value_or.
2085
2086         * DumpRenderTree/ios/UIScriptControllerIOS.mm:
2087         (WTR::UIScriptController::stableStateOverride):
2088         (WTR::UIScriptController::setStableStateOverride):
2089         * TestRunnerShared/Bindings/JSWrappable.h:
2090         (WTR::JSValueMakeBooleanOrNull):
2091         (WTR::JSValueToNullableBoolean):
2092         * TestRunnerShared/UIScriptContext/UIScriptController.cpp:
2093         (WTR::UIScriptController::stableStateOverride):
2094         (WTR::UIScriptController::setStableStateOverride):
2095         * TestRunnerShared/UIScriptContext/UIScriptController.h:
2096         * TestWebKitAPI/Tests/WTF/Optional.cpp:
2097         (TestWebKitAPI::TEST):
2098         * TestWebKitAPI/Tests/WebCore/HTMLParserIdioms.cpp:
2099         (TestWebKitAPI::testParseHTMLInteger):
2100         (TestWebKitAPI::testParseHTMLNonNegativeInteger):
2101         * TestWebKitAPI/Tests/WebCore/URLParser.cpp:
2102         (TestWebKitAPI::checkURL):
2103         (TestWebKitAPI::checkRelativeURL):
2104         (TestWebKitAPI::checkURLDifferences):
2105         (TestWebKitAPI::checkRelativeURLDifferences):
2106         * WebKitTestRunner/ios/UIScriptControllerIOS.mm:
2107         (WTR::UIScriptController::stableStateOverride):
2108         (WTR::UIScriptController::setStableStateOverride):
2109
2110 2016-11-26  Sam Weinig  <sam@webkit.org>
2111
2112         Convert IntersectionObserver over to using RuntimeEnabledFeatures so it can be properly excluded from script
2113         https://bugs.webkit.org/show_bug.cgi?id=164965
2114
2115         Reviewed by Simon Fraser.
2116
2117         * DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj:
2118         Add new files.
2119
2120         * DumpRenderTree/TestOptions.h: Added.
2121         * DumpRenderTree/TestOptions.mm: Added.
2122         (parseBooleanTestHeaderValue):
2123         (TestOptions::TestOptions):
2124         Port TestOption parsing from WKTR to DRT.
2125
2126         * DumpRenderTree/mac/DumpRenderTree.mm:
2127         (resetWebPreferencesToConsistentValues):
2128         (resetWebViewToConsistentStateBeforeTesting):
2129         (runTest):
2130         * WebKitTestRunner/TestController.cpp:
2131         Pass TestOptions down to resetWebPreferencesToConsistentValues to allow setting
2132         preferences conditionally.
2133
2134         (WTR::TestController::resetPreferencesToConsistentValues):
2135         (WTR::updateTestOptionsFromTestHeader):
2136         * WebKitTestRunner/TestOptions.h:
2137         Add a new test option header, enableIntersectionObserver, to enable IntersectionObserver.
2138
2139 2016-11-26  Simon Fraser  <simon.fraser@apple.com>
2140
2141         Migrate some layout timer-related code from std::chrono to Seconds and MonotonicTime
2142         https://bugs.webkit.org/show_bug.cgi?id=164992
2143
2144         Reviewed by Darin Adler.
2145         
2146         Use Seconds::zero().
2147
2148         * TestWebKitAPI/Tests/WTF/Condition.cpp:
2149
2150 2016-11-26  Simon Fraser  <simon.fraser@apple.com>
2151
2152         Add literals for various time units
2153         https://bugs.webkit.org/show_bug.cgi?id=165074
2154
2155         Reviewed by Filip Pizlo.
2156         
2157         Add tests for new time literals. Add new tests for units.
2158
2159         * TestWebKitAPI/Tests/WTF/Time.cpp:
2160         (TestWebKitAPI::TEST):
2161
2162 2016-11-25  Csaba Osztrogonác  <ossy@webkit.org>
2163
2164         Fix compile warnings after r208415
2165         https://bugs.webkit.org/show_bug.cgi?id=165061
2166
2167         Reviewed by Andy Estes.
2168
2169         * TestWebKitAPI/Tests/WTF/Time.cpp:
2170         (TestWebKitAPI::TEST):
2171
2172 2016-11-24  Michael Catanzaro  <mcatanzaro@igalia.com>
2173
2174         [GTK] Notifications API does not expose or respect the "tag" attribute
2175         https://bugs.webkit.org/show_bug.cgi?id=164771
2176
2177         Reviewed by Gustavo Noronha Silva.
2178
2179         Verify that showing a notification with the same tag as another notification closes the
2180         previous notification before the new notification is shown.
2181
2182         * TestWebKitAPI/Tests/WebKit2Gtk/TestWebKitWebView.cpp:
2183         (testWebViewNotification):
2184
2185 2016-11-24  Carlos Garcia Campos  <cgarcia@igalia.com>
2186
2187         Unreviewed. Fix GTK+ test /webkit2/WebKitWebContext/get-plugins after r208429.
2188
2189         Test plugin library was renamed as libTestNetscapePlugIn.so in r208429.
2190
2191         * TestWebKitAPI/Tests/WebKit2Gtk/TestWebKitWebContext.cpp:
2192         (testWebContextGetPlugins): Update the library name.
2193
2194 2016-11-22  Darin Adler  <darin@apple.com>
2195
2196         Make normal case fast in the input element limitString function
2197         https://bugs.webkit.org/show_bug.cgi?id=165023
2198
2199         Reviewed by Dan Bernstein.
2200
2201         * TestWebKitAPI/CMakeLists.txt: Added TextBreakIterator.cpp.
2202         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj: Ditto.
2203         * TestWebKitAPI/Tests/WTF/TextBreakIterator.cpp: Added.
2204         Contains some tests for the numGraphemeClusters and
2205         numCharactersInGraphemeClusters functions that I used to make sure
2206         that the new fast paths I added work correctly.
2207
2208 2016-11-22  Tomas Popela  <tpopela@redhat.com>
2209
2210         Unreviewed, add myself as a WebKit committer.
2211
2212         * Scripts/webkitpy/common/config/contributors.json:
2213
2214 2016-11-21  Mark Lam  <mark.lam@apple.com>
2215
2216         Hasher::addCharacters() should be able to handle zero length strings.
2217         https://bugs.webkit.org/show_bug.cgi?id=165024
2218
2219         Reviewed by Yusuke Suzuki.
2220
2221         * TestWebKitAPI/Tests/WTF/StringHasher.cpp:
2222         (TestWebKitAPI::TEST):
2223
2224 2016-11-21  Carlos Alberto Lopez Perez  <clopez@igalia.com>
2225
2226         [CMake] build fails after update to cmake 3.7
2227         https://bugs.webkit.org/show_bug.cgi?id=165008
2228
2229         Reviewed by Dan Bernstein.
2230
2231         When we remove the CMake cache, we should remove both the
2232         CMakeCache.txt file and the CMakeFiles directory.
2233         See: https://gitlab.kitware.com/cmake/cmake/issues/14820
2234
2235         * Scripts/webkitdirs.pm:
2236         (cmakeFilesPath):
2237         (removeCMakeCache):
2238
2239 2016-11-16  Philippe Normand  <pnormand@igalia.com>
2240
2241         [GTK][WebRTC] Switch to downstream OpenWebRTC and more recent GStreamer
2242         https://bugs.webkit.org/show_bug.cgi?id=164817
2243
2244         Reviewed by Alejandro G. Castro.
2245
2246         This is temporary, hopefully. The OpenWebRTC patches will/should
2247         be soon reviewed and upstream but meanwhile it makes sense to use
2248         the Igalia downstream fork so that the WebRTC testing is easier.
2249
2250         Recent GStreamer patches are also needed for RTP bundling support
2251         and RTP retransmission fixes.
2252
2253         * gtk/jhbuild.modules:
2254         * gtk/openwebrtc.modules: Removed.
2255         * gtk/patches/gst-plugins-good-0001-rtpbin-pipeline-gets-an-EOS-when-any-rtpsources-byes.patch: Added.
2256         * gtk/patches/gst-plugins-good-0002-rtpbin-avoid-generating-errors-when-rtcp-messages-ar.patch: Added.
2257         * gtk/patches/gst-plugins-good-0003-rtpbin-receive-bundle-support.patch: Added.
2258
2259 2016-11-20  Zan Dobersek  <zdobersek@igalia.com>
2260
2261         [EncryptedMedia] Make EME API runtime-enabled
2262         https://bugs.webkit.org/show_bug.cgi?id=164927
2263
2264         Reviewed by Jer Noble.
2265
2266         Enable the EME API via the WKTR InjectedBundle whenever testing
2267         commences. This does not have any effect unless the EME feature
2268         is enabled at compile-time, but it's still added to match other
2269         features and for future use.
2270
2271         * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
2272         (WTR::InjectedBundle::beginTesting):
2273         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
2274         (WTR::TestRunner::setEncryptedMediaAPIEnabled):
2275         * WebKitTestRunner/InjectedBundle/TestRunner.h:
2276
2277 2016-11-19  Simon Fraser  <simon.fraser@apple.com>
2278
2279         Fix the Mac and iOS bulds.
2280
2281         * WebKitTestRunner/cocoa/TestRunnerWKWebView.mm:
2282         (-[TestRunnerWKWebView _stableStateOverride]):
2283         (-[TestRunnerWKWebView _setStableStateOverride:]):
2284
2285 2016-11-18  Simon Fraser  <simon.fraser@apple.com>
2286
2287         Make it possible to test non-stable-state scrolling on iOS
2288         https://bugs.webkit.org/show_bug.cgi?id=164905
2289
2290         Reviewed by Dan Bernstein.
2291
2292         Make it possible for an iOS layout test to force every visible rect update
2293         from the UI process to the web process to be in a non-stable state. This emulates
2294         what happens during panning and zooming interactions, and allows us to test the
2295         scrolling and layer trees in these transient states.
2296         
2297         This is done by adding a testing property on WKWebView, _stableStateOverride, whose
2298         getters and setters are overridden in TestRunnerWKWebView. When non-nil, we _updateVisibleContentRectAfterScrollInView
2299         consults the NSNumber's boolValue and uses it to override the stable state.
2300         
2301         To facilitate this kind of testing, also add immediateScrollToOffset() and
2302         immediateZoomToScale() to UIScriptController. Finally, add doAfterPresentationUpdate()
2303         which provides a callback that fires after one trip to the web process and back.
2304         
2305         Add code generation support for optional boolean attributes in IDL.
2306
2307         Align CodeGeneratorDumpRenderTree.pm and CodeGeneratorTestRunner.pm.
2308
2309         * DumpRenderTree/Bindings/CodeGeneratorDumpRenderTree.pm:
2310         (_generateImplementationFile):
2311         (_platformTypeConstructor):
2312         (_returnExpression):
2313         * DumpRenderTree/ios/UIScriptControllerIOS.mm:
2314         (WTR::UIScriptController::doAfterPresentationUpdate):
2315         (WTR::contentOffsetBoundedInValidRange):
2316         (WTR::UIScriptController::scrollToOffset):
2317         (WTR::UIScriptController::immediateScrollToOffset):
2318         (WTR::UIScriptController::immediateZoomToScale):
2319         (WTR::UIScriptController::stableStateOverride):
2320         (WTR::UIScriptController::setStableStateOverride):
2321         * DumpRenderTree/mac/UIScriptControllerMac.mm:
2322         (WTR::UIScriptController::doAfterPresentationUpdate):
2323         * TestRunnerShared/Bindings/JSWrappable.h:
2324         (WTR::JSValueMakeBooleanOrNull):
2325         (WTR::JSValueToNullableBoolean):
2326         * TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
2327         * TestRunnerShared/UIScriptContext/UIScriptController.cpp:
2328         (WTR::UIScriptController::immediateScrollToOffset):
2329         (WTR::UIScriptController::immediateZoomToScale):
2330         (WTR::UIScriptController::stableStateOverride):
2331         (WTR::UIScriptController::setStableStateOverride):
2332         * TestRunnerShared/UIScriptContext/UIScriptController.h:
2333         * WebKitTestRunner/InjectedBundle/Bindings/CodeGeneratorTestRunner.pm:
2334         (_classRefGetter):
2335         (_platformTypeConstructor):
2336         (_returnExpression):
2337         * WebKitTestRunner/cocoa/TestRunnerWKWebView.mm:
2338         (-[TestRunnerWKWebView dealloc]):
2339         (-[TestRunnerWKWebView _stableStateOverride]):
2340         (-[TestRunnerWKWebView _setStableStateOverride:]):
2341         * WebKitTestRunner/ios/TestControllerIOS.mm:
2342         (WTR::TestController::platformResetStateToConsistentValues):
2343         * WebKitTestRunner/ios/UIScriptControllerIOS.mm:
2344         (WTR::UIScriptController::doAsyncTask):
2345         (WTR::UIScriptController::doAfterPresentationUpdate):
2346         (WTR::UIScriptController::zoomToScale):
2347         (WTR::UIScriptController::immediateScrollToOffset):
2348         (WTR::UIScriptController::immediateZoomToScale):
2349         (WTR::UIScriptController::stableStateOverride):
2350         (WTR::UIScriptController::setStableStateOverride):
2351         * WebKitTestRunner/mac/UIScriptControllerMac.mm:
2352         (WTR::UIScriptController::doAfterPresentationUpdate):
2353
2354 2016-11-19  Joanmarie Diggs  <jdiggs@igalia.com>
2355
2356         AX: [ATK] Expose aria-busy via ATK_STATE_BUSY
2357         https://bugs.webkit.org/show_bug.cgi?id=164909
2358
2359         Reviewed by Chris Fleizach.
2360
2361         Implement boolAttributeValue() for ATK so we can test AXElementBusy.
2362
2363         * WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
2364         (WTR::AccessibilityUIElement::boolAttributeValue):
2365
2366 2016-11-18  Simon Fraser  <simon.fraser@apple.com>
2367
2368         [iOS WK2] Eliminate a source of flakiness in layout tests by forcing WebPage into "responsive" mode for all tests, with an internals override
2369         https://bugs.webkit.org/show_bug.cgi?id=164980
2370
2371         Reviewed by Chris Dumez.
2372
2373         * WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
2374         (WTR::InjectedBundlePage::prepare):
2375
2376 2016-11-18  Dean Jackson  <dino@apple.com>
2377
2378         AX: "(inverted-colors)" media query only matches on page reload; should match on change
2379         https://bugs.webkit.org/show_bug.cgi?id=163564
2380         <rdar://problem/28807350>
2381
2382         Reviewed by Simon Fraser.
2383
2384         Add a UIScriptController method that tricks WebKit into thinking
2385         it has received a notification that accessibility settings have
2386         changed. Combined with our forced overrides, this allows us to
2387         test if a page would react to the notifications.
2388
2389         * DumpRenderTree/ios/UIScriptControllerIOS.mm:
2390         (WTR::UIScriptController::simulateAccessibilitySettingsChangeNotification):
2391         * DumpRenderTree/mac/UIScriptControllerMac.mm:
2392         (WTR::UIScriptController::simulateAccessibilitySettingsChangeNotification):
2393         * TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
2394         * TestRunnerShared/UIScriptContext/UIScriptController.cpp:
2395         (WTR::simulateAccessibilitySettingsChangeNotification):
2396         * TestRunnerShared/UIScriptContext/UIScriptController.h:
2397         * WebKitTestRunner/ios/UIScriptControllerIOS.mm:
2398         (WTR::UIScriptController::simulateAccessibilitySettingsChangeNotification):
2399         * WebKitTestRunner/mac/UIScriptControllerMac.mm:
2400         (WTR::UIScriptController::simulateAccessibilitySettingsChangeNotification):
2401
2402 2016-11-18  Alex Christensen  <achristensen@webkit.org>
2403
2404         Fix API test after r208902
2405         https://bugs.webkit.org/show_bug.cgi?id=144194
2406
2407         * TestWebKitAPI/Tests/Cocoa/URLExtras.mm:
2408         (TestWebKitAPI::TEST):
2409         The fullwidth solidus, U+FF0F, changed encoding from IDN2003 to IDN2008, probably to prevent domains from using it
2410         to spoof other domains.  https://webkit.org/blog/ and https://webkit.org\uFF0Fblog/ would otherwise look 
2411         too similar when rendered.
2412
2413 2016-11-17  Alex Christensen  <achristensen@webkit.org>
2414
2415         Support IDN2008 with UTS #46 instead of IDN2003
2416         https://bugs.webkit.org/show_bug.cgi?id=144194
2417
2418         Reviewed by Darin Adler.
2419
2420         * TestWebKitAPI/Tests/WebCore/URLParser.cpp:
2421         (TestWebKitAPI::TEST_F):
2422         Add some tests from http://unicode.org/faq/idn.html verifying that we follow UTS46's deviations from IDN2008.
2423         Add some tests based on https://tools.ietf.org/html/rfc5893 verifying that we check for bidirectional text.
2424         Add a test based on https://tools.ietf.org/html/rfc5892 verifying that we do not do ContextO check.
2425         Add a test for U+321D and U+321E which have particularly interesting punycode encodings.  We match Firefox here now.
2426         Also add a test from http://www.unicode.org/reports/tr46/#IDNAComparison verifying we are not using IDN2003.
2427         We should consider importing all of http://www.unicode.org/Public/idna/9.0.0/IdnaTest.txt as URL domain tests.
2428
2429 2016-11-17  Carlos Garcia Campos  <cgarcia@igalia.com>
2430
2431         Downloads started by context menu actions should also have a web view associated
2432         https://bugs.webkit.org/show_bug.cgi?id=164364
2433
2434         Reviewed by Michael Catanzaro.
2435
2436         Add a GTK+ unit tests to check that downloads started by the context menu have a web view associated.
2437
2438         * TestWebKitAPI/Tests/WebKit2Gtk/TestDownloads.cpp:
2439         (downloadLocalFileSuccessfully):
2440         (testDownloadOverwriteDestinationDisallowed):
2441         (testDownloadLocalFileError):
2442         (testDownloadRemoteFile):
2443         (testDownloadRemoteFileError):
2444         (testDownloadMIMEType):
2445         (contextMenuCallback):
2446         (testContextMenuDownloadActions):
2447         (beforeAll):
2448
2449 2016-11-17  Ryosuke Niwa  <rniwa@webkit.org>
2450
2451         Add an experimental API to find elements across shadow boundaries
2452         https://bugs.webkit.org/show_bug.cgi?id=164851
2453         <rdar://problem/28220092>
2454
2455         Reviewed by Sam Weinig.
2456
2457         Added test cases for window.collectMatchingElementsInFlatTree to WebKit2.InjectedBundleMakeAllShadowRootOpen.
2458
2459         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
2460         * TestWebKitAPI/Tests/WebKit2/InjectedBundleMakeAllShadowRoot*s*Open_Bundle.cpp: Renamed
2461         from InjectedBundleMakeAllShadowRootOpen_Bundle.cpp.
2462         (TestWebKitAPI::InjectedBundleMakeAllShadowRootOpenTest::initialize): Added test cases for
2463         window.collectMatchingElementsInFlatTree by calling alert() many times.
2464         * TestWebKitAPI/Tests/WebKit2/InjectedBundleMakeAllShadowRootsOpen.cpp:
2465         (TestWebKitAPI::runJavaScriptAlert): Added expectations for multiple test cases. Each test case
2466         finishes with a call to alert, and moves testNumber forward.
2467         (TestWebKitAPI::TEST): Use the newly added closed-shadow-tree-test.html
2468         * TestWebKitAPI/Tests/WebKit2/closed-shadow-tree-test.html: Added. Creates a shadow tree with slots
2469         and tests that window.collectMatchingElementsInFlatTree is not present when
2470         an event named "testnormalworld" is dispatched by the injected bundle.
2471
2472 2016-11-17  Brady Eidson  <beidson@apple.com>
2473
2474         Add _WKIconLoadingDelegate SPI.
2475         https://bugs.webkit.org/show_bug.cgi?id=164894
2476
2477         Reviewed by Alex Christensen.
2478
2479         Add MiniBrowser support for this new SPI, configurable with a setting.
2480
2481         * MiniBrowser/mac/SettingsController.h:
2482         * MiniBrowser/mac/SettingsController.m:
2483         (-[SettingsController _populateMenu]):
2484         (-[SettingsController validateMenuItem:]):
2485         (-[SettingsController loadsAllSiteIcons]):
2486         (-[SettingsController toggleLoadsAllSiteIcons:]):
2487         * MiniBrowser/mac/WK2BrowserWindowController.m:
2488         (-[WK2BrowserWindowController awakeFromNib]):
2489         (-[WK2BrowserWindowController webView:shouldLoadIconWithParameters:completionHandler:]):
2490
2491 2016-11-17  Caitlin Potter  <caitp@igalia.com>
2492
2493         [JSC] remove leftover references to ES2017_ASYNCFUNCTION_SYNTAX flag
2494         https://bugs.webkit.org/show_bug.cgi?id=164879
2495
2496         Reviewed by Alex Christensen.
2497
2498         The flag was referenced in FeatureList.pm and in one of the
2499         FeatureDefines.xcconfig files, despite being removed.
2500
2501         * Scripts/webkitperl/FeatureList.pm:
2502         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
2503
2504 2016-11-17  Per Arne Vollan  <pvollan@apple.com>
2505
2506         [Win] run-api-tests is failing.
2507         https://bugs.webkit.org/show_bug.cgi?id=164818
2508
2509         Reviewed by Alexey Proskuryakov.
2510
2511         Make sure Visual Studio interprets string literal as utf8.
2512  
2513         * TestWebKitAPI/Tests/WebCore/URLParser.cpp:
2514         (TestWebKitAPI::TEST_F):
2515
2516 2016-11-17  Yusuke Suzuki  <utatane.tea@gmail.com>
2517
2518         [JSC] WTF::TemporaryChange with WTF::SetForScope
2519         https://bugs.webkit.org/show_bug.cgi?id=164761
2520
2521         Reviewed by Saam Barati.
2522
2523         * TestWebKitAPI/CMakeLists.txt:
2524         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
2525         * TestWebKitAPI/Tests/WTF/SetForScope.cpp: Renamed from Tools/TestWebKitAPI/Tests/WTF/TemporaryChange.cpp.
2526         (TestWebKitAPI::TEST):
2527         * WebKitTestRunner/TestController.cpp:
2528         (WTR::TestController::resetStateToConsistentValues):
2529
2530 2016-11-16  Alexey Proskuryakov  <ap@apple.com>
2531
2532         REGRESSION (r208455): LayoutTests swipe/pushState-cached-back-swipe.html and swipe/main-frame-pinning-requirement.html are failing
2533         https://bugs.webkit.org/show_bug.cgi?id=164572
2534
2535         Reviewed by Tim Horton.
2536
2537         * WebKitTestRunner/mac/TestControllerMac.mm: (WTR::TestController::platformResetStateToConsistentValues):
2538         Use the correct constant.
2539
2540 2016-11-16  Yusuke Suzuki  <utatane.tea@gmail.com>
2541
2542         [ES6][WebCore] Change ES6_MODULES compile time flag to runtime flag
2543         https://bugs.webkit.org/show_bug.cgi?id=164827
2544
2545         Reviewed by Ryosuke Niwa.
2546
2547         Enabled ES6 Modules in test runners.
2548
2549         * DumpRenderTree/mac/DumpRenderTree.mm:
2550         (resetWebPreferencesToConsistentValues):
2551         * DumpRenderTree/win/DumpRenderTree.cpp:
2552         (resetWebPreferencesToConsistentValues):
2553         * Scripts/webkitperl/FeatureList.pm:
2554         * TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
2555         * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
2556         (WTR::InjectedBundle::beginTesting):
2557         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
2558         (WTR::TestRunner::setES6ModulesEnabled):
2559         * WebKitTestRunner/InjectedBundle/TestRunner.h:
2560
2561 2016-11-16  Simon Fraser  <simon.fraser@apple.com>
2562
2563         Hard to write reliable UIScriptController scrollingTreeAsText tests
2564         https://bugs.webkit.org/show_bug.cgi?id=164764
2565
2566         Reviewed by Wenson Hsieh.
2567
2568         Fix one cause of flakiness by resetting the WKWebView's UIScrollView scale
2569         and scroll position between tests.
2570
2571         * WebKitTestRunner/ios/TestControllerIOS.mm:
2572         (WTR::TestController::platformResetStateToConsistentValues):
2573
2574 2016-11-16  Simon Fraser  <simon.fraser@apple.com>
2575
2576         UIScriptController: script with no async tasks fails if an earlier script registered a callback
2577         https://bugs.webkit.org/show_bug.cgi?id=164762
2578
2579         Reviewed by Wenson Hsieh.
2580         
2581         Make TestRunner::callUIScriptCallback() async in DumpRenderTree to match WebKitTestRunner behavior.
2582         This fixes ui-side-script-with-callback.html in WK1, which failed because the second runUIScript()
2583         would occur inside the completion callback from the first. This no longer happens.
2584
2585         * DumpRenderTree/TestRunner.cpp:
2586         (TestRunner::callUIScriptCallback):
2587         * TestRunnerShared/UIScriptContext/UIScriptContext.cpp:
2588         (UIScriptContext::tryToCompleteUIScriptForCurrentParentCallback):
2589
2590 2016-11-16  Ryan Haddad  <ryanhaddad@apple.com>
2591
2592         Unreviewed, rolling out r208770.
2593
2594         The test added with this change is timing out on mac-wk1.
2595
2596         Reverted changeset:
2597
2598         "UIScriptController: script with no async tasks fails if an
2599         earlier script registered a callback"
2600         https://bugs.webkit.org/show_bug.cgi?id=164762
2601         http://trac.webkit.org/changeset/208770
2602
2603 2016-11-16  Per Arne Vollan  <pvollan@apple.com>
2604
2605         [Win] WebCore test is failing.
2606         https://bugs.webkit.org/show_bug.cgi?id=164772
2607
2608         Reviewed by Brent Fulgham.
2609
2610         The value of CGRectInfinite is not the same on Windows as on Mac.
2611
2612         * TestWebKitAPI/Tests/WebCore/FloatRect.cpp:
2613         (TestWebKitAPI::TEST):
2614
2615 2016-11-15  Alexey Proskuryakov  <ap@apple.com>
2616
2617         Update Youenn's e-mail addresses.
2618
2619         * Scripts/webkitpy/common/config/contributors.json:
2620
2621 2016-11-15  Simon Fraser  <simon.fraser@apple.com>
2622
2623         UIScriptController: script with no async tasks fails if an earlier script registered a callback
2624         https://bugs.webkit.org/show_bug.cgi?id=164762
2625
2626         Reviewed by Wenson Hsieh.
2627         
2628         UIScriptContext::runUIScript() considers a script to be "immediate" if that script doesn't
2629         queue any async tasks. However, if an earlier UI script registered a callback, UIScriptContext::runUIScript()
2630         would consider that an outstanding task.
2631         
2632         Fix by unregistering any callbacks associated with the current UI script when uiScriptComplete() is called.
2633
2634         * TestRunnerShared/UIScriptContext/UIScriptContext.cpp:
2635         (UIScriptContext::tryToCompleteUIScriptForCurrentParentCallback):
2636
2637 2016-11-15  Simon Fraser  <simon.fraser@apple.com>
2638
2639         UIScriptController: setting a callback to undefined should unregister it
2640         https://bugs.webkit.org/show_bug.cgi?id=164796
2641
2642         Reviewed by Dean Jackson.
2643         
2644         "Immediate" UI scripts (those that don't schedule any async tasks) should return
2645         immediately, without the need to call uiScriptComplete(). However, this is broken if
2646         an earlier UI script registered a callback (since no-one clears that callback after the
2647         first script completes).
2648
2649         Make possible the workaround of setting the callback to undefined, which previously did
2650         not clear the callback registration.
2651
2652         * TestRunnerShared/UIScriptContext/UIScriptContext.cpp:
2653         (UIScriptContext::registerCallback):
2654         * TestRunnerShared/UIScriptContext/UIScriptContext.h:
2655         * WebKitTestRunner/ios/UIScriptControllerIOS.mm:
2656         (WTR::UIScriptController::platformClearAllCallbacks):
2657
2658 2016-11-14  Mark Lam  <mark.lam@apple.com>
2659
2660         Enhance run-jsc-stress-test script to allow optional test specific options to be added for all test run configurations.
2661         https://bugs.webkit.org/show_bug.cgi?id=164695
2662
2663         Reviewed by Keith Miller.
2664
2665         This gives us more flexibility when specific tests needs to enable special JSC
2666         options in order to exercise specific code paths to be tested.  It also saves us
2667         from having to create duplicate test run configurations e.g. runMiscFTLNoCJITTest.
2668         We can now just use runFTLNoCJIT in its place.
2669
2670         Also replaced the ifJSCArgIsntProvidedAreWeReleaseBuild variable with $buildType
2671         so that we have the ability to skip certain tests for release or debug builds.
2672         This will be needed in the upcoming patch for https://webkit.org/b/155145.
2673
2674         * Scripts/run-jsc-stress-tests:
2675
2676 2016-11-14  Joanmarie Diggs  <jdiggs@igalia.com>
2677
2678         AX: [ATK] Expose STATE_SINGLE_LINE and STATE_MULTI_LINE for ARIA searchbox role
2679         https://bugs.webkit.org/show_bug.cgi?id=164712
2680
2681         Reviewed by Chris Fleizach.
2682
2683         Add AccessibilityUIElement::isSingleLine, AccessibilityUIElement::isMultiLine
2684         to DRT and WKTR. Implement it for ATK.
2685
2686         * DumpRenderTree/AccessibilityUIElement.h:
2687         * DumpRenderTree/ios/AccessibilityUIElementIOS.mm:
2688         (AccessibilityUIElement::isSingleLine):
2689         (AccessibilityUIElement::isMultiLine):
2690         * DumpRenderTree/mac/AccessibilityUIElementMac.mm:
2691         (AccessibilityUIElement::isSingleLine):
2692         (AccessibilityUIElement::isMultiLine):
2693         * DumpRenderTree/win/AccessibilityUIElementWin.cpp:
2694         (AccessibilityUIElement::isSingleLine):
2695         (AccessibilityUIElement::isMultiLine):
2696         * WebKitTestRunner/InjectedBundle/AccessibilityUIElement.h:
2697         * WebKitTestRunner/InjectedBundle/Bindings/AccessibilityUIElement.idl:
2698         * WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
2699         (WTR::AccessibilityUIElement::isSingleLine):
2700         (WTR::AccessibilityUIElement::isMultiLine):
2701         * WebKitTestRunner/InjectedBundle/ios/AccessibilityUIElementIOS.mm:
2702         (WTR::AccessibilityUIElement::isSingleLine):
2703         (WTR::AccessibilityUIElement::isMultiLine):
2704         * WebKitTestRunner/InjectedBundle/mac/AccessibilityUIElementMac.mm:
2705         (WTR::AccessibilityUIElement::isSingleLine):
2706         (WTR::AccessibilityUIElement::isMultiLine):
2707
2708 2016-11-14  Youenn Fablet  <youenn@apple.com>
2709
2710         Support WPT templated tests
2711         https://bugs.webkit.org/show_bug.cgi?id=164707
2712
2713         Reviewed by Sam Weinig.
2714
2715         * Scripts/webkitpy/w3c/test_importer.py:
2716         (TestImporter.write_html_files_for_templated_js_tests): Generating empty HTML files for templated JS tests.
2717         (TestImporter.import_tests):
2718
2719 2016-11-13  JF Bastien  <jfbastien@apple.com>
2720
2721         Implement WTF::Expected
2722         https://bugs.webkit.org/show_bug.cgi?id=164526
2723
2724         Reviewed by Yusuke Suzuki.
2725
2726         std::expected isn't in C++17, and may be in C++20. It's a nice
2727         complement to std::any / std::optional because it's a type-tagged
2728         union which has a single expected result but could also contain an
2729         error.
2730
2731         This would be useful in the WebAssembly parser, for example.
2732
2733         Using this implementation will allow us to provide feedback to the
2734         standards committee and guide std::expected's design before it
2735         gets standardized. I've already sent a bunch of feedback to the
2736         author based on my experience implementing this.
2737
2738         This could supplement WTF::Either and WTF::ExceptionOr.
2739
2740         * TestWebKitAPI/CMakeLists.txt:
2741         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
2742         * TestWebKitAPI/Tests/WTF/Expected.cpp: Added.
2743         (WTF::operator<<):
2744         (TestWebKitAPI::TEST):
2745         (TestWebKitAPI::foo::foo):
2746         (TestWebKitAPI::foo::~foo):
2747         (TestWebKitAPI::foo::operator==):
2748         (TestWebKitAPI::operator<<):
2749
2750 2016-11-12  Simon Fraser  <simon.fraser@apple.com>
2751
2752         Add a way to get the UI-side scrolling tree as text via UIScriptController
2753         https://bugs.webkit.org/show_bug.cgi?id=164697
2754
2755         Reviewed by Zalan Bujtas.
2756
2757         Add UIScriptController::scrollingTreeAsText(), which gets the state of the scrolling
2758         tree in the UI process, including the current positions of CALayers. This will be used
2759         to test UI-side scrolling and visual viewports.
2760
2761         * DumpRenderTree/ios/UIScriptControllerIOS.mm:
2762         (WTR::UIScriptController::scrollingTreeAsText):
2763         * TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
2764         * TestRunnerShared/UIScriptContext/UIScriptController.cpp:
2765         (WTR::UIScriptController::scrollingTreeAsText):
2766         * TestRunnerShared/UIScriptContext/UIScriptController.h:
2767         * WebKitTestRunner/ios/UIScriptControllerIOS.mm:
2768         (WTR::UIScriptController::scrollingTreeAsText):
2769
2770 2016-11-12  Wenson Hsieh  <wenson_hsieh@apple.com>
2771
2772         The main content heuristic should be robust when handling large media elements
2773         https://bugs.webkit.org/show_bug.cgi?id=164676
2774         <rdar://problem/29211503>
2775
2776         Reviewed by Eric Carlson.
2777
2778         Added a new test verifying that enormous video elements are handled gracefully when put through the main
2779         content heuristic.
2780
2781         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
2782         * TestWebKitAPI/Tests/WebKit2Cocoa/VideoControlsManager.mm:
2783         (TestWebKitAPI::TEST):
2784         * TestWebKitAPI/Tests/WebKit2Cocoa/enormous-video-with-sound.html: Added.
2785
2786 2016-11-12  Dan Bernstein  <mitz@apple.com>
2787
2788         run-safari does not work for open source contributors
2789         https://bugs.webkit.org/show_bug.cgi?id=164667
2790         <rdar://problem/29229894>
2791
2792         Reviewed by Joseph Pecoraro.
2793
2794         * Scripts/run-api-tests:
2795         (archCommandLineArgumentsForRestrictedEnvironmentVariables): Moved from here…
2796         * Scripts/webkitdirs.pm:
2797         (archCommandLineArgumentsForRestrictedEnvironmentVariables): …to here
2798         (runMacWebKitApp): Have arch(1) carry the DYLD_* variables we set in our environmet over
2799           to the environment of the app being run.
2800
2801 2016-11-11  Joseph Pecoraro  <pecoraro@apple.com>
2802
2803         Removed unused INCLUDE_OPTIONS_FOR_DEBUGGING
2804         https://bugs.webkit.org/show_bug.cgi?id=164664
2805
2806         Reviewed by Dan Bernstein.
2807
2808         * Scripts/debug-minibrowser:
2809         * Scripts/debug-safari:
2810         * Scripts/debug-test-runner:
2811         * Scripts/webkitdirs.pm:
2812         (printHelpAndExitForRunAndDebugWebKitAppIfNeeded):
2813         There are no debug specific options anymore.
2814
2815 2016-11-11  Wenson Hsieh  <wenson_hsieh@apple.com>
2816
2817         [WK2] autocorrect and autocapitalize attributes do not work in contenteditable elements
2818         https://bugs.webkit.org/show_bug.cgi?id=164538
2819         <rdar://problem/8418711>
2820
2821         Reviewed by Ryosuke Niwa.
2822
2823         Adds support for being able to test autocorrect and autocapitalize attributes in contenteditable areas. To do
2824         this, we add removeAllDynamicDictionaries to UIScriptController in order to ensure that autocorrect suggestions
2825         are reset to their defaults prior to running contenteditable-autocorrect-off.html.
2826
2827         * DumpRenderTree/ios/UIScriptControllerIOS.mm:
2828         (WTR::UIScriptController::removeAllDynamicDictionaries):
2829         * Scripts/webkitpy/port/ios.py:
2830         (IOSSimulatorPort._createSimulatorApp):
2831         * TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
2832         * TestRunnerShared/UIScriptContext/UIScriptController.cpp:
2833         (WTR::UIScriptController::removeAllDynamicDictionaries):
2834         * TestRunnerShared/UIScriptContext/UIScriptController.h:
2835         * WebKitTestRunner/cocoa/TestRunnerWKWebView.mm:
2836         (-[TestRunnerWKWebView _keyboardDidShow:]):
2837         (-[TestRunnerWKWebView _keyboardDidHide:]):
2838
2839         Work around an issue where consecutive UIKeyboardDidShowNotification would cause keyboard appearance callbacks
2840         to be fired multiple times. This was causing a single key press to cause two characters to be typed. While this
2841         does not affect the correctness of existing tests, the new autocorrection test requires this workaround.
2842
2843         * WebKitTestRunner/ios/UIKitSPI.h:
2844         * WebKitTestRunner/ios/UIScriptControllerIOS.mm:
2845         (WTR::UIScriptController::waitForTextPredictionsViewAndSelectCandidateAtIndex):
2846         (WTR::UIScriptController::removeAllDynamicDictionaries):
2847
2848 2016-11-11  Alex Christensen  <achristensen@webkit.org>
2849
2850         Build all Mac API tests
2851         https://bugs.webkit.org/show_bug.cgi?id=164633
2852
2853         Reviewed by Gyuyoung Kim.
2854
2855         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
2856         * TestWebKitAPI/Tests/mac/NavigatorLanguage.mm:
2857
2858 2016-11-11  Alex Christensen  <achristensen@webkit.org>
2859
2860         Allow mutable lambdas in HashMap::ensure
2861         https://bugs.webkit.org/show_bug.cgi?id=164642
2862
2863         Reviewed by Sam Weinig.
2864
2865         * TestWebKitAPI/Tests/WTF/HashMap.cpp:
2866         (TestWebKitAPI::TEST):
2867
2868 2016-11-10  Wenson Hsieh  <wenson_hsieh@apple.com>
2869
2870         Composition state should be cleared when changing focus to a non-editable element
2871         https://bugs.webkit.org/show_bug.cgi?id=164595
2872         <rdar://problem/26412551>
2873
2874         Reviewed by Enrica Casucci.
2875
2876         Adds support for window.textInputController in DumpRenderTree on iOS. So far, only the methods needed for the
2877         new layout test (editing/focus-change-with-marked-text.html) are supported. These are insertText, setMarkedText,
2878         and markedRange.
2879
2880         * DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj:
2881         * DumpRenderTree/TextInputController.h: Renamed from Tools/DumpRenderTree/mac/TextInputController.h.
2882
2883         Remove the PLATFORM(MAC) guard for defining the TextInputController. Also, move the TextInputController header
2884         out of the /mac platform directory.
2885
2886         * DumpRenderTree/ios/TextInputControllerIOS.m: Added.
2887         (+[TextInputController isSelectorExcludedFromWebScript:]):
2888         (+[TextInputController webScriptNameForSelector:]):
2889         (-[TextInputController initWithWebView:]):
2890         (-[TextInputController markedRange]):
2891         (-[TextInputController insertText:]):
2892         (-[TextInputController setMarkedText:selectedFrom:length:]):
2893
2894         Introduces TextInputControllerIOS.m, which contains an iOS implementation of TextInputController. Only a subset
2895         of the methods available on the Mac version will be available on iOS for now (see above).
2896
2897         * DumpRenderTree/mac/FrameLoadDelegate.mm:
2898
2899         Remove the PLATFORM(MAC) guard for initializing the TextInputController and binding it to the window object.
2900
2901         (-[FrameLoadDelegate didClearWindowObjectInStandardWorldForFrame:]):
2902         * DumpRenderTree/mac/TextInputControllerMac.m: Renamed from Tools/DumpRenderTree/mac/TextInputController.m.
2903         (-[WebHTMLView interpretKeyEvents:]):
2904         (-[WebNSRange initWithNSRange:]):
2905         (-[WebNSRange location]):
2906         (-[WebNSRange length]):
2907         (+[WebNSRange isSelectorExcludedFromWebScript:]):
2908         (+[NSMutableAttributedString isSelectorExcludedFromWebScript:]):
2909         (+[NSMutableAttributedString webScriptNameForSelector:]):
2910         (-[NSMutableAttributedString getLength]):
2911         (-[NSMutableAttributedString ranges]):
2912         (-[NSMutableAttributedString attributeNamesAtIndex:]):
2913         (-[NSMutableAttributedString valueOfAttribute:atIndex:]):
2914         (-[NSMutableAttributedString addAttribute:value:]):
2915         (-[NSMutableAttributedString addAttribute:value:from:length:]):
2916         (-[NSMutableAttributedString addColorAttribute:red:green:blue:alpha:]):
2917         (-[NSMutableAttributedString addColorAttribute:red:green:blue:alpha:from:length:]):
2918         (-[NSMutableAttributedString addFontAttribute:fontName:size:]):
2919         (-[NSMutableAttributedString addFontAttribute:fontName:size:from:length:]):
2920         (+[TextInputController isSelectorExcludedFromWebScript:]):
2921         (+[TextInputController webScriptNameForSelector:]):
2922         (-[TextInputController initWithWebView:]):
2923         (-[TextInputController dealloc]):
2924         (-[TextInputController textInput]):
2925         (-[TextInputController insertText:]):
2926         (-[TextInputController doCommand:]):
2927         (-[TextInputController setMarkedText:selectedFrom:length:]):
2928         (-[TextInputController unmarkText]):
2929         (-[TextInputController hasMarkedText]):
2930         (-[TextInputController conversationIdentifier]):
2931         (-[TextInputController substringFrom:length:]):
2932         (-[TextInputController attributedSubstringFrom:length:]):
2933         (-[TextInputController legacyAttributedString:]):
2934         (-[TextInputController markedRange]):
2935         (-[TextInputController selectedRange]):
2936         (-[TextInputController firstRectForCharactersFrom:length:]):
2937         (-[TextInputController characterIndexForPointX:Y:]):
2938         (-[TextInputController validAttributesForMarkedText]):
2939         (-[TextInputController attributedStringWithString:]):
2940         (-[TextInputController stringWithUndoGroupingInsertion:]):
2941         (-[TextInputController dictatedStringWithPrimaryString:alternative:alternativeOffset:alternativeLength:]):
2942         (-[TextInputController setInputMethodHandler:]):
2943         (-[TextInputController interpretKeyEvents:withSender:]):
2944
2945         Fixes miscellaneous style issues.
2946
2947 2016-11-11  Philippe Normand  <pnormand@igalia.com>
2948
2949         [GTK][JHbuild] bump libnice version in openwebrtc.modules
2950         https://bugs.webkit.org/show_bug.cgi?id=164586
2951
2952         Reviewed by Michael Catanzaro.
2953
2954         Update to a recent libnice git snapshot and remove patches already
2955         upstream or not applying anymore. The patches not upstream yet
2956         will be reported in Phabricator.
2957
2958         * gtk/openwebrtc.modules:
2959         * gtk/patches/libnice-0001-agent-Remove-unnecessary-NULL-check.patch: Removed.
2960         * gtk/patches/libnice-0002-Do-not-update-a-remote-candidate-s-type.patch: Removed.
2961         * gtk/patches/libnice-0002-TURN-handle-437-Allocation-Mismatch-responses.patch: Removed.
2962         * gtk/patches/libnice-0003-Do-not-compare-scope-for-IPv6-address-when-scope-is-.patch: Removed.
2963         * gtk/patches/libnice-0004-Removing-no-op-assignment.patch: Removed.
2964
2965 2016-11-10  Alex Christensen  <achristensen@webkit.org>
2966
2967         Fix assertion after r208534.
2968         https://bugs.webkit.org/show_bug.cgi?id=160497
2969
2970         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
2971         * TestWebKitAPI/Tests/mac/MemoryPressureHandler.mm: Added.
2972         (TestWebKitAPI::TEST):
2973         Add a regression test.
2974
2975 2016-11-10  Chris Dumez  <cdumez@apple.com>
2976
2977         REGRESSION (r208522): LayoutTest fast/loader/reload-zero-byte-plugin.html is a flaky failure
2978         https://bugs.webkit.org/show_bug.cgi?id=164570
2979
2980         Reviewed by Simon Fraser.
2981
2982         Properly reset TestController::m_shouldDownloadUndisplayableMIMETypes between tests to
2983         avoid flakiness.
2984
2985         * WebKitTestRunner/TestController.cpp:
2986         (WTR::TestController::resetStateToConsistentValues):
2987
2988 2016-11-10  Miguel Gomez  <magomez@igalia.com>
2989
2990         Unreviewed. Added myself to the list of committers.
2991
2992         * Scripts/webkitpy/common/config/contributors.json:
2993
2994 2016-10-27  Sergio Villar Senin  <svillar@igalia.com>
2995
2996         [GTK] New API to notify about dynamically added forms
2997         https://bugs.webkit.org/show_bug.cgi?id=164050
2998
2999         Reviewed by Carlos Garcia Campos.
3000
3001         Added a new test case to verify that dinamically added forms correctly trigger the
3002         "form-controls-associated" signal from WebPage.
3003
3004         * TestWebKitAPI/Tests/WebKit2Gtk/TestWebExtensions.cpp:
3005         (didAssociateFormControlsCallback):
3006         (testWebExtensionFormControlsAssociated):
3007         (beforeAll):
3008         * TestWebKitAPI/Tests/WebKit2Gtk/WebExtensionTest.cpp:
3009         (DelayedSignal::DelayedSignal):
3010         (emitFormControlsAssociated):
3011         (formControlsAssociatedCallback):
3012         (pageCreatedCallback):
3013
3014 2016-11-09  Ryosuke Niwa  <rniwa@webkit.org>
3015
3016         WebHTMLView's _attributeStringFromDOMRange should use HTMLConverter instead of NSAttributedString's _initWithDOMRange
3017         https://bugs.webkit.org/show_bug.cgi?id=164501
3018         <rdar://problem/29152282>
3019
3020         Reviewed by Sam Weinig.
3021
3022         * DumpRenderTree/mac/TextInputController.m:
3023         (-[TextInputController legacyAttributedString:]):
3024
3025 2016-11-09  Chris Dumez  <cdumez@apple.com>
3026
3027         [WK2][NETWORK_SESSION] Add support for downloading file backed blobs
3028         https://bugs.webkit.org/show_bug.cgi?id=164458
3029         <rdar://problem/28905514>
3030
3031         Reviewed by Darin Adler.
3032
3033         Add testRunner.setShouldDownloadUndisplayableMIMETypes(bool) API so that layout
3034         tests can request that such resources are downloaded instead of being ignored.
3035
3036         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
3037         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
3038         (WTR::TestRunner::setShouldDownloadUndisplayableMIMETypes):
3039         * WebKitTestRunner/InjectedBundle/TestRunner.h:
3040         * WebKitTestRunner/TestController.cpp:
3041         (WTR::TestController::decidePolicyForNavigationResponse):
3042         * WebKitTestRunner/TestController.h:
3043         (WTR::TestController::setShouldDownloadUndisplayableMIMETypes):
3044         * WebKitTestRunner/TestInvocation.cpp:
3045         (WTR::TestInvocation::didReceiveMessageFromInjectedBundle):
3046
3047 2016-11-09  Carlos Garcia Campos  <cgarcia@igalia.com>
3048
3049         NetworkSession: Network process crash when converting main resource to download
3050         https://bugs.webkit.org/show_bug.cgi?id=164220
3051
3052         Reviewed by Alex Christensen.
3053
3054         Split /webkit2/Downloads/policy-decision-download in two, one to test the full load when main resource is
3055         converted to a download and another one to test the cancellation as the test was doing before. When doing the
3056         full load, delay a bit the decide destination to ensure the load is aborted before the data task has became a
3057         download.
3058
3059         * TestWebKitAPI/Tests/WebKit2Gtk/TestDownloads.cpp:
3060         (testPolicyResponseDownload):
3061         (testPolicyResponseDownloadCancel):
3062         (beforeAll):
3063
3064 2016-11-09  KwangHyuk Kim  <hyuki.kim@samsung.com>
3065
3066         [EFL] fix error message caused by eina log
3067         https://bugs.webkit.org/show_bug.cgi?id=164546
3068
3069         Reviewed by Gyuyoung Kim.
3070
3071         Fix error message caused by eina log when MiniBrowser is working with help option.
3072
3073         * MiniBrowser/efl/main.c:
3074         (quit):
3075
3076 2016-11-09  Brent Fulgham  <bfulgham@apple.com>
3077
3078         Unreviewed build fix after r208509.
3079
3080         * DumpRenderTree/win/TestRunnerWin.cpp:
3081         (TestRunner::setNeedsStorageAccessFromFileURLsQuirk): Add missing TestRunner implementation."
3082
3083 2016-11-09  Alex Christensen  <achristensen@webkit.org>
3084
3085         Unreviewed, rolling out r208438.
3086
3087         crashes
3088
3089         Reverted changeset:
3090
3091         "[WK2][NETWORK_SESSION] Add support for downloading file
3092         backed blobs"
3093         https://bugs.webkit.org/show_bug.cgi?id=164458
3094         http://trac.webkit.org/changeset/208438
3095
3096 2016-11-04  Brent Fulgham  <bfulgham@apple.com>
3097
3098         Local HTML should be blocked from localStorage access unless "Disable Local File Restrictions" is checked
3099         https://bugs.webkit.org/show_bug.cgi?id=155185
3100         <rdar://problem/11101440>
3101
3102         Reviewed by Brady Eidson.
3103
3104         * DumpRenderTree/TestRunner.cpp:
3105         (setNeedsLocalStorageQuirkCallback): Added.
3106         (TestRunner::staticFunctions):
3107         * DumpRenderTree/TestRunner.h:
3108         * DumpRenderTree/mac/DumpRenderTree.mm:
3109         (resetWebPreferencesToConsistentValues): Update for new quirk setting.
3110         * DumpRenderTree/mac/TestRunnerMac.mm:
3111         (TestRunner::setNeedsLocalStorageQuirk):
3112         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
3113         * TestWebKitAPI/Tests/WebKit2/CloseFromWithinCreatePage.cpp:
3114         * TestWebKitAPI/Tests/WebKit2Cocoa/LocalStorageClear.mm:
3115         * TestWebKitAPI/Tests/WebKit2Cocoa/LocalStorageNullEntries.mm:
3116         * TestWebKitAPI/Tests/WebKit2Cocoa/LocalStorageQuirkEnabled.html: Added.
3117         * TestWebKitAPI/Tests/WebKit2Cocoa/LocalStorageQuirkTest.mm: Added.
3118         (-[LocalStorageQuirkMessageHandler userContentController:didReceiveScriptMessage:]):
3119         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
3120         * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
3121         (WTR::InjectedBundle::beginTesting): Update for new quirk setting.
3122         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
3123         (WTR::TestRunner::setNeedsLocalStorageQuirk): Added.
3124         * WebKitTestRunner/InjectedBundle/TestRunner.h:
3125
3126 2016-11-09  Alex Christensen  <achristensen@webkit.org>
3127
3128         URLParser should not consider path of URLs with no host to start at the first slash after the colon
3129         https://bugs.webkit.org/show_bug.cgi?id=164555
3130
3131         Reviewed by Tim Horton.
3132
3133         * TestWebKitAPI/Tests/WebCore/URLParser.cpp:
3134         (TestWebKitAPI::TEST_F):
3135
3136 2016-11-09  Jonathan Bedard  <jbedard@apple.com>
3137
3138         test-webkitpy failing test_create_patch_is_full_patch unit test
3139         https://bugs.webkit.org/show_bug.cgi?id=164385
3140
3141         Reviewed by Darin Adler.
3142
3143         * Scripts/webkitpy/common/checkout/scm/scm_unittest.py: Fixed expected output to match output.
3144
3145 2016-11-09  Chris Dumez  <cdumez@apple.com>
3146
3147         [Mac] Stop using deprecated AppKit enumeration values
3148         https://bugs.webkit.org/show_bug.cgi?id=164494
3149
3150         Reviewed by Darin Adler.
3151
3152         Stop using deprecated AppKit enumeration values.
3153
3154         * DumpRenderTree/mac/EventSendingController.mm:
3155         (eventTypeForMouseButtonAndAction):
3156         (modifierFlags):
3157         (-[EventSendingController mouseMoveToX:Y:]):
3158         (-[EventSendingController contextClick]):
3159         (-[EventSendingController keyDown:withModifiers:withLocation:]):
3160         * DumpRenderTree/mac/TextInputController.m:
3161         (-[TextInputController interpretKeyEvents:withSender:]):
3162         * TestWebKitAPI/Tests/WebKit2Cocoa/CommandBackForward.mm:
3163         (simulateCommandArrow):
3164         * TestWebKitAPI/Tests/WebKit2Cocoa/FullscreenDelegate.mm:
3165         (TestWebKitAPI::TEST):
3166         * TestWebKitAPI/Tests/WebKit2Cocoa/FullscreenLayoutConstraints.mm:
3167         (TestWebKitAPI::TEST):
3168         * TestWebKitAPI/Tests/WebKit2Cocoa/FullscreenTopContentInset.mm:
3169         (TestWebKitAPI::TEST):
3170         * TestWebKitAPI/Tests/WebKit2Cocoa/ShouldOpenExternalURLsInNewWindowActions.mm:
3171         (TEST):
3172         * TestWebKitAPI/Tests/WebKit2Cocoa/UserInitiatedActionInNavigationAction.mm:
3173         (UserInitiatedActionTest::SetUp):
3174         (UserInitiatedActionTest::click):
3175         * TestWebKitAPI/Tests/mac/AcceptsFirstMouse.mm:
3176         (TestWebKitAPI::AcceptsFirstMouse::runTest):
3177         * TestWebKitAPI/Tests/mac/ContextMenuCanCopyURL.mm:
3178         (TestWebKitAPI::contextMenuCopyLink):
3179         (TestWebKitAPI::TEST):
3180         * TestWebKitAPI/Tests/mac/ContextMenuDefaultItemsHaveTags.mm:
3181         (TestWebKitAPI::TEST):
3182         * TestWebKitAPI/Tests/mac/FullscreenZoomInitialFrame.mm:
3183         (TestWebKitAPI::FullscreenZoomInitialFrame::runTest):
3184         * TestWebKitAPI/Tests/mac/MenuTypesForMouseEvents.mm:
3185         (TestWebKitAPI::TEST):
3186         * TestWebKitAPI/mac/PlatformUtilitiesMac.mm:
3187         (TestWebKitAPI::Util::isKeyDown):
3188         * TestWebKitAPI/mac/PlatformWebViewMac.mm:
3189         (TestWebKitAPI::PlatformWebView::initialize):
3190         (TestWebKitAPI::PlatformWebView::simulateSpacebarKeyPress):
3191         (TestWebKitAPI::PlatformWebView::simulateRightClick):
3192         (TestWebKitAPI::PlatformWebView::simulateMouseMove):
3193         (TestWebKitAPI::eventTypeForButton):
3194         (TestWebKitAPI::modifierFlagsForWKModifiers):
3195         * TestWebKitAPI/mac/TestWKWebViewMac.mm:
3196         (__simulated_forceClickAssociatedEventsMask):
3197         (-[TestWKWebViewHostWindow _mouseDownAtPoint:simulatePressure:]):
3198         (-[TestWKWebView _setUpTestWindow:]):
3199         (-[TestWKWebView typeCharacter:]):
3200         * WebKitTestRunner/mac/EventSenderProxy.mm:
3201         (WTR::eventTypeForMouseButtonAndAction):
3202         (WTR::buildModifierFlags):
3203         (WTR::EventSenderProxy::sendMouseDownToStartPressureEvents):
3204         (WTR::EventSenderProxy::mouseForceClick):
3205         (WTR::EventSenderProxy::startAndCancelMouseForceClick):
3206         (WTR::EventSenderProxy::mouseMoveTo):
3207         (WTR::EventSenderProxy::keyDown):
3208         (WTR::EventSenderProxy::swipeGestureWithWheelAndMomentumPhases):
3209         * WebKitTestRunner/mac/PlatformWebViewMac.mm:
3210         (WTR::PlatformWebView::PlatformWebView):
3211         * WebKitTestRunner/mac/TestControllerMac.mm:
3212         (WTR::TestController::platformResetStateToConsistentValues):
3213
3214 2016-11-09  Beth Dakin  <bdakin@apple.com>
3215
3216         Support TouchBar in WebKit
3217         https://bugs.webkit.org/show_bug.cgi?id=164437
3218         -and corresponding-
3219         rdar://problem/28876524
3220
3221         Reviewed by Darin Adler.
3222
3223         This makes MiniBrowser support TouchBar customization. 
3224
3225         * MiniBrowser/mac/AppDelegate.m:
3226         (-[BrowserAppDelegate awakeFromNib]):
3227
3228 2016-11-09  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
3229
3230         [EFL] Use libgcrypt instead of GnuTLS for CryptoDigest
3231         https://bugs.webkit.org/show_bug.cgi?id=164461
3232
3233         Reviewed by Michael Catanzaro.
3234
3235         As GTK port in r208297, EFL port starts to use libgcrypt instead of GnuTLS as well.
3236
3237         * efl/install-dependencies: Add libgcript package dependecy.
3238
3239 2016-11-09  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
3240
3241         [EFL] Remove unused function in MiniBrowser
3242         https://bugs.webkit.org/show_bug.cgi?id=164398
3243
3244         Reviewed by Darin Adler.
3245
3246         * MiniBrowser/efl/main.c:
3247         (window_find_with_elm_window): Deleted because it is not used anywhere.
3248
3249 2016-11-09  Chris Dumez  <cdumez@apple.com>
3250
3251         [WK2][NETWORK_SESSION] Add support for downloading file backed blobs
3252         https://bugs.webkit.org/show_bug.cgi?id=164458
3253         <rdar://problem/28905514>
3254
3255         Reviewed by Darin Adler.
3256
3257         Add testRunner.setShouldDownloadUndisplayableMIMETypes(bool) API so that layout
3258         tests can request that such resources are downloaded instead of being ignored.
3259
3260         * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
3261         * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
3262         (WTR::TestRunner::setShouldDownloadUndisplayableMIMETypes):
3263         * WebKitTestRunner/InjectedBundle/TestRunner.h:
3264         * WebKitTestRunner/TestController.cpp:
3265         (WTR::TestController::decidePolicyForNavigationResponse):
3266         * WebKitTestRunner/TestController.h:
3267         (WTR::TestController::setShouldDownloadUndisplayableMIMETypes):
3268         * WebKitTestRunner/TestInvocation.cpp:
3269         (WTR::TestInvocation::didReceiveMessageFromInjectedBundle):
3270
3271 2016-11-09  Jonathan Bedard  <jbedard@apple.com>
3272
3273         Make rpaths more robust for iOS Simulators
3274         https://bugs.webkit.org/show_bug.cgi?id=164521
3275
3276         Reviewed by Simon Fraser.
3277
3278         * Scripts/webkitpy/port/ios.py:
3279         (IOSSimulatorPort._createSimulatorApp): Added more robust path.
3280
3281 2016-11-09  Csaba Osztrogonác  <ossy@webkit.org>
3282
3283         Fix Tools build on case sensitive file systems
3284         https://bugs.webkit.org/show_bug.cgi?id=164474
3285
3286         Unreviewed buildfix.
3287
3288         * DumpRenderTree/CMakeLists.txt:
3289         * DumpRenderTree/PlatformMac.cmake:
3290         * DumpRenderTree/PlatformWin.cmake:
3291         * DumpRenderTree/TestNetscapePlugIn/CMakeLists.txt:
3292         * MiniBrowser/mac/CMakeLists.txt:
3293
3294 2016-11-04  Filip Pizlo  <fpizlo@apple.com>
3295
3296         WTF::ParkingLot should stop using std::chrono because std::chrono::duration casts are prone to overflows
3297         https://bugs.webkit.org/show_bug.cgi?id=152045
3298
3299         Reviewed by Andy Estes.
3300
3301         * TestWebKitAPI/CMakeLists.txt:
3302         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
3303         * TestWebKitAPI/Tests/WTF/Condition.cpp:
3304         (TestWebKitAPI::TEST):
3305         * TestWebKitAPI/Tests/WTF/SynchronizedFixedQueue.cpp:
3306         (TestWebKitAPI::ToUpperConverter::stopProducing):
3307         (TestWebKitAPI::ToUpperConverter::stopConsuming):
3308         * TestWebKitAPI/Tests/WTF/Time.cpp: Added.
3309         (WTF::operator<<):
3310         (TestWebKitAPI::TEST):
3311
3312 2016-11-04  Alex Christensen  <achristensen@webkit.org>
3313
3314         Unreviewed, rolling out r208293.
3315
3316         asserts in API tests.
3317
3318         Reverted changeset:
3319
3320         "NetworkSession: Network process crash when converting main
3321         resource to download"
3322         https://bugs.webkit.org/show_bug.cgi?id=164220
3323         http://trac.webkit.org/changeset/208293
3324
3325 2016-11-04  Said Abou-Hallawa  <sabouhallawa@apple.com>
3326
3327         Add a setting and preferences to enable/disable async image decoding
3328         https://bugs.webkit.org/show_bug.cgi?id=164417
3329
3330         Reviewed by Simon Fraser.
3331
3332         Pref and a menu item to toggle asyncImageDecodingEnabled for WebKits 1 and 2.
3333
3334         * MiniBrowser/mac/SettingsController.h:
3335         * MiniBrowser/mac/SettingsController.m:
3336         (-[SettingsController _populateMenu]):
3337         (-[SettingsController validateMenuItem:]):
3338         (-[SettingsController toggleAsyncImageDecodingEnabled:]):
3339         (-[SettingsController asyncImageDecodingEnabled]):
3340         * MiniBrowser/mac/WK1BrowserWindowController.m:
3341         (-[WK1BrowserWindowController didChangeSettings]):
3342         * MiniBrowser/mac/WK2BrowserWindowController.m:
3343         (-[WK2BrowserWindowController didChangeSettings]):
3344
3345 2016-11-04  Brady Eidson  <beidson@apple.com>
3346
3347         REGRESSION (r208349) StringHasher::hashMemory behavior changed, causing API tests to fail
3348         https://bugs.webkit.org/show_bug.cgi?id=164390
3349
3350         Reviewed by Geoffrey Garen.
3351
3352         Operating under the assumption that the behavior change is okay/desirable, this updates the test.
3353
3354         * TestWebKitAPI/Tests/WTF/StringHasher.cpp:
3355         (TestWebKitAPI::TEST):
3356
3357 2016-11-04  Joanmarie Diggs  <jdiggs@igalia.com>
3358
3359         AX: [ATK] Attempting to clear selection on ARIA listboxes results in crash
3360         https://bugs.webkit.org/show_bug.cgi?id=164331
3361
3362         Reviewed by Chris Fleizach.
3363
3364         Add AccessibilityUIElement::clearSelectedChildren() to DRT and WKTR.
3365         Implement it for ATK.
3366
3367         * DumpRenderTree/AccessibilityUIElement.h:
3368         * DumpRenderTree/ios/AccessibilityUIElementIOS.mm:
3369         (AccessibilityUIElement::clearSelectedChildren):
3370         * DumpRenderTree/mac/AccessibilityUIElementMac.mm:
3371         (AccessibilityUIElement::clearSelectedChildren):
3372         * DumpRenderTree/win/AccessibilityUIElementWin.cpp:
3373         (AccessibilityUIElement::clearSelectedChildren):
3374         * WebKitTestRunner/InjectedBundle/AccessibilityUIElement.h:
3375         * WebKitTestRunner/InjectedBundle/Bindings/AccessibilityUIElement.idl:
3376         * WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
3377         (WTR::AccessibilityUIElement::clearSelectedChildren):
3378         * WebKitTestRunner/InjectedBundle/ios/AccessibilityUIElementIOS.mm:
3379         (WTR::AccessibilityUIElement::clearSelectedChildren):
3380         * WebKitTestRunner/InjectedBundle/mac/AccessibilityUIElementMac.mm:
3381         (WTR::AccessibilityUIElement::clearSelectedChildren):
3382
3383 2016-11-04  Per Arne Vollan  <pvollan@apple.com>
3384
3385         [Win] Page visibility tests are timing out.
3386         https://bugs.webkit.org/show_bug.cgi?id=164363
3387
3388         Reviewed by Brent Fulgham.
3389
3390         Implement methods to set page visibility.
3391
3392         * DumpRenderTree/win/TestRunnerWin.cpp:
3393         (TestRunner::resetPageVisibility):
3394         (TestRunner::setPageVisibility):
3395
3396 2016-11-03  Simon Fraser  <simon.fraser@apple.com>
3397
3398         Give all the geometry classes a single-argument scale() function for consistency
3399         https://bugs.webkit.org/show_bug.cgi?id=164400
3400
3401         Reviewed by Zalan Bujtas.
3402         
3403         Test single-argument scale().
3404
3405         * TestWebKitAPI/Tests/WebCore/FloatPoint.cpp:
3406         (TestWebKitAPI::TEST):
3407
3408 2016-11-03  Chris Dumez  <cdumez@apple.com>
3409
3410         [WK2][Cocoa] Implement user interface for HTML form validation
3411         https://bugs.webkit.org/show_bug.cgi?id=164143
3412         <rdar://problem/28944652>
3413
3414         Reviewed by Simon Fraser.
3415
3416         Add support for UIScriptController::contentsOfUserInterfaceItem("validationBubble")
3417         on both Mac and iOS to retrieve the currently displayed validation message.
3418
3419         * DumpRenderTree/mac/UIScriptControllerMac.mm:
3420         (WTR::UIScriptController::contentsOfUserInterfaceItem):
3421         * TestRunnerShared/UIScriptContext/UIScriptController.cpp:
3422         (WTR::UIScriptController::contentsOfUserInterfaceItem):
3423         (WTR::UIScriptController::selectFormAccessoryPickerRow):
3424         * WebKitTestRunner/mac/UIScriptControllerMac.mm:
3425         (WTR::UIScriptController::contentsOfUserInterfaceItem):
3426
3427 2016-11-03  Konstantin Tokarev  <annulen@yandex.ru>
3428
3429         Fixes to build JSCOnly on macOS
3430         https://bugs.webkit.org/show_bug.cgi?id=164379
3431
3432         Reviewed by Michael Catanzaro.
3433
3434         * TestWebKitAPI/PlatformJSCOnly.cmake: Moved BUILDING_JSCONLY__
3435         definition to OptionsJSCOnly.cmake
3436
3437 2016-11-03  Dan Bernstein  <mitz@apple.com>
3438
3439         WKWebView’s _observedRenderingProgressEvents not restored after web process crash
3440         https://bugs.webkit.org/show_bug.cgi?id=164368
3441         <rdar://problem/29091954>
3442
3443         Reviewed by Anders Carlsson.
3444
3445         * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
3446         * TestWebKitAPI/Tests/WebKit2Cocoa/ObservedRenderingProgressEventsAfterCrash.mm: Added.
3447         (TEST):
3448
3449 2016-11-03  Alex Christensen  <achristensen@webkit.org>
3450
3451         Purge PassRefPtr from Tools
3452         https://bugs.webkit.org/show_bug.cgi?id=164358
3453
3454         Reviewed by Michael Catanzaro.
3455
3456         * ImageDiff/efl/ImageDiff.cpp:
3457         * TestWebKitAPI/Tests/WebKit2Gtk/TestWebKitAccessibility.cpp:
3458         * WebKitTestRunner/InjectedBundle/AccessibilityController.cpp:
3459         (WTR::AccessibilityController::create):
3460         (WTR::AccessibilityController::rootElement):
3461         (WTR::AccessibilityController::focusedElement):
3462         (WTR::AccessibilityController::elementAtPoint):
3463         (WTR::AccessibilityController::addNotificationListener): Deleted.
3464         (WTR::AccessibilityController::removeNotificationListener): Deleted.
3465         (WTR::AccessibilityController::accessibleElementById): Deleted.
3466         (WTR::AccessibilityController::logAccessibilityEvents): Deleted.
3467         (WTR::AccessibilityController::resetToConsistentState): Deleted.
3468         (WTR::AccessibilityController::platformName): Deleted.
3469         * WebKitTestRunner/InjectedBundle/AccessibilityController.h:
3470         (WTR::AccessibilityController::logAccessibilityEvents):
3471         * WebKitTestRunner/InjectedBundle/AccessibilityTextMarker.cpp:
3472         (WTR::AccessibilityTextMarker::create):
3473         * WebKitTestRunner/InjectedBundle/AccessibilityTextMarker.h:
3474         * WebKitTestRunner/InjectedBundle/AccessibilityTextMarkerRange.cpp:
3475         (WTR::AccessibilityTextMarkerRange::create):
3476         * WebKitTestRunner/InjectedBundle/AccessibilityTextMarkerRange.h:
3477         * WebKitTestRunner/InjectedBundle/AccessibilityUIElement.cpp:
3478         (WTR::AccessibilityUIElement::create):
3479         (WTR::AccessibilityUIElement::linkedElement):
3480         (WTR::AccessibilityUIElement::headerElementAtIndex):
3481         (WTR::AccessibilityUIElement::fieldsetAncestorElement):
3482         (WTR::AccessibilityUIElement::characterAtOffset):
3483         (WTR::AccessibilityUIElement::wordAtOffset):
3484         (WTR::AccessibilityUIElement::lineAtOffset):
3485         (WTR::AccessibilityUIElement::sentenceAtOffset):
3486         (WTR::AccessibilityUIElement::selectedTextMarkerRange):
3487         (WTR::AccessibilityUIElement::leftWordTextMarkerRangeForTextMarker):
3488         (WTR::AccessibilityUIElement::rightWordTextMarkerRangeForTextMarker):
3489         (WTR::AccessibilityUIElement::previousWordStartTextMarkerForTextMarker):
3490         (WTR::AccessibilityUIElement::nextWordEndTextMarkerForTextMarker):
3491         (WTR::AccessibilityUIElement::paragraphTextMarkerRangeForTextMarker):
3492         (WTR::AccessibilityUIElement::nextParagraphEndTextMarkerForTextMarker):
3493         (WTR::AccessibilityUIElement::previousParagraphStartTextMarkerForTextMarker):
3494         (WTR::AccessibilityUIElement::sentenceTextMarkerRangeForTextMarker):
3495         (WTR::AccessibilityUIElement::nextSentenceEndTextMarkerForTextMarker):
3496         (WTR::AccessibilityUIElement::previousSentenceStartTextMarkerForTextMarker):
3497         (WTR::AccessibilityUIElement::AccessibilityUIElement): Deleted.
3498         (WTR::AccessibilityUIElement::~AccessibilityUIElement): Deleted.
3499         (WTR::AccessibilityUIElement::isEqual): Deleted.
3500         (WTR::AccessibilityUIElement::elementAtPoint): Deleted.
3501         (WTR::AccessibilityUIElement::childAtIndex): Deleted.
3502         (WTR::AccessibilityUIElement::indexOfChild): Deleted.
3503         (WTR::AccessibilityUIElement::childrenCount): Deleted.
3504         (WTR::AccessibilityUIElement::titleUIElement): Deleted.
3505         (WTR::AccessibilityUIElement::parentElement): Deleted.
3506         (WTR::AccessibilityUIElement::takeFocus): Deleted.
3507         (WTR::AccessibilityUIElement::takeSelection): Deleted.
3508         (WTR::AccessibilityUIElement::addSelection): Deleted.
3509         (WTR::AccessibilityUIElement::removeSelection): Deleted.
3510         (WTR::AccessibilityUIElement::allAttributes): Deleted.
3511         (WTR::AccessibilityUIElement::attributesOfLinkedUIElements): Deleted.
3512         (WTR::AccessibilityUIElement::linkedUIElementAtIndex): Deleted.
3513         (WTR::AccessibilityUIElement::attributesOfDocumentLinks): Deleted.
3514         (WTR::AccessibilityUIElement::attributesOfChildren): Deleted.
3515         (WTR::AccessibilityUIElement::parameterizedAttributeNames): Deleted.
3516         (WTR::AccessibilityUIElement::increment): Deleted.
3517         (WTR::AccessibilityUIElement::decrement): Deleted.
3518         (WTR::AccessibilityUIElement::showMenu): Deleted.
3519         (WTR::AccessibilityUIElement::press): Deleted.
3520         (WTR::AccessibilityUIElement::stringAttributeValue): Deleted.
3521         (WTR::AccessibilityUIElement::uiElementArrayAttributeValue): Deleted.
3522         (WTR::AccessibilityUIElement::uiElementAttributeValue): Deleted.
3523         (WTR::AccessibilityUIElement::numberAttributeValue): Deleted.
3524         (WTR::AccessibilityUIElement::boolAttributeValue): Deleted.
3525         (WTR::AccessibilityUIElement::isAttributeSupported): Deleted.
3526         (WTR::AccessibilityUIElement::isAttributeSettable): Deleted.
3527         (WTR::AccessibilityUIElement::isPressActionSupported): Deleted.
3528         (WTR::AccessibilityUIElement::isIncrementActionSupported): Deleted.
3529         (WTR::AccessibilityUIElement::isDecrementActionSupported): Deleted.
3530         (WTR::AccessibilityUIElement::role): Deleted.
3531         (WTR::AccessibilityUIElement::subrole): Deleted.
3532         (WTR::AccessibilityUIElement::roleDescription): Deleted.
3533         (WTR::AccessibilityUIElement::computedRoleString): Deleted.
3534         (WTR::AccessibilityUIElement::title): Deleted.
3535         (WTR::AccessibilityUIElement::description): Deleted.
3536         (WTR::AccessibilityUIElement::language): Deleted.
3537         (WTR::AccessibilityUIElement::stringValue): Deleted.
3538         (WTR::AccessibilityUIElement::accessibilityValue): Deleted.
3539         (WTR::AccessibilityUIElement::helpText): Deleted.
3540         (WTR::AccessibilityUIElement::orientation): Deleted.
3541         (WTR::AccessibilityUIElement::x): Deleted.
3542         (WTR::AccessibilityUIElement::y): Deleted.
3543         (WTR::AccessibilityUIElement::width): Deleted.
3544         (WTR::AccessibilityUIElement::height): Deleted.
3545         (WTR::AccessibilityUIElement::intValue): Deleted.
3546         (WTR::AccessibilityUIElement::minValue): Deleted.
3547         (WTR::AccessibilityUIElement::maxValue): Deleted.
3548         (WTR::AccessibilityUIElement::valueDescription): Deleted.
3549         (WTR::AccessibilityUIElement::insertionPointLineNumber): Deleted.
3550         (WTR::AccessibilityUIElement::selectedTextRange): Deleted.
3551         (WTR::AccessibilityUIElement::isEnabled): Deleted.
3552         (WTR::AccessibilityUIElement::isRequired): Deleted.
3553         (WTR::AccessibilityUIElement::isFocused): Deleted.
3554         (WTR::AccessibilityUIElement::isFocusable): Deleted.
3555         (WTR::AccessibilityUIElement::isSelected): Deleted.
3556         (WTR::AccessibilityUIElement::isSelectedOptionActive): Deleted.
3557         (WTR::AccessibilityUIElement::isSelectable): Deleted.
3558         (WTR::AccessibilityUIElement::isMultiSelectable): Deleted.
3559         (WTR::AccessibilityUIElement::setSelectedChild): Deleted.
3560         (WTR::AccessibilityUIElement::setSelectedChildAtIndex): Deleted.
3561         (WTR::AccessibilityUIElement::removeSelectionAtIndex): Deleted.
3562         (WTR::AccessibilityUIElement::selectedChildrenCount): Deleted.
3563         (WTR::AccessibilityUIElement::selectedChildAtIndex): Deleted.
3564         (WTR::AccessibilityUIElement::isExpanded): Deleted.
3565         (WTR::AccessibilityUIElement::isChecked): Deleted.
3566         (WTR::AccessibilityUIElement::isIndeterminate): Deleted.
3567         (WTR::AccessibilityUIElement::isVisible): Deleted.
3568         (WTR::AccessibilityUIElement::isOffScreen): Deleted.
3569         (WTR::AccessibilityUIElement::isCollapsed): Deleted.
3570         (WTR::AccessibilityUIElement::isIgnored): Deleted.
3571         (WTR::AccessibilityUIElement::hasPopup): Deleted.
3572         (WTR::AccessibilityUIElement::hierarchicalLevel): Deleted.
3573         (WTR::AccessibilityUIElement::clickPointX): Deleted.
3574         (WTR::AccessibilityUIElement::clickPointY): Deleted.
3575         (WTR::AccessibilityUIElement::documentEncoding): Deleted.
3576         (WTR::AccessibilityUIElement::documentURI): Deleted.
3577         (WTR::AccessibilityUIElement::url): Deleted.
3578         (WTR::AccessibilityUIElement::speak): Deleted.
3579         (WTR::AccessibilityUIElement::attributesOfColumnHeaders): Deleted.
3580         (WTR::AccessibilityUIElement::attributesOfRowHeaders): Deleted.
3581         (WTR::AccessibilityUIElement::attributesOfColumns): Deleted.
3582         (WTR::AccessibilityUIElement::attributesOfRows): Deleted.
3583         (WTR::AccessibilityUIElement::attributesOfVisibleCells): Deleted.
3584         (WTR::AccessibilityUIElement::attributesOfHeader): Deleted.
3585         (WTR::AccessibilityUIElement::indexInTable): Deleted.
3586         (WTR::AccessibilityUIElement::rowIndexRange): Deleted.
3587         (WTR::AccessibilityUIElement::columnIndexRange): Deleted.
3588         (WTR::AccessibilityUIElement::rowCount): Deleted.
3589         (WTR::AccessibilityUIElement::columnCount): Deleted.
3590         (WTR::AccessibilityUIElement::rowHeaders): Deleted.
3591         (WTR::AccessibilityUIElement::columnHeaders): Deleted.
3592         (WTR::AccessibilityUIElement::selectedRowAtIndex): Deleted.
3593         (WTR::AccessibilityUIElement::disclosedByRow): Deleted.
3594         (WTR::AccessibilityUIElement::disclosedRowAtIndex): Deleted.
3595         (WTR::AccessibilityUIElement::rowAtIndex): Deleted.
3596         (WTR::AccessibilityUIElement::ariaOwnsElementAtIndex): Deleted.
3597         (WTR::AccessibilityUIElement::ariaFlowToElementAtIndex): Deleted.
3598         (WTR::AccessibilityUIElement::ariaControlsElementAtIndex): Deleted.
3599         (WTR::AccessibilityUIElement::ariaIsGrabbed): Deleted.
3600         (WTR::AccessibilityUIElement::ariaDropEffects): Deleted.