mirror of https://github.com/sveltejs/svelte
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.
32 lines
549 B
32 lines
549 B
6 years ago
|
export default {
|
||
|
props: {
|
||
|
foo: 'lol',
|
||
|
baz: 40 + 2,
|
||
|
qux: `this is a ${'piece of'} string`,
|
||
|
quux: 'core'
|
||
|
},
|
||
|
|
||
|
html: `
|
||
|
<div><p>foo: lol</p>
|
||
|
<p>baz: 42 (number)</p>
|
||
|
<p>qux: named</p>
|
||
|
<p>quux: core</p></div>
|
||
|
`,
|
||
|
|
||
|
async test({ assert, component, target }) {
|
||
|
await component.$set({
|
||
|
foo: 'wut',
|
||
|
baz: 40 + 3,
|
||
|
qux: `this is a ${'rather boring'} string`,
|
||
|
quux: 'heart'
|
||
|
});
|
||
|
|
||
|
assert.htmlEqual(target.innerHTML, `
|
||
|
<div><p>foo: wut</p>
|
||
|
<p>baz: 43 (number)</p>
|
||
|
<p>qux: named</p>
|
||
|
<p>quux: heart</p></div>
|
||
|
`);
|
||
|
}
|
||
|
};
|