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