widget/tests/test_clipboard_getDataSnapshot[Sync].html fails on new android 14 emulator image
Categories
(Core :: Widget, defect)
Tracking
()
People
(Reporter: jmaher, Assigned: m_kato)
References
Details
Attachments
(1 file)
on this try push, there are many failures, but it appears that in most instances widget/tests/test_clipboard_getDataSnapshot.html is failing with errors (such as got text/plain, expecting text/html) (as per this log)
I am planning on skipping this test on android 14 in bug 1982943.
Updated•1 year ago
|
| Assignee | ||
Updated•13 days ago
|
| Assignee | ||
Comment 1•11 days ago
|
||
Android ClipItem can has text, html, url and intent on one mime type. So before Android P, we check text and htmltext in ClipData, then if HTML text exists, it can HTML mime type. After Android change (https://developer.android.com/about/versions/12/behavior-changes-all#clipboard-access-notifications), we check MIME type instead. text/plain in Gecko means text/plain and text/html in GV.
Also the following WPTs are failed by same reason.
- /clipboard-apis/async-html-script-removal.https.html
- /clipboard-apis/async-write-html-read-html.https.html
https://treeherder.mozilla.org/jobs?repo=try&revision=cd24ac2c4505d7a360e40c80fe010cf12acf8e3d
| Assignee | ||
Comment 2•9 days ago
|
||
This issue occurs by bug 1755052 since we cannot check content data
without clipboard notifications after Android 12.
Even if text/html type, Android's ClipData can have both text and html.
Before Android 12, we check text data into ClipData whether it has
text. But, by Android 12 changes, we cannot check it without clipboard
access notifications.
So then, we check MIME type only whether this is text/html or text/plain
on Android 12+. If Gecko requests text/plain, we allow text/html too.
But this causes that several tests are failed.
So we should add both mimetypes when plain text and html text are set.
Also, we shouldn't contain HTML when requesting plain text.
Description
•