From 2b65b491cea2c956e4ba314a809915b9ec62933b Mon Sep 17 00:00:00 2001 From: Gareth Jones Date: Sun, 14 Mar 2021 11:17:06 +1300 Subject: [PATCH] fix(no-focused-tests): report on `skip` instead of `concurrent` (#791) --- src/rules/__tests__/no-focused-tests.test.ts | 4 ++-- src/rules/no-focused-tests.ts | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/rules/__tests__/no-focused-tests.test.ts b/src/rules/__tests__/no-focused-tests.test.ts index 36d2fb087..0bc9ae7a3 100644 --- a/src/rules/__tests__/no-focused-tests.test.ts +++ b/src/rules/__tests__/no-focused-tests.test.ts @@ -114,7 +114,7 @@ ruleTester.run('no-focused-tests', rule, { errors: [ { messageId: 'focusedTest', - column: 4, + column: 15, line: 1, suggestions: [ { @@ -194,7 +194,7 @@ ruleTester.run('no-focused-tests', rule, { errors: [ { messageId: 'focusedTest', - column: 6, + column: 17, line: 1, suggestions: [ { diff --git a/src/rules/no-focused-tests.ts b/src/rules/no-focused-tests.ts index 96a6e01c0..89ffb3500 100644 --- a/src/rules/no-focused-tests.ts +++ b/src/rules/no-focused-tests.ts @@ -99,7 +99,9 @@ export default createRule({ ) { context.report({ messageId: 'focusedTest', - node: calleeObject.property, + node: isConcurrentExpression(calleeObject) + ? callee.property + : calleeObject.property, suggest: [ { messageId: 'suggestRemoveFocus',