Skip to content

Commit a71305c

Browse files
committed
✅ test(module): add test
1 parent b1fa1d9 commit a71305c

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

test/module.test.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,3 +69,10 @@ test('detect missing translation', t => {
6969
t.is(render, `with(this){return _c(\'p\',{domProps:{"textContent":_s("foo.bar")}})}`)
7070
t.deepEqual(errors, [])
7171
})
72+
73+
test('fallback custom directive', t => {
74+
const { ast, render, errors } = compile(`<p v-t="'foo.bar'"></p>`)
75+
t.falsy(ast.i18n)
76+
t.deepEqual(ast.directives[0], { name: 't', rawName: 'v-t', value: '\'foo.bar\'', arg: null, modifiers: undefined })
77+
t.deepEqual(errors, [])
78+
})

0 commit comments

Comments
 (0)