eslint-plugin-jest 28.13.4 → 28.14.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -80,7 +80,7 @@ var _default = exports.default = (0, _utils2.createRule)({
80
80
  if (importNode?.type === _utils.AST_NODE_TYPES.ImportDeclaration) {
81
81
  for (const specifier of importNode.specifiers) {
82
82
  if (specifier.type === _utils.AST_NODE_TYPES.ImportSpecifier) {
83
- let importName = specifier.imported.name ?? '';
83
+ let importName = 'name' in specifier.imported ? specifier.imported.name : '';
84
84
  const local = (0, _utils2.getAccessorValue)(specifier.local);
85
85
  if (local !== importName) {
86
86
  importName = `${importName} as ${local}`;
@@ -21,6 +21,8 @@ const baseRule = (() => {
21
21
  }
22
22
  })();
23
23
  const DEFAULT_MESSAGE = 'This rule requires `@typescript-eslint/eslint-plugin`';
24
+
25
+ // todo: remove these along with the actual runtime properties below in new major
24
26
  var _default = exports.default = (0, _utils2.createRule)({
25
27
  defaultOptions: [{
26
28
  ignoreStatic: false
@@ -37,9 +39,11 @@ var _default = exports.default = (0, _utils2.createRule)({
37
39
  ...baseRule?.meta,
38
40
  docs: {
39
41
  description: 'Enforce unbound methods are called with their expected scope',
42
+ /** @deprecated */
40
43
  requiresTypeChecking: true,
41
44
  ...baseRule?.meta.docs,
42
45
  // mark this as not recommended
46
+ /** @deprecated */
43
47
  recommended: undefined
44
48
  }
45
49
  },
@@ -217,7 +217,7 @@ const describeImportDefAsImport = def => {
217
217
  }
218
218
  return {
219
219
  source: def.parent.source.value,
220
- imported: def.node.imported.name,
220
+ imported: 'name' in def.node.imported ? def.node.imported.name : def.node.imported.value,
221
221
  local: def.node.local.name
222
222
  };
223
223
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eslint-plugin-jest",
3
- "version": "28.13.4",
3
+ "version": "28.14.0",
4
4
  "description": "ESLint rules for Jest",
5
5
  "keywords": [
6
6
  "eslint",
@@ -85,9 +85,9 @@
85
85
  "@types/jest": "^29.0.0",
86
86
  "@types/node": "^16.0.0",
87
87
  "@types/semver": "^7.5.8",
88
- "@typescript-eslint/eslint-plugin": "^7.0.0",
89
- "@typescript-eslint/parser": "^7.0.0",
90
- "@typescript-eslint/utils": "^7.0.0",
88
+ "@typescript-eslint/eslint-plugin": "^8.0.0",
89
+ "@typescript-eslint/parser": "^8.0.0",
90
+ "@typescript-eslint/utils": "^8.0.0",
91
91
  "babel-jest": "^29.0.0",
92
92
  "babel-plugin-replace-ts-export-assignment": "^0.0.2",
93
93
  "dedent": "^1.5.0",