Bug 264991
Summary: | 'NotEnumerable' causing Selection API 'idlharness' stringification test failure | ||
---|---|---|---|
Product: | WebKit | Reporter: | Ahmad Saleem <ahmad.saleem792> |
Component: | HTML Editing | Assignee: | Nobody <webkit-unassigned> |
Status: | RESOLVED FIXED | ||
Severity: | Normal | CC: | mike, rniwa, webkit-bug-importer, wenson_hsieh |
Priority: | P2 | Keywords: | BrowserCompat, InRadar, WPTImpact |
Version: | WebKit Nightly Build | ||
Hardware: | Unspecified | ||
OS: | Unspecified |
Ahmad Saleem
Hi Team,
While trying to investigate 'browser specific failure', I noticed that Safari / WebKit fails one 'idlharness' test from Selection API:
WPT Test Case: https://wpt.fyi/results/selection/idlharness.window.html?label=master&label=experimental&aligned=&q=safari%3Afail+idlharness
^ Failing: Selection interface: stringifier
While loading 'Assert', I noticed that it was failing here:
Fail
assert_true(false, "property should be enumerable")
/resources/idlharness.js:2642:20
and while looking into 'DOMSelection.idl', I noticed that we have following:
https://github.com/WebKit/WebKit/blob/54a799c39b9970cface5982aefe8e5f6cc508bf7/Source/WebCore/page/DOMSelection.idl#L70
[NotEnumerable] DOMString toString();
and change above to:
DOMString toString();
___
It leads us to pass all test cases in 'idlharness'.
I just wanted to raise so we can track this failure and fix the issue.
Thanks!
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Ahmad Saleem
Web-Spec: https://w3c.github.io/selection-api/#dom-selection-stringifier
Ahmad Saleem
Just to update, we have following:
undefined setBaseAndExtent(Node? baseNode, unsigned long baseOffset, Node? extentNode, unsigned long extentOffset);
but Web-Spec has following:
undefined setBaseAndExtent(Node anchorNode, unsigned long anchorOffset, Node focusNode, unsigned long focusOffset);
___
Web-Spec: https://w3c.github.io/selection-api/#selection-interface
Ryosuke Niwa
It seems like a good change assuming that other browser engines pass those tests.
Ahmad Saleem
PR to sync partially with bug - https://github.com/WebKit/WebKit/pull/20696
As for 'Comment 02', it is bit more involved change, will create separate bug for it.
@Ryosuke - thanks for your input. For some reason, we don't have 'idlharness' expectation file but I will run above PR as draft via EWS to see, what this change leads and then will make it 'Open' once everything looks good.
EWS
Committed 270933@main (6b9b667d2d27): <https://commits.webkit.org/270933@main>
Reviewed commits have been landed. Closing PR #20696 and removing active labels.
Radar WebKit Bug Importer
<rdar://problem/118594710>