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/packages/svelte/tests/runtime-runes/samples/svg-element-attribute-seria.../_config.js

19 lines
433 B

import { flushSync } from '../../../../src/index-client';
import { test, ok } from '../../test';
export default test({
mode: ['client'],
test({ assert, target }) {
const svg = target.querySelector('svg');
const button = target.querySelector('button');
ok(svg);
ok(button);
assert.equal(svg.getAttribute('class'), '0');
flushSync(() => {
button.click();
});
assert.equal(svg.getAttribute('class'), '1');
}
});