export default {
html: `
0
`,
async test({ assert, target, window }) {
const buttons = target.querySelectorAll('button');
const click = new window.MouseEvent('click');
await buttons[0].dispatchEvent(click);
assert.htmlEqual(target.innerHTML, `
1
`);
await buttons[1].dispatchEvent(click);
assert.htmlEqual(target.innerHTML, `
0
`);
await buttons[0].dispatchEvent(click);
assert.htmlEqual(target.innerHTML, `
1
`);
}
};