eslint-plugin-jest
Advanced tools
Comparing version 26.8.6 to 26.8.7
@@ -35,4 +35,6 @@ "use strict"; | ||
const suggestions = [['suggestAddingHasAssertions', 'expect.hasAssertions();'], ['suggestAddingAssertions', 'expect.assertions();']]; | ||
// const suggestions: Array<[MessageIds, string]> = [ | ||
// ['suggestAddingHasAssertions', 'expect.hasAssertions();'], | ||
// ['suggestAddingAssertions', 'expect.assertions();'], | ||
// ]; | ||
var _default = (0, _utils2.createRule)({ | ||
@@ -217,10 +219,6 @@ name: __filename, | ||
if (!(0, _utils2.isFunction)(testFn) || testFn.body.type !== _utils.AST_NODE_TYPES.BlockStatement) { | ||
if (!(0, _utils2.isFunction)(testFn) || !shouldCheckFunction(testFn)) { | ||
return; | ||
} | ||
if (!shouldCheckFunction(testFn)) { | ||
return; | ||
} | ||
hasExpectInLoop = false; | ||
@@ -234,2 +232,8 @@ hasExpectInCallback = false; | ||
const suggestions = []; | ||
if (testFn.body.type === _utils.AST_NODE_TYPES.BlockStatement) { | ||
suggestions.push(['suggestAddingHasAssertions', 'expect.hasAssertions();'], ['suggestAddingAssertions', 'expect.assertions();']); | ||
} | ||
context.report({ | ||
@@ -236,0 +240,0 @@ messageId: 'haveExpectAssertions', |
{ | ||
"name": "eslint-plugin-jest", | ||
"version": "26.8.6", | ||
"version": "26.8.7", | ||
"description": "ESLint rules for Jest", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
298773
5151