Skip to content

Commit 819ead3

Browse files
committed
chore: update test
1 parent f657781 commit 819ead3

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

packages/compiler/test/transforms/__snapshots__/vBind.spec.ts.snap

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,13 @@ exports[`compiler v-bind > no expression 1`] = `
3232
"
3333
`;
3434

35+
exports[`compiler v-bind > number value 1`] = `
36+
"
37+
const n0 = _createComponent(Comp, { depth: () => (0) }, null, true)
38+
return n0
39+
"
40+
`;
41+
3542
exports[`compiler v-bind > with constant value 1`] = `
3643
"
3744
const n0 = t0()

packages/compiler/test/transforms/vBind.spec.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -557,4 +557,10 @@ describe('compiler v-bind', () => {
557557
)
558558
expect(code).matchSnapshot()
559559
})
560+
561+
test('number value', () => {
562+
const { code } = compileWithVBind(`<Comp depth={0} />`)
563+
expect(code).matchSnapshot()
564+
expect(code).contains('{ depth: () => (0) }')
565+
})
560566
})

0 commit comments

Comments
 (0)