You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
svelte/test/generator/samples/component-binding-deep/_config.js

23 lines
425 B

export default {
html: `
<input>
<p>foo</p>
`,
test ( assert, component, target, window ) {
const event = new window.MouseEvent( 'input' );
const input = target.querySelector( 'input' );
input.value = 'blah';
input.dispatchEvent( event );
assert.deepEqual( component.get( 'deep' ), { name: 'blah' } );
assert.htmlEqual( target.innerHTML, `
<input>
<p>blah</p>
` );
component.destroy();
}
};