Skip to content

Commit 4211825

Browse files
wip(tests): update 'should pass vue-template-es2015-compiler test "arg spread"' test
1 parent f96cddc commit 4211825

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tests/basic.test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -800,15 +800,15 @@ const { defaultFilesFactory, createPage } = require('./testsTools.js');
800800

801801
'/main.vue': `
802802
<template>
803-
<button @click="(...args) => { store.foo(...args) }">Go</button>
803+
<div id="result">{{ JSON.stringify( ((...args) => args)(1,2,3) ) }}</div>
804804
</template>
805805
`,
806806
}
807807
});
808808

809809
// original Vue2 expected match: `_vm.store.foo.apply(_vm.store, args)`
810810
// Vue3 expected match: `_ctx.store.foo(...args)`
811-
await expect(page.$eval('#app', el => el.vueApp.$options.render.toString()) ).resolves.toMatch(`.store.foo(...args)`);
811+
await expect(page.$eval('#result', el => el.textContent)).resolves.toMatch('[1,2,3]');
812812
});
813813

814814

0 commit comments

Comments
 (0)