From 9eb28318102df551d32725e733af988ac5c41778 Mon Sep 17 00:00:00 2001 From: ST-DDT Date: Sun, 20 Jul 2025 19:05:16 +0200 Subject: [PATCH] test(comma-dangle): make tests more strict --- tests/lib/rules/comma-dangle.js | 32 ++++++++++++++++++++++++++------ 1 file changed, 26 insertions(+), 6 deletions(-) diff --git a/tests/lib/rules/comma-dangle.js b/tests/lib/rules/comma-dangle.js index 2792b93f5..61c649dce 100644 --- a/tests/lib/rules/comma-dangle.js +++ b/tests/lib/rules/comma-dangle.js @@ -63,7 +63,10 @@ tester.run('comma-dangle', rule, { errors: [ { message: 'Unexpected trailing comma.', - line: 3 + line: 3, + column: 41, + endLine: 3, + endColumn: 42 } ] }, @@ -84,7 +87,10 @@ tester.run('comma-dangle', rule, { errors: [ { message: 'Unexpected trailing comma.', - line: 3 + line: 3, + column: 40, + endLine: 3, + endColumn: 41 } ] }, @@ -113,11 +119,17 @@ tester.run('comma-dangle', rule, { errors: [ { message: 'Unexpected trailing comma.', - line: 4 + line: 4, + column: 21, + endLine: 4, + endColumn: 22 }, { message: 'Missing trailing comma.', - line: 7 + line: 7, + column: 16, + endLine: 8, + endColumn: 1 } ] }, @@ -132,7 +144,11 @@ tester.run('comma-dangle', rule, { `, errors: [ { - message: 'Unexpected trailing comma.' + message: 'Unexpected trailing comma.', + line: 3, + column: 23, + endLine: 3, + endColumn: 24 } ] }, @@ -148,7 +164,11 @@ tester.run('comma-dangle', rule, { options: ['always'], errors: [ { - message: 'Missing trailing comma.' + message: 'Missing trailing comma.', + line: 3, + column: 23, + endLine: 3, + endColumn: 24 } ] }