Title: [236958] trunk/Tools
Revision
236958
Author
wenson_hs...@apple.com
Date
2018-10-08 20:28:31 -0700 (Mon, 08 Oct 2018)

Log Message

[macOS] API test DragAndDropTests.DropColor is failing on macOS 10.12
https://bugs.webkit.org/show_bug.cgi?id=190386

Reviewed by Ryosuke Niwa.

Unlike macOS 10.13 and 10.14, -[NSColor redColor] is not equivalent to a fully red color in sRGB on macOS 10.12.
Fix the test by dragging and dropping an NSColor that is equivalent to rgb(255, 0, 0) on all relevant versions
of macOS.

* TestWebKitAPI/Tests/mac/DragAndDropTestsMac.mm:
(TEST):

Modified Paths

Diff

Modified: trunk/Tools/ChangeLog (236957 => 236958)


--- trunk/Tools/ChangeLog	2018-10-09 02:37:24 UTC (rev 236957)
+++ trunk/Tools/ChangeLog	2018-10-09 03:28:31 UTC (rev 236958)
@@ -1,5 +1,19 @@
 2018-10-08  Wenson Hsieh  <wenson_hs...@apple.com>
 
+        [macOS] API test DragAndDropTests.DropColor is failing on macOS 10.12
+        https://bugs.webkit.org/show_bug.cgi?id=190386
+
+        Reviewed by Ryosuke Niwa.
+
+        Unlike macOS 10.13 and 10.14, -[NSColor redColor] is not equivalent to a fully red color in sRGB on macOS 10.12.
+        Fix the test by dragging and dropping an NSColor that is equivalent to rgb(255, 0, 0) on all relevant versions
+        of macOS.
+
+        * TestWebKitAPI/Tests/mac/DragAndDropTestsMac.mm:
+        (TEST):
+
+2018-10-08  Wenson Hsieh  <wenson_hs...@apple.com>
+
         [Cocoa] [WK2] Add support for text alignment and text lists in font attributes
         https://bugs.webkit.org/show_bug.cgi?id=190342
         <rdar://problem/44767118>

Modified: trunk/Tools/TestWebKitAPI/Tests/mac/DragAndDropTestsMac.mm (236957 => 236958)


--- trunk/Tools/TestWebKitAPI/Tests/mac/DragAndDropTestsMac.mm	2018-10-09 02:37:24 UTC (rev 236957)
+++ trunk/Tools/TestWebKitAPI/Tests/mac/DragAndDropTestsMac.mm	2018-10-09 03:28:31 UTC (rev 236958)
@@ -78,7 +78,7 @@
 {
     NSPasteboard *pasteboard = [NSPasteboard pasteboardWithUniqueName];
     [pasteboard declareTypes:@[NSColorPboardType] owner:nil];
-    [[NSColor redColor] writeToPasteboard:pasteboard];
+    [[NSColor colorWithRed:1 green:0 blue:0 alpha:1] writeToPasteboard:pasteboard];
 
     auto simulator = adoptNS([[DragAndDropSimulator alloc] initWithWebViewFrame:NSMakeRect(0, 0, 400, 400)]);
     TestWKWebView *webView = [simulator webView];
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to