Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 28e9bf4

Browse files
authored
test(no-arrow-functions-in-watch): make tests more strict (#2860)
1 parent 158a085 commit 28e9bf4

File tree

1 file changed

+33
-7
lines changed

1 file changed

+33
-7
lines changed

‎tests/lib/rules/no-arrow-functions-in-watch.js

Lines changed: 33 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,15 @@ ruleTester.run('no-arrow-functions-in-watch', rule, {
131131
foo: () => {}
132132
},
133133
}`,
134-
errors: ['You should not use an arrow function to define a watcher.']
134+
errors: [
135+
{
136+
message: 'You should not use an arrow function to define a watcher.',
137+
line: 4,
138+
column: 16,
139+
endLine: 4,
140+
endColumn: 24
141+
}
142+
]
135143
},
136144
{
137145
filename: 'test.vue',
@@ -145,7 +153,10 @@ ruleTester.run('no-arrow-functions-in-watch', rule, {
145153
errors: [
146154
{
147155
message: 'You should not use an arrow function to define a watcher.',
148-
line: 5
156+
line: 5,
157+
column: 16,
158+
endLine: 5,
159+
endColumn: 24
149160
}
150161
]
151162
},
@@ -161,7 +172,10 @@ ruleTester.run('no-arrow-functions-in-watch', rule, {
161172
errors: [
162173
{
163174
message: 'You should not use an arrow function to define a watcher.',
164-
line: 5
175+
line: 5,
176+
column: 16,
177+
endLine: 5,
178+
endColumn: 24
165179
}
166180
]
167181
},
@@ -207,7 +221,10 @@ ruleTester.run('no-arrow-functions-in-watch', rule, {
207221
errors: [
208222
{
209223
message: 'You should not use an arrow function to define a watcher.',
210-
line: 15
224+
line: 15,
225+
column: 14,
226+
endLine: 17,
227+
endColumn: 12
211228
}
212229
]
213230
},
@@ -227,7 +244,10 @@ ruleTester.run('no-arrow-functions-in-watch', rule, {
227244
errors: [
228245
{
229246
message: 'You should not use an arrow function to define a watcher.',
230-
line: 8
247+
line: 8,
248+
column: 22,
249+
endLine: 8,
250+
endColumn: 30
231251
}
232252
]
233253
},
@@ -248,11 +268,17 @@ ruleTester.run('no-arrow-functions-in-watch', rule, {
248268
errors: [
249269
{
250270
message: 'You should not use an arrow function to define a watcher.',
251-
line: 6
271+
line: 6,
272+
column: 13,
273+
endLine: 6,
274+
endColumn: 43
252275
},
253276
{
254277
message: 'You should not use an arrow function to define a watcher.',
255-
line: 8
278+
line: 8,
279+
column: 24,
280+
endLine: 8,
281+
endColumn: 54
256282
}
257283
]
258284
}

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /