export default { props: { thePromise: new Promise(resolve => {}) }, html: ` loading... `, async test({ assert, component, target }) { await (component.thePromise = Promise.resolve([1, 2])); assert.htmlEqual( target.innerHTML, `
a: 1
b: 2
` ); await (component.thePromise = Promise.resolve([4, 5])); assert.htmlEqual( target.innerHTML, `a: 4
b: 5
` ); try { await (component.thePromise = Promise.reject(['a', [6, 7]])); } catch (e) { // do nothing } assert.htmlEqual( target.innerHTML, `c: a
d: 6
e: 7
` ); try { await (component.thePromise = Promise.reject(['b', [8, 9]])); } catch (e) { // do nothing } assert.htmlEqual( target.innerHTML, `c: b
d: 8
e: 9
` ); } };