Skip to content

Commit af17d4f

Browse files
committed
Add testcase
1 parent d22cb94 commit af17d4f

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

Diff for: tests/lib/rules/no-parsing-error.js

+26
Original file line numberDiff line numberDiff line change
@@ -615,6 +615,32 @@ tester.run('no-parsing-error', rule, {
615615
{
616616
code: '<template><div xmlns=""></template>',
617617
errors: ['Parsing error: x-invalid-namespace.']
618+
},
619+
620+
//style vars
621+
{
622+
filename: 'test.vue',
623+
code: `
624+
<template></template>
625+
<style>
626+
.text {
627+
color: v-bind(color.);
628+
font-size: v-bind('font size');
629+
}
630+
</style>
631+
`,
632+
errors: [
633+
{
634+
message: 'Parsing error: Unexpected end of expression.',
635+
line: 5,
636+
column: 33
637+
},
638+
{
639+
message: 'Parsing error: Unexpected token size.',
640+
line: 6,
641+
column: 37
642+
}
643+
]
618644
}
619645
]
620646
})

0 commit comments

Comments
 (0)