From d50aace3abfbcaae959ed67bed7c9b1050f6edd4 Mon Sep 17 00:00:00 2001 From: Brett Zamir Date: Fri, 29 Jan 2021 19:39:12 +0800 Subject: [PATCH] Fix error message --- src/rules/requireAsteriskPrefix.js | 4 ++-- test/rules/assertions/requireAsteriskPrefix.js | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/rules/requireAsteriskPrefix.js b/src/rules/requireAsteriskPrefix.js index 070a5a742..fff998188 100644 --- a/src/rules/requireAsteriskPrefix.js +++ b/src/rules/requireAsteriskPrefix.js @@ -27,7 +27,7 @@ export default iterateJsdoc(({ tokens.postDelimiter = ''; }; - utils.reportJSDoc('Expected JSDoc block to have no prefix.', { + utils.reportJSDoc('Expected JSDoc line to have no prefix.', { column: 0, line: number, }, fix); @@ -53,7 +53,7 @@ export default iterateJsdoc(({ tokens.postDelimiter = ' '; }; - utils.reportJSDoc('Expected JSDoc block to have the prefix.', { + utils.reportJSDoc('Expected JSDoc line to have the prefix.', { column: 0, line: number, }, fix); diff --git a/test/rules/assertions/requireAsteriskPrefix.js b/test/rules/assertions/requireAsteriskPrefix.js index 1c2ce22c9..4e5466bbe 100644 --- a/test/rules/assertions/requireAsteriskPrefix.js +++ b/test/rules/assertions/requireAsteriskPrefix.js @@ -13,7 +13,7 @@ export default { errors: [ { line: 4, - message: 'Expected JSDoc block to have the prefix.', + message: 'Expected JSDoc line to have the prefix.', }, ], output: ` @@ -37,7 +37,7 @@ export default { errors: [ { line: 3, - message: 'Expected JSDoc block to have the prefix.', + message: 'Expected JSDoc line to have the prefix.', }, ], output: ` @@ -61,7 +61,7 @@ export default { errors: [ { line: 4, - message: 'Expected JSDoc block to have no prefix.', + message: 'Expected JSDoc line to have no prefix.', }, ], options: ['never'], @@ -86,7 +86,7 @@ export default { errors: [ { line: 3, - message: 'Expected JSDoc block to have no prefix.', + message: 'Expected JSDoc line to have no prefix.', }, ], options: ['never'],