diff options
author | Gae24 <96017547+Gae24@users.noreply.github.com> | 2024-11-25 11:49:04 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-11-25 10:49:04 +0000 |
commit | c9e3d3e25e37068cff5164d83dfa906a7d74f528 (patch) | |
tree | 0c7dd286f6437ca17a98d74a68b4a0c821ca46c5 /tests/wpt | |
parent | 810a91ecac71f656ca6573045ff51e7fee35ca53 (diff) | |
download | servo-c9e3d3e25e37068cff5164d83dfa906a7d74f528.tar.gz servo-c9e3d3e25e37068cff5164d83dfa906a7d74f528.zip |
Implement `DataTransfer` and related interfaces (#34205)
* add datatransfer interfaces
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
* implement DataTransfer interface
implemented Constructor, setter and getter for drop_effect and effect_allowed, Items and SetDragImage
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
* implement DataTransferItem interface
Implemented Kind, Type, GetAsString, GetAsFile.
Marked DataTransfer as weakReferenceable to access its field
inside DataTransferItemList and DataTransferItem.
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
* implement DataTransferItemList interface
implemented Lenght, Getter, Add, Remove, Clear
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
* added DataTransfer's old interface
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
* DataTransfer: implemented GetData, SetData, SetData
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
* set Weakref to DataTransfer in DataTransferItemList and DataTransferItem
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
* DataTransfer: implemented Types and Files
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
* cleanup get_data, set_data, clear_data
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
* fix clippy warning
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
* add drag data store
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
* fix DataTransfer's Types() behaviour
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
* DataTransferItem: use the underlying drag data store
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
* fix DataTransferItemList's getter and remove
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
* fix clippy warnings
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
* update test expectations
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
---------
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
Diffstat (limited to 'tests/wpt')
8 files changed, 4 insertions, 146 deletions
diff --git a/tests/wpt/meta/html/dom/idlharness.https.html.ini b/tests/wpt/meta/html/dom/idlharness.https.html.ini index 82cc0be8c16..eedf2e1f139 100644 --- a/tests/wpt/meta/html/dom/idlharness.https.html.ini +++ b/tests/wpt/meta/html/dom/idlharness.https.html.ini @@ -5042,114 +5042,6 @@ [CloseWatcher interface: attribute onclose] expected: FAIL - [DataTransfer interface: existence and properties of interface object] - expected: FAIL - - [DataTransfer interface object length] - expected: FAIL - - [DataTransfer interface object name] - expected: FAIL - - [DataTransfer interface: existence and properties of interface prototype object] - expected: FAIL - - [DataTransfer interface: existence and properties of interface prototype object's "constructor" property] - expected: FAIL - - [DataTransfer interface: existence and properties of interface prototype object's @@unscopables property] - expected: FAIL - - [DataTransfer interface: attribute dropEffect] - expected: FAIL - - [DataTransfer interface: attribute effectAllowed] - expected: FAIL - - [DataTransfer interface: attribute items] - expected: FAIL - - [DataTransfer interface: operation setDragImage(Element, long, long)] - expected: FAIL - - [DataTransfer interface: attribute types] - expected: FAIL - - [DataTransfer interface: operation getData(DOMString)] - expected: FAIL - - [DataTransfer interface: operation setData(DOMString, DOMString)] - expected: FAIL - - [DataTransfer interface: operation clearData(optional DOMString)] - expected: FAIL - - [DataTransfer interface: attribute files] - expected: FAIL - - [DataTransferItemList interface: existence and properties of interface object] - expected: FAIL - - [DataTransferItemList interface object length] - expected: FAIL - - [DataTransferItemList interface object name] - expected: FAIL - - [DataTransferItemList interface: existence and properties of interface prototype object] - expected: FAIL - - [DataTransferItemList interface: existence and properties of interface prototype object's "constructor" property] - expected: FAIL - - [DataTransferItemList interface: existence and properties of interface prototype object's @@unscopables property] - expected: FAIL - - [DataTransferItemList interface: attribute length] - expected: FAIL - - [DataTransferItemList interface: operation add(DOMString, DOMString)] - expected: FAIL - - [DataTransferItemList interface: operation add(File)] - expected: FAIL - - [DataTransferItemList interface: operation remove(unsigned long)] - expected: FAIL - - [DataTransferItemList interface: operation clear()] - expected: FAIL - - [DataTransferItem interface: existence and properties of interface object] - expected: FAIL - - [DataTransferItem interface object length] - expected: FAIL - - [DataTransferItem interface object name] - expected: FAIL - - [DataTransferItem interface: existence and properties of interface prototype object] - expected: FAIL - - [DataTransferItem interface: existence and properties of interface prototype object's "constructor" property] - expected: FAIL - - [DataTransferItem interface: existence and properties of interface prototype object's @@unscopables property] - expected: FAIL - - [DataTransferItem interface: attribute kind] - expected: FAIL - - [DataTransferItem interface: attribute type] - expected: FAIL - - [DataTransferItem interface: operation getAsString(FunctionStringCallback?)] - expected: FAIL - - [DataTransferItem interface: operation getAsFile()] - expected: FAIL - [DragEvent interface: existence and properties of interface object] expected: FAIL diff --git a/tests/wpt/meta/html/editing/dnd/datastore/datatransfer-constructor-001.html.ini b/tests/wpt/meta/html/editing/dnd/datastore/datatransfer-constructor-001.html.ini deleted file mode 100644 index 750d47ebed2..00000000000 --- a/tests/wpt/meta/html/editing/dnd/datastore/datatransfer-constructor-001.html.ini +++ /dev/null @@ -1,3 +0,0 @@ -[datatransfer-constructor-001.html] - [Verify DataTransfer constructor] - expected: FAIL diff --git a/tests/wpt/meta/html/editing/dnd/datastore/datatransfer-types.html.ini b/tests/wpt/meta/html/editing/dnd/datastore/datatransfer-types.html.ini deleted file mode 100644 index 0b373dd8da2..00000000000 --- a/tests/wpt/meta/html/editing/dnd/datastore/datatransfer-types.html.ini +++ /dev/null @@ -1,15 +0,0 @@ -[datatransfer-types.html] - [type's state on DataTransfer creation] - expected: FAIL - - [Relationship between types and items] - expected: FAIL - - [type's identity] - expected: FAIL - - [Verify type is a read-only attribute] - expected: FAIL - - [DataTransfer containing files] - expected: FAIL diff --git a/tests/wpt/meta/html/editing/dnd/datastore/datatransferitemlist-remove.html.ini b/tests/wpt/meta/html/editing/dnd/datastore/datatransferitemlist-remove.html.ini deleted file mode 100644 index e4a19e7595e..00000000000 --- a/tests/wpt/meta/html/editing/dnd/datastore/datatransferitemlist-remove.html.ini +++ /dev/null @@ -1,3 +0,0 @@ -[datatransferitemlist-remove.html] - [remove()ing an out-of-bounds index does nothing] - expected: FAIL diff --git a/tests/wpt/meta/html/semantics/forms/form-submission-0/newline-normalization.html.ini b/tests/wpt/meta/html/semantics/forms/form-submission-0/newline-normalization.html.ini index 1cc138175d3..8144a10f25d 100644 --- a/tests/wpt/meta/html/semantics/forms/form-submission-0/newline-normalization.html.ini +++ b/tests/wpt/meta/html/semantics/forms/form-submission-0/newline-normalization.html.ini @@ -22,15 +22,3 @@ [Form newline normalization: \\n\\r in the filename stays unchanged] expected: FAIL - - [Constructing the entry list shouldn't perform newline normalization: \\n in the filename] - expected: FAIL - - [Constructing the entry list shouldn't perform newline normalization: \\r in the filename] - expected: FAIL - - [Constructing the entry list shouldn't perform newline normalization: \\r\\n in the filename] - expected: FAIL - - [Constructing the entry list shouldn't perform newline normalization: \\n\\r in the filename] - expected: FAIL diff --git a/tests/wpt/meta/html/semantics/forms/form-submission-0/submit-file.sub.html.ini b/tests/wpt/meta/html/semantics/forms/form-submission-0/submit-file.sub.html.ini deleted file mode 100644 index a2d487c0e97..00000000000 --- a/tests/wpt/meta/html/semantics/forms/form-submission-0/submit-file.sub.html.ini +++ /dev/null @@ -1,4 +0,0 @@ -[submit-file.sub.html] - [Posting a File] - expected: FAIL - diff --git a/tests/wpt/mozilla/meta/MANIFEST.json b/tests/wpt/mozilla/meta/MANIFEST.json index c1c95016bcb..094659d27ca 100644 --- a/tests/wpt/mozilla/meta/MANIFEST.json +++ b/tests/wpt/mozilla/meta/MANIFEST.json @@ -13495,7 +13495,7 @@ ] ], "interfaces.https.html": [ - "5a39868cd2090b492e2192447bf353527649bbfb", + "dc853b1a823990fa2d1478533dc5bd17fb576a13", [ null, {} diff --git a/tests/wpt/mozilla/tests/mozilla/interfaces.https.html b/tests/wpt/mozilla/tests/mozilla/interfaces.https.html index 5a39868cd20..dc853b1a823 100644 --- a/tests/wpt/mozilla/tests/mozilla/interfaces.https.html +++ b/tests/wpt/mozilla/tests/mozilla/interfaces.https.html @@ -58,6 +58,9 @@ test_interfaces([ "CSSStyleRule", "CSSStyleSheet", "CSSSupportsRule", + "DataTransfer", + "DataTransferItem", + "DataTransferItemList", "DOMMatrix", "DOMMatrixReadOnly", "DOMPoint", |