import * as assert from 'assert.js'; import { tick } from 'svelte'; import './main.svelte'; export default async function (target) { target.innerHTML = ''; await tick(); const el = target.querySelector('custom-element'); assert.equal(el.shadowRoot.innerHTML, '

Hello world!

1

2

'); el.setAttribute('camel-case', 'universe'); el.setAttribute('an-array', '[3,4]'); el.setAttribute('camelcase2', 'Hi'); await tick(); assert.equal(el.shadowRoot.innerHTML, '

Hi universe!

3

4

'); assert.equal( target.innerHTML, '' ); el.camelCase = 'galaxy'; el.camelCase2 = 'Hey'; el.anArray = [5, 6]; await tick(); assert.equal(el.shadowRoot.innerHTML, '

Hey galaxy!

5

6

'); assert.equal( target.innerHTML, '' ); }