@vitest/eslint-plugin 1.1.25 → 1.1.26

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vitest/eslint-plugin",
3
- "version": "1.1.25",
3
+ "version": "1.1.26",
4
4
  "license": "MIT",
5
5
  "description": "Eslint plugin for vitest",
6
6
  "repository": "vitest-dev/eslint-plugin-vitest",
@@ -16,12 +16,25 @@
16
16
  "type": "module",
17
17
  "main": "./dist/index.cjs",
18
18
  "module": "./dist/index.mjs",
19
- "types": "./dist/index.d.ts",
19
+ "types": "./dist/index.d.cts",
20
20
  "exports": {
21
21
  ".": {
22
- "types": "./dist/index.d.ts",
23
- "import": "./dist/index.mjs",
24
- "require": "./dist/index.cjs"
22
+ "module-sync": {
23
+ "types": "./dist/index.d.mts",
24
+ "default": "./dist/index.mjs"
25
+ },
26
+ "module": {
27
+ "types": "./dist/index.d.mts",
28
+ "default": "./dist/index.mjs"
29
+ },
30
+ "import": {
31
+ "types": "./dist/index.d.mts",
32
+ "default": "./dist/index.mjs"
33
+ },
34
+ "require": {
35
+ "types": "./dist/index.d.cts",
36
+ "default": "./dist/index.cjs"
37
+ }
25
38
  },
26
39
  "./package.json": "./package.json"
27
40
  },
@@ -29,25 +42,25 @@
29
42
  "dist"
30
43
  ],
31
44
  "devDependencies": {
32
- "@stylistic/eslint-plugin": "^2.12.1",
45
+ "@stylistic/eslint-plugin": "^2.13.0",
33
46
  "@types/eslint": "^9.6.1",
34
47
  "@types/mocha": "^10.0.10",
35
- "@types/node": "^22.10.5",
36
- "@typescript-eslint/eslint-plugin": "8.19.0",
37
- "@typescript-eslint/parser": "8.19.0",
38
- "@typescript-eslint/rule-tester": "8.18.2",
39
- "@vitest/eslint-plugin": "^1.1.24",
40
- "bumpp": "^9.9.2",
48
+ "@types/node": "^22.13.0",
49
+ "@typescript-eslint/eslint-plugin": "8.22.0",
50
+ "@typescript-eslint/parser": "8.22.0",
51
+ "@typescript-eslint/rule-tester": "8.22.0",
52
+ "@vitest/eslint-plugin": "^1.1.25",
53
+ "bumpp": "^9.11.1",
41
54
  "concurrently": "^9.1.2",
42
- "eslint": "^9.17.0",
55
+ "eslint": "^9.19.0",
43
56
  "eslint-doc-generator": "^2.0.2",
44
57
  "eslint-plugin-eslint-plugin": "^6.4.0",
45
58
  "eslint-remote-tester": "^4.0.1",
46
59
  "eslint-remote-tester-repositories": "^2.0.0",
47
60
  "tsx": "^4.19.2",
48
- "typescript": "^5.7.2",
49
- "unbuild": "^3.2.0",
50
- "vitest": "^2.1.8"
61
+ "typescript": "^5.7.3",
62
+ "unbuild": "^3.3.1",
63
+ "vitest": "^3.0.4"
51
64
  },
52
65
  "peerDependencies": {
53
66
  "@typescript-eslint/utils": ">= 8.0",
@@ -64,11 +77,11 @@
64
77
  }
65
78
  },
66
79
  "scripts": {
67
- "build": "unbuild",
80
+ "build": "unbuild --config unbuild.config.ts",
68
81
  "lint:eslint-docs": "pnpm build && eslint-doc-generator --check",
69
82
  "lint:js": "eslint . --fix",
70
83
  "lint": "concurrently --prefixColors auto \"pnpm:lint:*\"",
71
- "release": "pnpm build && bumpp package.json --commit --push --tag && pnpm publish",
84
+ "release": "bumpp package.json --commit --push --tag && pnpm build && pnpm publish",
72
85
  "stub": "unbuild --stub",
73
86
  "test:ci": "vitest run",
74
87
  "test": "vitest",
package/dist/index.d.ts DELETED
@@ -1,213 +0,0 @@
1
- import * as eslint from 'eslint';
2
- import { ESLint } from 'eslint';
3
-
4
- declare const plugin: {
5
- meta: {
6
- name: string;
7
- version: string;
8
- };
9
- rules: {
10
- "prefer-lowercase-title": eslint.Rule.RuleModule;
11
- "max-nested-describe": eslint.Rule.RuleModule;
12
- "no-identical-title": eslint.Rule.RuleModule;
13
- "no-focused-tests": eslint.Rule.RuleModule;
14
- "no-conditional-tests": eslint.Rule.RuleModule;
15
- "expect-expect": eslint.Rule.RuleModule;
16
- "consistent-test-it": eslint.Rule.RuleModule;
17
- "prefer-to-be": eslint.Rule.RuleModule;
18
- "no-hooks": eslint.Rule.RuleModule;
19
- "no-restricted-vi-methods": eslint.Rule.RuleModule;
20
- "consistent-test-filename": eslint.Rule.RuleModule;
21
- "max-expects": eslint.Rule.RuleModule;
22
- "no-alias-methods": eslint.Rule.RuleModule;
23
- "no-commented-out-tests": eslint.Rule.RuleModule;
24
- "no-conditional-expect": eslint.Rule.RuleModule;
25
- "no-conditional-in-test": eslint.Rule.RuleModule;
26
- "no-disabled-tests": eslint.Rule.RuleModule;
27
- "no-done-callback": eslint.Rule.RuleModule;
28
- "no-duplicate-hooks": eslint.Rule.RuleModule;
29
- "no-large-snapshots": eslint.Rule.RuleModule;
30
- "no-interpolation-in-snapshots": eslint.Rule.RuleModule;
31
- "no-mocks-import": eslint.Rule.RuleModule;
32
- "no-restricted-matchers": eslint.Rule.RuleModule;
33
- "no-standalone-expect": eslint.Rule.RuleModule;
34
- "no-test-prefixes": eslint.Rule.RuleModule;
35
- "no-test-return-statement": eslint.Rule.RuleModule;
36
- "no-import-node-test": eslint.Rule.RuleModule;
37
- "prefer-called-with": eslint.Rule.RuleModule;
38
- "valid-title": eslint.Rule.RuleModule;
39
- "valid-expect": eslint.Rule.RuleModule;
40
- "prefer-to-be-falsy": eslint.Rule.RuleModule;
41
- "prefer-to-be-object": eslint.Rule.RuleModule;
42
- "prefer-to-be-truthy": eslint.Rule.RuleModule;
43
- "prefer-to-have-length": eslint.Rule.RuleModule;
44
- "prefer-equality-matcher": eslint.Rule.RuleModule;
45
- "prefer-strict-equal": eslint.Rule.RuleModule;
46
- "prefer-expect-resolves": eslint.Rule.RuleModule;
47
- "prefer-each": eslint.Rule.RuleModule;
48
- "prefer-hooks-on-top": eslint.Rule.RuleModule;
49
- "prefer-hooks-in-order": eslint.Rule.RuleModule;
50
- "require-local-test-context-for-concurrent-snapshots": eslint.Rule.RuleModule;
51
- "prefer-mock-promise-shorthand": eslint.Rule.RuleModule;
52
- "prefer-vi-mocked": eslint.Rule.RuleModule;
53
- "prefer-snapshot-hint": eslint.Rule.RuleModule;
54
- "valid-describe-callback": eslint.Rule.RuleModule;
55
- "require-top-level-describe": eslint.Rule.RuleModule;
56
- "require-to-throw-message": eslint.Rule.RuleModule;
57
- "require-hook": eslint.Rule.RuleModule;
58
- "prefer-todo": eslint.Rule.RuleModule;
59
- "prefer-spy-on": eslint.Rule.RuleModule;
60
- "prefer-comparison-matcher": eslint.Rule.RuleModule;
61
- "prefer-to-contain": eslint.Rule.RuleModule;
62
- "prefer-expect-assertions": eslint.Rule.RuleModule;
63
- "padding-around-after-all-blocks": eslint.Rule.RuleModule;
64
- "padding-around-after-each-blocks": eslint.Rule.RuleModule;
65
- "padding-around-all": eslint.Rule.RuleModule;
66
- "padding-around-before-all-blocks": eslint.Rule.RuleModule;
67
- "padding-around-before-each-blocks": eslint.Rule.RuleModule;
68
- "padding-around-describe-blocks": eslint.Rule.RuleModule;
69
- "padding-around-expect-groups": eslint.Rule.RuleModule;
70
- "padding-around-test-blocks": eslint.Rule.RuleModule;
71
- "valid-expect-in-promise": eslint.Rule.RuleModule;
72
- };
73
- environments: {
74
- env: {
75
- globals: {
76
- suite: true;
77
- test: true;
78
- describe: true;
79
- it: true;
80
- expectTypeOf: true;
81
- assertType: true;
82
- expect: true;
83
- assert: true;
84
- vitest: true;
85
- vi: true;
86
- beforeAll: true;
87
- afterAll: true;
88
- beforeEach: true;
89
- afterEach: true;
90
- onTestFailed: true;
91
- onTestFinished: true;
92
- };
93
- };
94
- };
95
- configs: {
96
- 'legacy-recommended': {
97
- plugins: string[];
98
- rules: {};
99
- };
100
- 'legacy-all': {
101
- plugins: string[];
102
- rules: {};
103
- };
104
- recommended: {
105
- plugins: {
106
- readonly vitest: ESLint.Plugin;
107
- };
108
- rules: {
109
- readonly "vitest/expect-expect": "error";
110
- readonly "vitest/no-identical-title": "error";
111
- readonly "vitest/no-commented-out-tests": "error";
112
- readonly "vitest/valid-title": "error";
113
- readonly "vitest/valid-expect": "error";
114
- readonly "vitest/valid-describe-callback": "error";
115
- readonly "vitest/require-local-test-context-for-concurrent-snapshots": "error";
116
- readonly "vitest/no-import-node-test": "error";
117
- };
118
- };
119
- all: {
120
- plugins: {
121
- readonly vitest: ESLint.Plugin;
122
- };
123
- rules: {
124
- readonly "vitest/prefer-lowercase-title": "warn";
125
- readonly "vitest/max-nested-describe": "warn";
126
- readonly "vitest/no-focused-tests": "warn";
127
- readonly "vitest/no-conditional-tests": "warn";
128
- readonly "vitest/consistent-test-it": "warn";
129
- readonly "vitest/no-hooks": "warn";
130
- readonly "vitest/no-restricted-vi-methods": "warn";
131
- readonly "vitest/consistent-test-filename": "warn";
132
- readonly "vitest/max-expects": "warn";
133
- readonly "vitest/no-alias-methods": "warn";
134
- readonly "vitest/no-conditional-expect": "warn";
135
- readonly "vitest/no-conditional-in-test": "warn";
136
- readonly "vitest/no-disabled-tests": "warn";
137
- readonly "vitest/no-done-callback": "warn";
138
- readonly "vitest/no-duplicate-hooks": "warn";
139
- readonly "vitest/no-large-snapshots": "warn";
140
- readonly "vitest/no-interpolation-in-snapshots": "warn";
141
- readonly "vitest/no-mocks-import": "warn";
142
- readonly "vitest/no-restricted-matchers": "warn";
143
- readonly "vitest/no-standalone-expect": "warn";
144
- readonly "vitest/no-test-prefixes": "warn";
145
- readonly "vitest/no-test-return-statement": "warn";
146
- readonly "vitest/prefer-called-with": "warn";
147
- readonly "vitest/prefer-to-be-falsy": "warn";
148
- readonly "vitest/prefer-to-be-object": "warn";
149
- readonly "vitest/prefer-to-be-truthy": "warn";
150
- readonly "vitest/prefer-to-have-length": "warn";
151
- readonly "vitest/prefer-equality-matcher": "warn";
152
- readonly "vitest/prefer-strict-equal": "warn";
153
- readonly "vitest/prefer-expect-resolves": "warn";
154
- readonly "vitest/prefer-each": "warn";
155
- readonly "vitest/prefer-hooks-on-top": "warn";
156
- readonly "vitest/prefer-hooks-in-order": "warn";
157
- readonly "vitest/prefer-mock-promise-shorthand": "warn";
158
- readonly "vitest/prefer-vi-mocked": "warn";
159
- readonly "vitest/prefer-snapshot-hint": "warn";
160
- readonly "vitest/require-top-level-describe": "warn";
161
- readonly "vitest/require-to-throw-message": "warn";
162
- readonly "vitest/require-hook": "warn";
163
- readonly "vitest/prefer-todo": "warn";
164
- readonly "vitest/prefer-spy-on": "warn";
165
- readonly "vitest/prefer-comparison-matcher": "warn";
166
- readonly "vitest/prefer-to-contain": "warn";
167
- readonly "vitest/prefer-expect-assertions": "warn";
168
- readonly "vitest/prefer-to-be": "warn";
169
- readonly "vitest/padding-around-after-all-blocks": "warn";
170
- readonly "vitest/padding-around-after-each-blocks": "warn";
171
- readonly "vitest/padding-around-all": "warn";
172
- readonly "vitest/padding-around-before-all-blocks": "warn";
173
- readonly "vitest/padding-around-before-each-blocks": "warn";
174
- readonly "vitest/padding-around-describe-blocks": "warn";
175
- readonly "vitest/padding-around-expect-groups": "warn";
176
- readonly "vitest/padding-around-test-blocks": "warn";
177
- readonly "vitest/valid-expect-in-promise": "warn";
178
- readonly "vitest/expect-expect": "warn";
179
- readonly "vitest/no-identical-title": "warn";
180
- readonly "vitest/no-commented-out-tests": "warn";
181
- readonly "vitest/valid-title": "warn";
182
- readonly "vitest/valid-expect": "warn";
183
- readonly "vitest/valid-describe-callback": "warn";
184
- readonly "vitest/require-local-test-context-for-concurrent-snapshots": "warn";
185
- readonly "vitest/no-import-node-test": "warn";
186
- };
187
- };
188
- env: {
189
- languageOptions: {
190
- globals: {
191
- suite: "writable";
192
- test: "writable";
193
- describe: "writable";
194
- it: "writable";
195
- expectTypeOf: "writable";
196
- assertType: "writable";
197
- expect: "writable";
198
- assert: "writable";
199
- vitest: "writable";
200
- vi: "writable";
201
- beforeAll: "writable";
202
- afterAll: "writable";
203
- beforeEach: "writable";
204
- afterEach: "writable";
205
- onTestFailed: "writable";
206
- onTestFinished: "writable";
207
- };
208
- };
209
- };
210
- };
211
- };
212
-
213
- export { plugin as default };