-
Notifications
You must be signed in to change notification settings - Fork 3.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add insertion tests for the new changes with the "deferred steps queue" #15264
Conversation
The most interesting one is the button one because it doesn't even rely on a document fragment. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for writing these! I have some questions and I'm also not sure we should merge these given we're unclear on the direction of the specification still. I'd be somewhat okay if we put .tentative. in the name, but it's not even clear these are the results we want...
e84e128
to
7cab7bb
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd like to see a test where multiple scripts are inserted at once through a fragment and one of the scripts that executes earlier modifies another script. It'd be good to know that the modification takes effect, as per the current proposed text.
And a similar test where the subsequent script is removed from the tree to see it gets properly aborted.
dom/nodes/Node-appendChild-script-and-custom-from-fragment.html
Outdated
Show resolved
Hide resolved
7cab7bb
to
0253b2a
Compare
5082ab6
to
b177352
Compare
9c8d1ab
to
54d4ba6
Compare
a2efc70
to
005ed5e
Compare
FYI: I'm in the process of rewriting these tests so they work with newish wpt requirements. |
The test follows the spec, but the spec is followed only by Safari.
This test too follows the spec, but only Safari defines the custom element before inserting one in the document, other browsers upgrade the custom-element at the time of the customElements.define call because it is already in tree.
This test once again follows the spec, but only Safari executes it correctly, with no form owner set on the button at the time of the execution of the script.
Safari and Chrome pass that test, Firefox fails it.
1ba9f9c
to
43076fa
Compare
These tests are cleaned up now, but pass conditions probably still need adjusting. |
@domfarolino you might want to repurpose these for #44308 and whatwg/dom#808. There's a couple other interesting cases these tests touch. |
Closing this out in favor of #44658 which is being reviewed now. We'd like to land it soon, with Git co-author credit to @nox for working on this suite of tests initially. Thanks a lot! |
Those tests expose differences between Safari and the spec on one side, and the rest of the world on the other side.
[These are for whatwg/dom#732 and whatwg/html#4354. - Anne]