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/test/runtime/samples/transition-js-if-else-block.../_config.js

21 lines
506 B

export default {
test ( assert, component, target, window, raf ) {
assert.equal( target.querySelector( 'div' ), component.refs.no );
assert.equal( component.refs.no.foo, 0 );
raf.tick( 200 );
assert.equal( component.refs.no.foo, 0.5 );
raf.tick( 500 );
component.set({ x: true });
assert.equal( component.refs.no, undefined );
assert.equal( component.refs.yes.foo, 0 );
raf.tick( 700 );
assert.equal( component.refs.yes.foo, 0.5 );
raf.tick( 1000 );
component.destroy();
}
};