Bug 237821 - [AT-SPI] accessibility/native-text-control-attributed-string.html is failing
Summary: [AT-SPI] accessibility/native-text-control-attributed-string.html is failing
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Lauro Moura
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2022-03-13 23:08 PDT by Lauro Moura
Modified: 2022-03-28 18:21 PDT (History)
11 users (show)

See Also:


Attachments
Patch (11.18 KB, patch)
2022-03-13 23:09 PDT, Lauro Moura
no flags Details | Formatted Diff | Diff
Patch with bugnumber (11.22 KB, patch)
2022-03-13 23:10 PDT, Lauro Moura
no flags Details | Formatted Diff | Diff
Updated patch skipping out of range (8.04 KB, patch)
2022-03-24 20:11 PDT, Lauro Moura
no flags Details | Formatted Diff | Diff
Patch for landing (8.13 KB, patch)
2022-03-28 13:52 PDT, Lauro Moura
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Lauro Moura 2022-03-13 23:08:24 PDT
[AT-SPI] accessibility/native-text-control-attributed-string.html is failing
Comment 1 Lauro Moura 2022-03-13 23:09:01 PDT
Created attachment 454564 [details]
Patch
Comment 2 Lauro Moura 2022-03-13 23:10:01 PDT
Created attachment 454565 [details]
Patch with bugnumber
Comment 3 Lauro Moura 2022-03-13 23:14:26 PDT
Comment on attachment 454565 [details]
Patch with bugnumber

View in context: https://bugs.webkit.org/attachment.cgi?id=454565&action=review

> LayoutTests/platform/gtk/accessibility/native-text-control-attributed-string-expected.txt:51
> +Attributed string for range (5, 10):

In the mac expectation, this range has positions outside the string and ends up returning null. Should we do the same?

> LayoutTests/platform/gtk/accessibility/native-text-control-attributed-string-expected.txt:66
> +Attributed string for range (10, 1):

Ditto.
Comment 4 Carlos Garcia Campos 2022-03-15 06:37:42 PDT
Comment on attachment 454565 [details]
Patch with bugnumber

View in context: https://bugs.webkit.org/attachment.cgi?id=454565&action=review

>> LayoutTests/platform/gtk/accessibility/native-text-control-attributed-string-expected.txt:51
>> +Attributed string for range (5, 10):
> 
> In the mac expectation, this range has positions outside the string and ends up returning null. Should we do the same?

Yes, for consistency. I guess we just need to check the range is valid and return null otherwise.
Comment 5 Radar WebKit Bug Importer 2022-03-20 23:09:18 PDT
<rdar://problem/90552509>
Comment 6 Lauro Moura 2022-03-24 20:11:56 PDT
Created attachment 455721 [details]
Updated patch skipping out of range

The -1,1 out of range case still returns an attribute string as the location arrives as 0, like in the mac port
Comment 7 Carlos Garcia Campos 2022-03-25 01:24:46 PDT
Comment on attachment 455721 [details]
Updated patch skipping out of range

View in context: https://bugs.webkit.org/attachment.cgi?id=455721&action=review

> Tools/WebKitTestRunner/InjectedBundle/atspi/AccessibilityUIElementAtspi.cpp:1169
> +    auto text = m_element->text();

You should also move m_element->updateBackingStore(); here, before calling text().
Comment 8 Lauro Moura 2022-03-28 13:52:18 PDT
Created attachment 455949 [details]
Patch for landing
Comment 9 EWS 2022-03-28 18:21:45 PDT
Committed r292019 (248963@main): <https://commits.webkit.org/248963@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 455949 [details].