@mui/internal-code-infra 0.0.4-canary.106 → 0.0.4-canary.108

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.
@@ -3,12 +3,6 @@
3
3
  */
4
4
  export declare const baseSpecRules: import('eslint').Linter.Config;
5
5
  /**
6
- * @param {Object} [options]
7
- * @param {boolean} [options.useMocha]
8
- * @param {boolean} [options.useVitest]
9
6
  * @returns {import('eslint').Linter.Config[]}
10
7
  */
11
- export declare function createTestConfig(options?: {
12
- useMocha?: boolean;
13
- useVitest?: boolean;
14
- }): import('eslint').Linter.Config[];
8
+ export declare function createTestConfig(): import('eslint').Linter.Config[];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mui/internal-code-infra",
3
- "version": "0.0.4-canary.106",
3
+ "version": "0.0.4-canary.108",
4
4
  "author": "MUI Team",
5
5
  "description": "Infra scripts and configs to be used across MUI repos.",
6
6
  "license": "MIT",
@@ -53,7 +53,7 @@
53
53
  "code-infra": "./bin/code-infra.mjs"
54
54
  },
55
55
  "dependencies": {
56
- "@argos-ci/core": "6.7.0",
56
+ "@argos-ci/core": "6.8.1",
57
57
  "@babel/cli": "^7.29.7",
58
58
  "@babel/core": "^7.29.7",
59
59
  "@babel/plugin-syntax-jsx": "^7.29.7",
@@ -65,18 +65,18 @@
65
65
  "@eslint/compat": "^2.1.0",
66
66
  "@eslint/js": "^10.0.1",
67
67
  "@eslint/json": "^2.0.1",
68
- "@inquirer/confirm": "^6.1.1",
69
- "@inquirer/select": "^5.2.1",
68
+ "@inquirer/confirm": "^6.2.0",
69
+ "@inquirer/select": "^5.2.2",
70
70
  "@napi-rs/keyring": "^1.3.0",
71
71
  "@octokit/auth-action": "^6.0.2",
72
- "@octokit/oauth-methods": "^6.0.2",
72
+ "@octokit/oauth-methods": "^6.0.4",
73
73
  "@octokit/rest": "^22.0.1",
74
- "@pnpm/config.version-policy": "^1100.1.9",
74
+ "@pnpm/config.version-policy": "^1100.2.0",
75
75
  "@pnpm/find-workspace-dir": "^1000.1.5",
76
76
  "@pnpm/parse-wanted-dependency": "^1001.0.0",
77
- "@typescript-eslint/types": "^8.65.0",
78
- "@typescript-eslint/utils": "^8.65.0",
79
- "@vitest/eslint-plugin": "^1.6.24",
77
+ "@typescript-eslint/types": "^8.67.0",
78
+ "@typescript-eslint/utils": "^8.67.0",
79
+ "@vitest/eslint-plugin": "^1.6.27",
80
80
  "babel-plugin-optimize-clsx": "^2.6.2",
81
81
  "babel-plugin-react-compiler": "^1.0.0",
82
82
  "babel-plugin-transform-import-meta": "^2.3.3",
@@ -85,9 +85,9 @@
85
85
  "babel-plugin-transform-remove-imports": "^1.8.1",
86
86
  "chalk": "^6.0.0",
87
87
  "clipboardy": "^5.3.2",
88
- "content-type": "^2.0.0",
88
+ "content-type": "^2.1.0",
89
89
  "env-ci": "^11.2.0",
90
- "es-toolkit": "^1.49.0",
90
+ "es-toolkit": "^1.51.0",
91
91
  "eslint-config-prettier": "^10.1.8",
92
92
  "eslint-import-resolver-typescript": "^4.4.5",
93
93
  "eslint-module-utils": "^2.14.0",
@@ -95,19 +95,18 @@
95
95
  "eslint-plugin-import": "^2.32.0",
96
96
  "eslint-plugin-jsx-a11y": "^6.10.2",
97
97
  "eslint-plugin-mdx": "^3.8.1",
98
- "eslint-plugin-mocha": "^11.3.0",
99
98
  "eslint-plugin-react": "^7.37.5",
100
99
  "eslint-plugin-react-compiler": "^19.1.0-rc.2",
101
100
  "eslint-plugin-react-hooks": "^7.1.1",
102
101
  "eslint-plugin-testing-library": "^7.16.2",
103
- "execa": "^9.6.1",
102
+ "execa": "^10.0.1",
104
103
  "git-url-parse": "^16.1.0",
105
- "globals": "^17.7.0",
106
- "globby": "^16.2.2",
107
- "html-validate": "^11.5.6",
108
- "minimatch": "^10.2.5",
109
- "node-html-parser": "^9.0.0",
110
- "open": "^11.0.0",
104
+ "globals": "^17.11.0",
105
+ "globby": "^16.2.4",
106
+ "html-validate": "^11.9.0",
107
+ "minimatch": "^10.2.6",
108
+ "node-html-parser": "^9.0.1",
109
+ "open": "^11.0.1",
111
110
  "postcss-styled-syntax": "^0.7.2",
112
111
  "regexp.escape": "^2.0.1",
113
112
  "rehype-slug": "^6.0.0",
@@ -131,15 +130,15 @@
131
130
  "resolve-pkg-maps": "^1.0.0",
132
131
  "semver": "^7.8.5",
133
132
  "stylelint-config-standard": "^40.0.0",
134
- "typescript-eslint": "^8.65.0",
133
+ "typescript-eslint": "^8.67.0",
135
134
  "unified": "^11.0.5",
136
135
  "unified-lint-rule": "^3.0.1",
137
136
  "unist-util-visit": "^5.1.0",
138
137
  "yaml": "^2.9.0",
139
- "yargs": "^18.0.0",
140
- "@mui/internal-babel-plugin-minify-errors": "2.0.8-canary.30",
138
+ "yargs": "^18.1.0",
141
139
  "@mui/internal-babel-plugin-display-name": "1.0.4-canary.23",
142
- "@mui/internal-babel-plugin-resolve-imports": "2.0.7-canary.42"
140
+ "@mui/internal-babel-plugin-resolve-imports": "2.0.7-canary.42",
141
+ "@mui/internal-babel-plugin-minify-errors": "2.0.8-canary.30"
143
142
  },
144
143
  "peerDependencies": {
145
144
  "@next/eslint-plugin-next": "*",
@@ -167,15 +166,15 @@
167
166
  "@types/mdast": "4.0.4",
168
167
  "@types/regexp.escape": "2.0.0",
169
168
  "@types/yargs": "17.0.35",
170
- "@typescript-eslint/parser": "8.65.0",
171
- "@typescript-eslint/rule-tester": "8.65.0",
172
- "eslint": "10.8.0",
169
+ "@typescript-eslint/parser": "8.67.0",
170
+ "@typescript-eslint/rule-tester": "8.67.0",
171
+ "eslint": "10.8.1",
173
172
  "get-port": "7.2.0",
174
- "prettier": "3.9.5",
173
+ "prettier": "3.9.6",
175
174
  "remark": "15.0.1",
176
175
  "remark-mdx": "3.1.1",
177
176
  "serve": "14.2.6",
178
- "typescript-eslint": "8.65.0"
177
+ "typescript-eslint": "8.67.0"
179
178
  },
180
179
  "files": [
181
180
  "bin",
@@ -190,7 +189,7 @@
190
189
  "publishConfig": {
191
190
  "access": "public"
192
191
  },
193
- "gitSha": "7d0cdc53fd9c01aaf49798a4e8e30e6ffea53022",
192
+ "gitSha": "621d2be80da48abdbfaeb85f498580416be78c9a",
194
193
  "scripts": {
195
194
  "build": "tsgo -p tsconfig.build.json",
196
195
  "typescript": "tsgo -noEmit",
@@ -1,5 +1,5 @@
1
1
  /* eslint-disable no-console */
2
- import { execaCommand } from 'execa';
2
+ import { execa, parseCommandString } from 'execa';
3
3
  import timers from 'node:timers/promises';
4
4
  import * as fs from 'node:fs/promises';
5
5
  import * as path from 'node:path';
@@ -626,7 +626,7 @@ export async function crawl(rawOptions) {
626
626
  if (options.startCommand) {
627
627
  console.log(chalk.blue(`Starting server with "${options.startCommand}"...`));
628
628
  controller = new AbortController();
629
- const appProcess = execaCommand(options.startCommand, {
629
+ const appProcess = execa({
630
630
  stdout: 'pipe',
631
631
  stderr: 'pipe',
632
632
  cancelSignal: controller.signal,
@@ -634,7 +634,7 @@ export async function crawl(rawOptions) {
634
634
  FORCE_COLOR: '1',
635
635
  ...process.env,
636
636
  },
637
- });
637
+ })`${parseCommandString(options.startCommand)}`;
638
638
 
639
639
  // Prefix server logs
640
640
  const serverPrefix = chalk.gray('server: ');
@@ -1,8 +1,6 @@
1
- import mochaPlugin from 'eslint-plugin-mocha';
2
1
  import vitestPlugin from '@vitest/eslint-plugin';
3
2
  import testingLibrary from 'eslint-plugin-testing-library';
4
3
  import { defineConfig } from 'eslint/config';
5
- import globals from 'globals';
6
4
  import * as tseslint from 'typescript-eslint';
7
5
  import { EXTENSION_TS } from './extensions.mjs';
8
6
 
@@ -44,16 +42,11 @@ export const baseSpecRules = {
44
42
  };
45
43
 
46
44
  /**
47
- * @param {Object} [options]
48
- * @param {boolean} [options.useMocha]
49
- * @param {boolean} [options.useVitest]
50
45
  * @returns {import('eslint').Linter.Config[]}
51
46
  */
52
- export function createTestConfig(options = {}) {
53
- const { useMocha = true, useVitest = false } = options;
47
+ export function createTestConfig() {
54
48
  return defineConfig(
55
- useMocha ? mochaPlugin.configs.recommended : {},
56
- useVitest ? vitestPlugin.configs.recommended : {},
49
+ vitestPlugin.configs.recommended,
57
50
  testingLibrary.configs['flat/dom'],
58
51
  testingLibrary.configs['flat/react'],
59
52
  {
@@ -63,7 +56,6 @@ export function createTestConfig(options = {}) {
63
56
  parserOptions: {
64
57
  ecmaVersion: 7,
65
58
  },
66
- globals: globals.mocha,
67
59
  },
68
60
  rules: {
69
61
  'compat/compat': 'off',
@@ -99,27 +91,7 @@ export function createTestConfig(options = {}) {
99
91
  'testing-library/no-node-access': 'off',
100
92
  '@typescript-eslint/no-non-null-asserted-optional-chain': 'off',
101
93
  // end migration
102
- ...(useMocha
103
- ? {
104
- 'mocha/consistent-spacing-between-blocks': 'off',
105
-
106
- // upgraded level from recommended
107
- 'mocha/no-pending-tests': 'error',
108
-
109
- // no rationale provided in /recommended
110
- 'mocha/no-mocha-arrows': 'off',
111
- // definitely a useful rule but too many false positives
112
- // due to `describeConformance`
113
- // "If you're using dynamically generated tests, you should disable this rule.""
114
- 'mocha/no-setup-in-describe': 'off',
115
- // `beforeEach` for a single case is optimized for change
116
- // when we add a test we don't have to refactor the existing
117
- // test to `beforeEach`.
118
- // `beforeEach`+`afterEach` also means that the `beforeEach`
119
- // is cleaned up in `afterEach` if the test causes a crash
120
- 'mocha/no-hooks-for-single-case': 'off',
121
- }
122
- : {}),
94
+ 'vitest/prefer-importing-vitest-globals': 'error',
123
95
  },
124
96
  },
125
97
  );