RESOLVED FIXED 175509
[iOS WK2] Add a version of DataInteractionTests.ExternalSourceAttributedStringToContentEditable that doesn't hit a debug assertion
https://bugs.webkit.org/show_bug.cgi?id=175509
Summary [iOS WK2] Add a version of DataInteractionTests.ExternalSourceAttributedStrin...
Wenson Hsieh
Reported 2017-08-12 02:42:29 PDT
This test is hitting a debug assertion after a recent SDK update. Instead of using [UIFont boldSystemFontOfSize:] to test that attributed strings preserve styles when dropping, use a foreground color and check that the resulting inserted text is colored in the DOM.
Attachments
Patch (2.56 KB, patch)
2017-08-12 03:02 PDT, Wenson Hsieh
no flags
Patch (3.81 KB, patch)
2017-08-18 13:33 PDT, Wenson Hsieh
rniwa: review+
Patch for landing (3.99 KB, patch)
2017-08-19 01:04 PDT, Wenson Hsieh
no flags
Wenson Hsieh
Comment 1 2017-08-12 02:44:41 PDT
Wenson Hsieh
Comment 2 2017-08-12 03:02:23 PDT
Megan Gardner
Comment 3 2017-08-12 15:08:29 PDT
This looks good, minus it not working on iOS-sim. I thought that the call you switched to might be too new for the perf bots, but it seems to be fine.
Wenson Hsieh
Comment 4 2017-08-12 15:13:00 PDT
(In reply to Megan Gardner from comment #3) > This looks good, minus it not working on iOS-sim. I thought that the call > you switched to might be too new for the perf bots, but it seems to be fine. Thanks for taking a look! Unfortunately, these API tests are not run on the EWS bots at all. The test failures making 'ios-sim' orange in the dashboard are unrelated: - imported/w3c/web-platform-tests/fetch/ - imported/w3c/web-platform-tests/cors/ - imported/w3c/web-platform-tests/XMLHttpRequest/ - imported/w3c/web-platform-tests/beacon/ - http/tests/blink/sendbeacon/ - http/wpt/beacon/
Megan Gardner
Comment 5 2017-08-12 15:19:16 PDT
Oh, I forgot that they don't run. LGTM then! (In reply to Wenson Hsieh from comment #4) > (In reply to Megan Gardner from comment #3) > > This looks good, minus it not working on iOS-sim. I thought that the call > > you switched to might be too new for the perf bots, but it seems to be fine. > > Thanks for taking a look! > > Unfortunately, these API tests are not run on the EWS bots at all. The test > failures making 'ios-sim' orange in the dashboard are unrelated: > > - imported/w3c/web-platform-tests/fetch/ > - imported/w3c/web-platform-tests/cors/ > - imported/w3c/web-platform-tests/XMLHttpRequest/ > - imported/w3c/web-platform-tests/beacon/ > - http/tests/blink/sendbeacon/ > - http/wpt/beacon/
Wenson Hsieh
Comment 6 2017-08-18 13:33:23 PDT
Wenson Hsieh
Comment 7 2017-08-18 13:34:53 PDT
Tim and I chatted in person -- we're going to keep the debug-assertion-ing test, but mark it as disabled, and add a new test that fulfills the same purpose (w.r.t. testing attributed strings and DnD) but uses color instead to ensure that we don't leave this codepath untested.
Ryosuke Niwa
Comment 8 2017-08-18 23:18:42 PDT
Comment on attachment 318536 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=318536&action=review > Tools/ChangeLog:11 > + Clone ExternalSourceAttributedStringToContentEditable to ExternalSourceColoredAttributedStringToContentEditable, > + which tests an attributed string with colored text instead of a bold attributed string of system font. Due to a > + recent change in behavior in UIKit, this test is hitting a debug assertion. The purpose of this test is to verify Could you clarify that you're adding a test which changes color because bold case is crashing.
Wenson Hsieh
Comment 9 2017-08-19 00:39:21 PDT
Comment on attachment 318536 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=318536&action=review >> Tools/ChangeLog:11 >> + recent change in behavior in UIKit, this test is hitting a debug assertion. The purpose of this test is to verify > > Could you clarify that you're adding a test which changes color because bold case is crashing. Will do!
Wenson Hsieh
Comment 10 2017-08-19 01:04:35 PDT
Created attachment 318584 [details] Patch for landing
WebKit Commit Bot
Comment 11 2017-08-19 01:46:20 PDT
Comment on attachment 318584 [details] Patch for landing Clearing flags on attachment: 318584 Committed r220952: <http://trac.webkit.org/changeset/220952>
Note You need to log in before you can comment on or make changes to this bug.