3128: Test to show nested slots fails

pull/3136/head
Cameron Stitt 6 years ago
parent 80ef6f190d
commit 370e117eea

@ -105,8 +105,9 @@ describe('custom-elements', function() {
const page = await browser.newPage();
page.on('console', (type, ...args) => {
console[type](...args);
page.on('console', msg => {
for (let i = 0; i < msg.args().length; ++i)
console[msg.type()](`${i}: ${msg.args()[i]}`);
});
try {

@ -0,0 +1,3 @@
<svelte:options tag="my-block"/>
<div><slot></slot></div>

@ -0,0 +1,7 @@
<svelte:options tag="my-app"/>
<script>
import Block from './Block.svelte';
</script>
<Block><strong>Name</strong></Block>

@ -0,0 +1,13 @@
import * as assert from 'assert';
import './main.svelte';
export default async function (target) {
target.innerHTML = '<my-app/>';
const el = target.querySelector('my-app');
const block = el.shadowRoot.children[0];
const [slot] = block.children;
assert.equal(slot.assignedNodes().length, 1);
}
Loading…
Cancel
Save