Skip to content
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

Update tests for slot change events #5954

Conversation

hayatoito
Copy link
Member

@hayatoito hayatoito commented May 17, 2017

…t is inserted

DOM Standard chagne is whatwg/dom#459.

@ghost
Copy link

ghost commented May 17, 2017

View the complete job log.

Firefox (nightly)

Testing web-platform-tests at revision 65932ee
Using browser at version BuildID 20170604100232; SourceStamp 130efc657df7e7fe291cc42307f3eb3cb0484dfc
Starting 10 test iterations
All results were stable

All results

4 tests ran
/shadow-dom/slotchange-event.html
Subtest Results Messages
OK
slotchange event must fire on a default slot element inside an open shadow root in a document FAIL host.attachShadow is not a function
slotchange event must fire on a default slot element inside a closed shadow root in a document FAIL host.attachShadow is not a function
slotchange event must fire on a default slot element inside an open shadow root not in a document FAIL host.attachShadow is not a function
slotchange event must fire on a default slot element inside a closed shadow root not in a document FAIL host.attachShadow is not a function
slotchange event must fire on a named slot element insidean open shadow root in a document FAIL host.attachShadow is not a function
slotchange event must fire on a named slot element insidea closed shadow root in a document FAIL host.attachShadow is not a function
slotchange event must fire on a named slot element insidean open shadow root not in a document FAIL host.attachShadow is not a function
slotchange event must fire on a named slot element insidea closed shadow root not in a document FAIL host.attachShadow is not a function
slotchange event must not fire on a slot element inside an open shadow root in a document when another slot's assigned nodes change FAIL host.attachShadow is not a function
slotchange event must not fire on a slot element inside a closed shadow root in a document when another slot's assigned nodes change FAIL host.attachShadow is not a function
slotchange event must not fire on a slot element inside an open shadow root not in a document when another slot's assigned nodes change FAIL host.attachShadow is not a function
slotchange event must not fire on a slot element inside a closed shadow root not in a document when another slot's assigned nodes change FAIL host.attachShadow is not a function
slotchange event must fire on a slot element when a shadow host has a slotable and the slot was inserted and must not fire when the shadow host was mutated after the slot was removed inside an open shadow root in a document FAIL host.attachShadow is not a function
slotchange event must fire on a slot element when a shadow host has a slotable and the slot was inserted and must not fire when the shadow host was mutated after the slot was removed inside a closed shadow root in a document FAIL host.attachShadow is not a function
slotchange event must fire on a slot element when a shadow host has a slotable and the slot was inserted and must not fire when the shadow host was mutated after the slot was removed inside an open shadow root not in a document FAIL host.attachShadow is not a function
slotchange event must fire on a slot element when a shadow host has a slotable and the slot was inserted and must not fire when the shadow host was mutated after the slot was removed inside a closed shadow root not in a document FAIL host.attachShadow is not a function
slotchange event must fire on a slot element inside an open shadow root in a document even if the slot was removed immediately after the assigned nodes were mutated FAIL host.attachShadow is not a function
slotchange event must fire on a slot element inside a closed shadow root in a document even if the slot was removed immediately after the assigned nodes were mutated FAIL host.attachShadow is not a function
slotchange event must fire on a slot element inside an open shadow root not in a document even if the slot was removed immediately after the assigned nodes were mutated FAIL host.attachShadow is not a function
slotchange event must fire on a slot element inside a closed shadow root not in a document even if the slot was removed immediately after the assigned nodes were mutated FAIL host.attachShadow is not a function
slotchange event must fire on a slot element inside an open shadow root in a document when innerHTML modifies the children of the shadow host FAIL host.attachShadow is not a function
slotchange event must fire on a slot element inside a closed shadow root in a document when innerHTML modifies the children of the shadow host FAIL host.attachShadow is not a function
slotchange event must fire on a slot element inside an open shadow root not in a document when innerHTML modifies the children of the shadow host FAIL host.attachShadow is not a function
slotchange event must fire on a slot element inside a closed shadow root not in a document when innerHTML modifies the children of the shadow host FAIL host.attachShadow is not a function
slotchange event must fire on a slot element inside an open shadow root in a document when nested slots's contents change FAIL outerHost.attachShadow is not a function
slotchange event must fire on a slot element inside a closed shadow root in a document when nested slots's contents change FAIL outerHost.attachShadow is not a function
slotchange event must fire on a slot element inside an open shadow root not in a document when nested slots's contents change FAIL outerHost.attachShadow is not a function
slotchange event must fire on a slot element inside a closed shadow root not in a document when nested slots's contents change FAIL outerHost.attachShadow is not a function
slotchange event must fire at the end of current microtask after mutation observers are invoked inside an open shadow root in a document when slots's contents change FAIL host.attachShadow is not a function
slotchange event must fire at the end of current microtask after mutation observers are invoked inside a closed shadow root in a document when slots's contents change FAIL host.attachShadow is not a function
slotchange event must fire at the end of current microtask after mutation observers are invoked inside an open shadow root not in a document when slots's contents change FAIL host.attachShadow is not a function
slotchange event must fire at the end of current microtask after mutation observers are invoked inside a closed shadow root not in a document when slots's contents change FAIL host.attachShadow is not a function
/shadow-dom/slots-fallback-in-document.html
Subtest Results Messages
OK
Shadow DOM: Slots and fallback contents in Document tree FAIL TypeError: parent.attachShadow is not a function
/shadow-dom/slots-fallback.html
Subtest Results Messages
OK
Slots fallback: Basic. FAIL parent.attachShadow is not a function
Slots fallback: Slots in Slots. FAIL parent.attachShadow is not a function
Slots fallback: Fallback contents should not be used if a node is assigned. FAIL parent.attachShadow is not a function
Slots fallback: Slots in Slots: Assinged nodes should be used as fallback contents of another slot FAIL parent.attachShadow is not a function
Slots fallback: Complex case. FAIL parent.attachShadow is not a function
Slots fallback: Mutation. Append fallback contents. FAIL parent.attachShadow is not a function
Slots fallback: Mutation. Remove fallback contents. FAIL parent.attachShadow is not a function
Slots fallback: Mutation. Assign a node to a slot so that fallback contens are no longer used. FAIL parent.attachShadow is not a function
Slots fallback: Mutation. Remove an assigned node from a slot so that fallback contens will be used. FAIL parent.attachShadow is not a function
Slots fallback: Mutation. Remove a slot which is a fallback content of another slot. FAIL parent.attachShadow is not a function
/shadow-dom/slots.html
Subtest Results Messages
OK
Slots: Basic. FAIL parent.attachShadow is not a function
Slots: Slots in closed. FAIL parent.attachShadow is not a function
Slots: Slots not in a shadow tree. FAIL n.s1.assignedNodes is not a function
Slots: Distributed nooes for Slots not in a shadow tree. FAIL assert_equals: expected (object) null but got (undefined) undefined
Slots: Name matching FAIL parent.attachShadow is not a function
Slots: No direct host child. FAIL parent.attachShadow is not a function
Slots: Default Slot. FAIL parent.attachShadow is not a function
Slots: Slot in Slot does not matter in assignment. FAIL parent.attachShadow is not a function
Slots: Slot is assigned to another slot FAIL parent.attachShadow is not a function
Slots: Open > Closed. FAIL parent.attachShadow is not a function
Slots: Closed > Closed. FAIL parent.attachShadow is not a function
Slots: Closed > Open. FAIL parent.attachShadow is not a function
Slots: Complex case: Basi line. FAIL parent.attachShadow is not a function
Slots: Mutation: appendChild. FAIL parent.attachShadow is not a function
Slots: Mutation: Change slot= attribute 1. FAIL parent.attachShadow is not a function
Slots: Mutation: Change slot= attribute 2. FAIL parent.attachShadow is not a function
Slots: Mutation: Change slot= attribute 3. FAIL parent.attachShadow is not a function
Slots: Mutation: Remove a child. FAIL parent.attachShadow is not a function
Slots: Mutation: Add a slot: after. FAIL parent.attachShadow is not a function
Slots: Mutation: Add a slot: before. FAIL parent.attachShadow is not a function
Slots: Mutation: Remove a slot. FAIL parent.attachShadow is not a function
Slots: Mutation: Change slot name= attribute. FAIL parent.attachShadow is not a function
Slots: Mutation: Change slot slot= attribute. FAIL parent.attachShadow is not a function

@ghost
Copy link

ghost commented May 17, 2017

View the complete job log.

Sauce (safari)

Testing web-platform-tests at revision 65932ee
Using browser at version 10.0
Starting 10 test iterations
All results were stable

All results

4 tests ran
/shadow-dom/slotchange-event.html
Subtest Results Messages
ERROR
slotchange event must fire on a default slot element inside an open shadow root in a document PASS
slotchange event must fire on a default slot element inside a closed shadow root in a document PASS
slotchange event must fire on a default slot element inside an open shadow root not in a document PASS
slotchange event must fire on a default slot element inside a closed shadow root not in a document PASS
slotchange event must fire on a named slot element insidean open shadow root in a document PASS
slotchange event must fire on a named slot element insidea closed shadow root in a document PASS
slotchange event must fire on a named slot element insidean open shadow root not in a document PASS
slotchange event must fire on a named slot element insidea closed shadow root not in a document PASS
slotchange event must not fire on a slot element inside an open shadow root in a document when another slot's assigned nodes change PASS
slotchange event must not fire on a slot element inside a closed shadow root in a document when another slot's assigned nodes change PASS
slotchange event must not fire on a slot element inside an open shadow root not in a document when another slot's assigned nodes change PASS
slotchange event must not fire on a slot element inside a closed shadow root not in a document when another slot's assigned nodes change PASS
slotchange event must fire on a slot element when a shadow host has a slotable and the slot was inserted and must not fire when the shadow host was mutated after the slot was removed inside an open shadow root in a document FAIL assert_equals: slotchange must be fired on a slot element if there is assigned nodes when the slot was inserted expected 1 but got 0
slotchange event must fire on a slot element when a shadow host has a slotable and the slot was inserted and must not fire when the shadow host was mutated after the slot was removed inside a closed shadow root in a document FAIL assert_equals: slotchange must be fired on a slot element if there is assigned nodes when the slot was inserted expected 1 but got 0
slotchange event must fire on a slot element when a shadow host has a slotable and the slot was inserted and must not fire when the shadow host was mutated after the slot was removed inside an open shadow root not in a document FAIL assert_equals: slotchange must be fired on a slot element if there is assigned nodes when the slot was inserted expected 1 but got 0
slotchange event must fire on a slot element when a shadow host has a slotable and the slot was inserted and must not fire when the shadow host was mutated after the slot was removed inside a closed shadow root not in a document FAIL assert_equals: slotchange must be fired on a slot element if there is assigned nodes when the slot was inserted expected 1 but got 0
slotchange event must fire on a slot element inside an open shadow root in a document even if the slot was removed immediately after the assigned nodes were mutated PASS
slotchange event must fire on a slot element inside a closed shadow root in a document even if the slot was removed immediately after the assigned nodes were mutated PASS
slotchange event must fire on a slot element inside an open shadow root not in a document even if the slot was removed immediately after the assigned nodes were mutated PASS
slotchange event must fire on a slot element inside a closed shadow root not in a document even if the slot was removed immediately after the assigned nodes were mutated PASS
slotchange event must fire on a slot element inside an open shadow root in a document when innerHTML modifies the children of the shadow host PASS
slotchange event must fire on a slot element inside a closed shadow root in a document when innerHTML modifies the children of the shadow host PASS
slotchange event must fire on a slot element inside an open shadow root not in a document when innerHTML modifies the children of the shadow host PASS
slotchange event must fire on a slot element inside a closed shadow root not in a document when innerHTML modifies the children of the shadow host PASS
slotchange event must fire on a slot element inside an open shadow root in a document when nested slots's contents change FAIL assert_equals: slotchange must be fired on a slot element and must bubble expected 2 but got 1
slotchange event must fire on a slot element inside a closed shadow root in a document when nested slots's contents change FAIL assert_equals: slotchange must be fired on a slot element and must bubble expected 2 but got 1
slotchange event must fire on a slot element inside an open shadow root not in a document when nested slots's contents change FAIL assert_equals: slotchange must be fired on a slot element and must bubble expected 2 but got 1
slotchange event must fire on a slot element inside a closed shadow root not in a document when nested slots's contents change FAIL assert_equals: slotchange must be fired on a slot element and must bubble expected 2 but got 1
slotchange event must fire at the end of current microtask after mutation observers are invoked inside an open shadow root in a document when slots's contents change PASS
slotchange event must fire at the end of current microtask after mutation observers are invoked inside a closed shadow root in a document when slots's contents change PASS
slotchange event must fire at the end of current microtask after mutation observers are invoked inside an open shadow root not in a document when slots's contents change PASS
slotchange event must fire at the end of current microtask after mutation observers are invoked inside a closed shadow root not in a document when slots's contents change PASS
/shadow-dom/slots-fallback-in-document.html
Subtest Results Messages
OK
Children of a slot in a document tree should not be counted in flattened assigned nodes. FAIL assert_array_equals: lengths differ, expected 1 got 0
Slot fallback content in shadow tree should be counted in flattened assigned nodes. FAIL assert_array_equals: lengths differ, expected 1 got 0
/shadow-dom/slots-fallback.html
Subtest Results Messages
OK
Slots fallback: Basic. FAIL assert_array_equals: lengths differ, expected 1 got 0
Slots fallback: Slots in Slots. FAIL assert_array_equals: lengths differ, expected 1 got 0
Slots fallback: Fallback contents should not be used if a node is assigned. FAIL assert_array_equals: lengths differ, expected 1 got 0
Slots fallback: Slots in Slots: Assinged nodes should be used as fallback contents of another slot FAIL assert_array_equals: lengths differ, expected 1 got 0
Slots fallback: Complex case. FAIL assert_array_equals: lengths differ, expected 2 got 0
Slots fallback: Mutation. Append fallback contents. FAIL assert_array_equals: lengths differ, expected 3 got 0
Slots fallback: Mutation. Remove fallback contents. FAIL assert_array_equals: lengths differ, expected 1 got 0
Slots fallback: Mutation. Assign a node to a slot so that fallback contens are no longer used. FAIL assert_array_equals: lengths differ, expected 2 got 0
Slots fallback: Mutation. Remove an assigned node from a slot so that fallback contens will be used. FAIL assert_array_equals: lengths differ, expected 1 got 0
Slots fallback: Mutation. Remove a slot which is a fallback content of another slot. FAIL assert_array_equals: lengths differ, expected 1 got 0
/shadow-dom/slots.html
Subtest Results Messages
OK
Slots: Basic. PASS
Slots: Slots in closed. PASS
Slots: Slots not in a shadow tree. PASS
Slots: Distributed nooes for Slots not in a shadow tree. PASS
Slots: Name matching PASS
Slots: No direct host child. PASS
Slots: Default Slot. PASS
Slots: Slot in Slot does not matter in assignment. PASS
Slots: Slot is assigned to another slot PASS
Slots: Open > Closed. PASS
Slots: Closed > Closed. PASS
Slots: Closed > Open. PASS
Slots: Complex case: Basi line. PASS
Slots: Mutation: appendChild. PASS
Slots: Mutation: Change slot= attribute 1. PASS
Slots: Mutation: Change slot= attribute 2. PASS
Slots: Mutation: Change slot= attribute 3. PASS
Slots: Mutation: Remove a child. PASS
Slots: Mutation: Add a slot: after. PASS
Slots: Mutation: Add a slot: before. PASS
Slots: Mutation: Remove a slot. PASS
Slots: Mutation: Change slot name= attribute. PASS
Slots: Mutation: Change slot slot= attribute. PASS

@ghost
Copy link

ghost commented May 17, 2017

View the complete job log.

Sauce (MicrosoftEdge)

Testing web-platform-tests at revision 65932ee
Using browser at version 14.14393
Starting 10 test iterations
All results were stable

All results

4 tests ran
/shadow-dom/slotchange-event.html
Subtest Results Messages
OK
slotchange event must fire on a default slot element inside an open shadow root in a document FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a default slot element inside a closed shadow root in a document FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a default slot element inside an open shadow root not in a document FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a default slot element inside a closed shadow root not in a document FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a named slot element insidean open shadow root in a document FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a named slot element insidea closed shadow root in a document FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a named slot element insidean open shadow root not in a document FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a named slot element insidea closed shadow root not in a document FAIL Object doesn't support property or method 'attachShadow'
slotchange event must not fire on a slot element inside an open shadow root in a document when another slot's assigned nodes change FAIL Object doesn't support property or method 'attachShadow'
slotchange event must not fire on a slot element inside a closed shadow root in a document when another slot's assigned nodes change FAIL Object doesn't support property or method 'attachShadow'
slotchange event must not fire on a slot element inside an open shadow root not in a document when another slot's assigned nodes change FAIL Object doesn't support property or method 'attachShadow'
slotchange event must not fire on a slot element inside a closed shadow root not in a document when another slot's assigned nodes change FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a slot element when a shadow host has a slotable and the slot was inserted and must not fire when the shadow host was mutated after the slot was removed inside an open shadow root in a document FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a slot element when a shadow host has a slotable and the slot was inserted and must not fire when the shadow host was mutated after the slot was removed inside a closed shadow root in a document FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a slot element when a shadow host has a slotable and the slot was inserted and must not fire when the shadow host was mutated after the slot was removed inside an open shadow root not in a document FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a slot element when a shadow host has a slotable and the slot was inserted and must not fire when the shadow host was mutated after the slot was removed inside a closed shadow root not in a document FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a slot element inside an open shadow root in a document even if the slot was removed immediately after the assigned nodes were mutated FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a slot element inside a closed shadow root in a document even if the slot was removed immediately after the assigned nodes were mutated FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a slot element inside an open shadow root not in a document even if the slot was removed immediately after the assigned nodes were mutated FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a slot element inside a closed shadow root not in a document even if the slot was removed immediately after the assigned nodes were mutated FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a slot element inside an open shadow root in a document when innerHTML modifies the children of the shadow host FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a slot element inside a closed shadow root in a document when innerHTML modifies the children of the shadow host FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a slot element inside an open shadow root not in a document when innerHTML modifies the children of the shadow host FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a slot element inside a closed shadow root not in a document when innerHTML modifies the children of the shadow host FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a slot element inside an open shadow root in a document when nested slots's contents change FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a slot element inside a closed shadow root in a document when nested slots's contents change FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a slot element inside an open shadow root not in a document when nested slots's contents change FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire on a slot element inside a closed shadow root not in a document when nested slots's contents change FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire at the end of current microtask after mutation observers are invoked inside an open shadow root in a document when slots's contents change FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire at the end of current microtask after mutation observers are invoked inside a closed shadow root in a document when slots's contents change FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire at the end of current microtask after mutation observers are invoked inside an open shadow root not in a document when slots's contents change FAIL Object doesn't support property or method 'attachShadow'
slotchange event must fire at the end of current microtask after mutation observers are invoked inside a closed shadow root not in a document when slots's contents change FAIL Object doesn't support property or method 'attachShadow'
/shadow-dom/slots-fallback-in-document.html
Subtest Results Messages
OK
Shadow DOM: Slots and fallback contents in Document tree FAIL Object doesn't support property or method 'attachShadow'
/shadow-dom/slots-fallback.html
Subtest Results Messages
OK
Slots fallback: Basic. FAIL Object doesn't support property or method 'attachShadow'
Slots fallback: Slots in Slots. FAIL Object doesn't support property or method 'attachShadow'
Slots fallback: Fallback contents should not be used if a node is assigned. FAIL Object doesn't support property or method 'attachShadow'
Slots fallback: Slots in Slots: Assinged nodes should be used as fallback contents of another slot FAIL Object doesn't support property or method 'attachShadow'
Slots fallback: Complex case. FAIL Object doesn't support property or method 'attachShadow'
Slots fallback: Mutation. Append fallback contents. FAIL Object doesn't support property or method 'attachShadow'
Slots fallback: Mutation. Remove fallback contents. FAIL Object doesn't support property or method 'attachShadow'
Slots fallback: Mutation. Assign a node to a slot so that fallback contens are no longer used. FAIL Object doesn't support property or method 'attachShadow'
Slots fallback: Mutation. Remove an assigned node from a slot so that fallback contens will be used. FAIL Object doesn't support property or method 'attachShadow'
Slots fallback: Mutation. Remove a slot which is a fallback content of another slot. FAIL Object doesn't support property or method 'attachShadow'
/shadow-dom/slots.html
Subtest Results Messages
OK
Slots: Basic. FAIL Object doesn't support property or method 'attachShadow'
Slots: Slots in closed. FAIL Object doesn't support property or method 'attachShadow'
Slots: Slots not in a shadow tree. FAIL Object doesn't support property or method 'assignedNodes'
Slots: Distributed nooes for Slots not in a shadow tree. FAIL assert_equals: expected (object) null but got (undefined) undefined
Slots: Name matching FAIL Object doesn't support property or method 'attachShadow'
Slots: No direct host child. FAIL Object doesn't support property or method 'attachShadow'
Slots: Default Slot. FAIL Object doesn't support property or method 'attachShadow'
Slots: Slot in Slot does not matter in assignment. FAIL Object doesn't support property or method 'attachShadow'
Slots: Slot is assigned to another slot FAIL Object doesn't support property or method 'attachShadow'
Slots: Open > Closed. FAIL Object doesn't support property or method 'attachShadow'
Slots: Closed > Closed. FAIL Object doesn't support property or method 'attachShadow'
Slots: Closed > Open. FAIL Object doesn't support property or method 'attachShadow'
Slots: Complex case: Basi line. FAIL Object doesn't support property or method 'attachShadow'
Slots: Mutation: appendChild. FAIL Object doesn't support property or method 'attachShadow'
Slots: Mutation: Change slot= attribute 1. FAIL Object doesn't support property or method 'attachShadow'
Slots: Mutation: Change slot= attribute 2. FAIL Object doesn't support property or method 'attachShadow'
Slots: Mutation: Change slot= attribute 3. FAIL Object doesn't support property or method 'attachShadow'
Slots: Mutation: Remove a child. FAIL Object doesn't support property or method 'attachShadow'
Slots: Mutation: Add a slot: after. FAIL Object doesn't support property or method 'attachShadow'
Slots: Mutation: Add a slot: before. FAIL Object doesn't support property or method 'attachShadow'
Slots: Mutation: Remove a slot. FAIL Object doesn't support property or method 'attachShadow'
Slots: Mutation: Change slot name= attribute. FAIL Object doesn't support property or method 'attachShadow'
Slots: Mutation: Change slot slot= attribute. FAIL Object doesn't support property or method 'attachShadow'

@ghost
Copy link

ghost commented May 17, 2017

View the complete job log.

Chrome (unstable)

Testing web-platform-tests at revision 65932ee
Using browser at version 60.0.3112.10 dev
Starting 10 test iterations
All results were stable

All results

4 tests ran
/shadow-dom/slotchange-event.html
Subtest Results Messages
ERROR
slotchange event must fire on a default slot element inside an open shadow root in a document PASS
slotchange event must fire on a default slot element inside a closed shadow root in a document PASS
slotchange event must fire on a default slot element inside an open shadow root not in a document PASS
slotchange event must fire on a default slot element inside a closed shadow root not in a document PASS
slotchange event must fire on a named slot element insidean open shadow root in a document PASS
slotchange event must fire on a named slot element insidea closed shadow root in a document PASS
slotchange event must fire on a named slot element insidean open shadow root not in a document PASS
slotchange event must fire on a named slot element insidea closed shadow root not in a document PASS
slotchange event must not fire on a slot element inside an open shadow root in a document when another slot's assigned nodes change PASS
slotchange event must not fire on a slot element inside a closed shadow root in a document when another slot's assigned nodes change PASS
slotchange event must not fire on a slot element inside an open shadow root not in a document when another slot's assigned nodes change PASS
slotchange event must not fire on a slot element inside a closed shadow root not in a document when another slot's assigned nodes change PASS
slotchange event must fire on a slot element when a shadow host has a slotable and the slot was inserted and must not fire when the shadow host was mutated after the slot was removed inside an open shadow root in a document FAIL assert_equals: slotchange must be fired on a slot element if there is assigned nodes when the slot was inserted expected 1 but got 0
slotchange event must fire on a slot element when a shadow host has a slotable and the slot was inserted and must not fire when the shadow host was mutated after the slot was removed inside a closed shadow root in a document FAIL assert_equals: slotchange must be fired on a slot element if there is assigned nodes when the slot was inserted expected 1 but got 0
slotchange event must fire on a slot element when a shadow host has a slotable and the slot was inserted and must not fire when the shadow host was mutated after the slot was removed inside an open shadow root not in a document FAIL assert_equals: slotchange must be fired on a slot element if there is assigned nodes when the slot was inserted expected 1 but got 0
slotchange event must fire on a slot element when a shadow host has a slotable and the slot was inserted and must not fire when the shadow host was mutated after the slot was removed inside a closed shadow root not in a document FAIL assert_equals: slotchange must be fired on a slot element if there is assigned nodes when the slot was inserted expected 1 but got 0
slotchange event must fire on a slot element inside an open shadow root in a document even if the slot was removed immediately after the assigned nodes were mutated PASS
slotchange event must fire on a slot element inside a closed shadow root in a document even if the slot was removed immediately after the assigned nodes were mutated PASS
slotchange event must fire on a slot element inside an open shadow root not in a document even if the slot was removed immediately after the assigned nodes were mutated PASS
slotchange event must fire on a slot element inside a closed shadow root not in a document even if the slot was removed immediately after the assigned nodes were mutated PASS
slotchange event must fire on a slot element inside an open shadow root in a document when innerHTML modifies the children of the shadow host PASS
slotchange event must fire on a slot element inside a closed shadow root in a document when innerHTML modifies the children of the shadow host PASS
slotchange event must fire on a slot element inside an open shadow root not in a document when innerHTML modifies the children of the shadow host PASS
slotchange event must fire on a slot element inside a closed shadow root not in a document when innerHTML modifies the children of the shadow host PASS
slotchange event must fire on a slot element inside an open shadow root in a document when nested slots's contents change FAIL assert_equals: slotchange event's target must be the inner slot element at 1st slotchange expected Element node <slot></slot> but got Element node <slot></slot>
slotchange event must fire on a slot element inside a closed shadow root in a document when nested slots's contents change FAIL assert_equals: slotchange event's target must be the inner slot element at 1st slotchange expected Element node <slot></slot> but got Element node <slot></slot>
slotchange event must fire on a slot element inside an open shadow root not in a document when nested slots's contents change FAIL assert_equals: slotchange event's target must be the inner slot element at 1st slotchange expected Element node <slot></slot> but got Element node <slot></slot>
slotchange event must fire on a slot element inside a closed shadow root not in a document when nested slots's contents change FAIL assert_equals: slotchange event's target must be the inner slot element at 1st slotchange expected Element node <slot></slot> but got Element node <slot></slot>
slotchange event must fire at the end of current microtask after mutation observers are invoked inside an open shadow root in a document when slots's contents change PASS
slotchange event must fire at the end of current microtask after mutation observers are invoked inside a closed shadow root in a document when slots's contents change PASS
slotchange event must fire at the end of current microtask after mutation observers are invoked inside an open shadow root not in a document when slots's contents change PASS
slotchange event must fire at the end of current microtask after mutation observers are invoked inside a closed shadow root not in a document when slots's contents change PASS
/shadow-dom/slots-fallback-in-document.html
Subtest Results Messages
OK
Children of a slot in a document tree should not be counted in flattened assigned nodes. FAIL assert_array_equals: lengths differ, expected 1 got 0
Slot fallback content in shadow tree should be counted in flattened assigned nodes. PASS
/shadow-dom/slots-fallback.html
Subtest Results Messages
OK
Slots fallback: Basic. PASS
Slots fallback: Slots in Slots. PASS
Slots fallback: Fallback contents should not be used if a node is assigned. PASS
Slots fallback: Slots in Slots: Assinged nodes should be used as fallback contents of another slot PASS
Slots fallback: Complex case. PASS
Slots fallback: Mutation. Append fallback contents. PASS
Slots fallback: Mutation. Remove fallback contents. PASS
Slots fallback: Mutation. Assign a node to a slot so that fallback contens are no longer used. PASS
Slots fallback: Mutation. Remove an assigned node from a slot so that fallback contens will be used. PASS
Slots fallback: Mutation. Remove a slot which is a fallback content of another slot. FAIL assert_array_equals: fall back contents should be empty because s1 is not in a shadow tree. lengths differ, expected 0 got 1
/shadow-dom/slots.html
Subtest Results Messages
OK
Slots: Basic. PASS
Slots: Slots in closed. PASS
Slots: Slots not in a shadow tree. PASS
Slots: Distributed nooes for Slots not in a shadow tree. FAIL assert_array_equals: lengths differ, expected 0 got 1
Slots: Name matching PASS
Slots: No direct host child. PASS
Slots: Default Slot. PASS
Slots: Slot in Slot does not matter in assignment. PASS
Slots: Slot is assigned to another slot PASS
Slots: Open > Closed. PASS
Slots: Closed > Closed. PASS
Slots: Closed > Open. PASS
Slots: Complex case: Basi line. PASS
Slots: Mutation: appendChild. PASS
Slots: Mutation: Change slot= attribute 1. PASS
Slots: Mutation: Change slot= attribute 2. PASS
Slots: Mutation: Change slot= attribute 3. PASS
Slots: Mutation: Remove a child. PASS
Slots: Mutation: Add a slot: after. PASS
Slots: Mutation: Add a slot: before. PASS
Slots: Mutation: Remove a slot. PASS
Slots: Mutation: Change slot name= attribute. PASS
Slots: Mutation: Change slot slot= attribute. PASS

@hayatoito hayatoito force-pushed the hayatoito/update-slotchange branch from 759b487 to 627ed45 Compare May 17, 2017 07:14
@hayatoito hayatoito changed the title shadow-dom: Update the test to consider a slotchange event when a slo… Update slotchange event tests for slots being inserted May 17, 2017
@hayatoito hayatoito force-pushed the hayatoito/update-slotchange branch 2 times, most recently from eebb9d0 to 00f36c3 Compare June 5, 2017 07:21
This corresponds to the DOM Standard change:
whatwg/dom#459.

We might want to clean up tests further because this patch is rather
the minimum effort to catch up the DOM Standard's change, but should be
good enough.
@hayatoito hayatoito force-pushed the hayatoito/update-slotchange branch from 00f36c3 to d28a7f3 Compare June 5, 2017 07:24
@hayatoito hayatoito changed the title Update slotchange event tests for slots being inserted Update tests for slot change events Jun 5, 2017
@hayatoito
Copy link
Member Author

I have updated the PR so that it reflects the latest whatwg/dom#459.
@rniwa Could you have a chance to take a look?
We might want to clean up tests further, but this PR could be good enough to catch up the DOM Standard's change.

cc: @domenic

@hayatoito
Copy link
Member Author

@TakayoshiKochi Could you review this too?

@TakayoshiKochi
Copy link
Member

LGTM

Copy link
Member

@TakayoshiKochi TakayoshiKochi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@TakayoshiKochi TakayoshiKochi merged commit ce33325 into web-platform-tests:master Jun 9, 2017
scheib pushed a commit to scheib/chromium that referenced this pull request Jun 16, 2017
…nge concept

Rewrite the core part of the Shadow DOM v1 distribution engine so that
distribution recalculation happens *if and only if* a newly-defined concept of
a slotchange actually happens.

Benefits:

- Performance improvement
- Eliminated code complexity
- Becomes spec-compliant (as a side effect, this is one of the motivations of rewriting)

1. Performance improvement:

The result of PerformanceTests/ShadowDOM performance tests:

                v1-distribution-disconnected-and-reconnected
    Before CL:  201.4 ms
    After CL:    41.7 ms  (5x times faster)

2. Eliminated code complexity:

Though I have a plan to explain the detail about how the v1 distribution engine
works in core/dom/shadow/README.md file, let me explain the benefits of the new
design here other than the performance tests:

- Eliminated false-positive for setting a dirty flag for distribution recalculation

  Before this CL, the engine sets a dirty flag for distribution conservatively.
  As a result, a false-positive can happen, which has been difficult to avoid
  because distribution is not a local effect. We don't have much budget of time
  in DOM mutation.

  After this CL, the engine sets a dirty flag if and only if a slotchange
  actually happens. No longer needs to set a dirty flag in other places.

  Note that the engine only detects the fact of "a slotchange happens", but it doesn't
  try to know an exact distributed nodes for each slot at the timing of DOM mutation
  so that DOM mutation should not be blocked more than necessary.  Distributed
  nodes are lazily-calculated later.

- Life cycle of slot's distribution nodes became more clear

   The engine no longer clears out each slot's distributed nodes in
  shadow-including descendant subtrees when the subtree is disconnected from
  the parent tree.

   e.g. We don't need to update distribution for a custom element which has
  deeply nested other custom elements inside of it at each insertion/removal
  from a tree.

   The performance test's improvement came mostly from this result.

- Eliminated a lot of tricky code which is needed to support <slot> in non-shadow trees.

   I successfully stopped to support <slot> in non-shadow trees, and upstreamed
  the decision to WHATWG DOM Standard [1], getting agreement from other browser
  vendors [2].  I have already updated web platform tests [3] too.  These tests
  no longer fail after this CL.

   The support of <slot> in non-shadow trees has been difficult to support, and
  has been the cause of crashes.  We no longer have to fight with crashes.

3. Becomes spec-compliant (as a side effect, this is one of the motivations of rewriting)

From the Web developers' perspective, this CL shouldn't have any practical
impact, as long as a slot element is only used in shadow trees. The only
practical visible change is:

A slotchange event is always signaled as a microtask whenever a slot's
distributed nodes are changed.

For example, when a slot is inserted or removed from a tree, a slotchange event
can be fired. Before this CL, a slotchange is never fired in this case.  See
DOM Standard issue [2] for details, which is rather a feature request from web
developers.  This CL satisfies this requirement, as an intended side effect.

I am aware that it would be better to separate the engine rewriting from the user
visible changes, but it would require unnecessary efforts to keep the old behavior in the
new engine. Thus, I put all together. Supporting [2] is one of the reasons I decided to
rewrite the engine.

Note that only Shadow DOM v1 can get these benefits. Shadow DOM v0 is out of the
scope of this CL.

- [1] DOM Standard change: whatwg/dom#459
- [2] DOM Standard issue: whatwg/dom#447
- [3] Web platform tests change: web-platform-tests/wpt#5954

Links: 
Change-Id: I41f29e781185c46739377ab3939d20fa24fb69bf
Reviewed-on: https://chromium-review.googlesource.com/532734
Commit-Queue: Hayato Ito <[email protected]>
Reviewed-by: Takayoshi Kochi <[email protected]>
Reviewed-by: Kent Tamura <[email protected]>
Cr-Commit-Position: refs/heads/master@{#480013}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants