chore(deps): update node.js to v22.15.0 (#15606)
* chore(deps): update node.js to v22.15.0 * chore: determine Jest args from Node.js version * fix * fix: `import.meta.dirname` is not supported in v20.10.0 --------- Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: zyoshoka <107108195+zyoshoka@users.noreply.github.com>
This commit is contained in:
parent
14d6734cb1
commit
c23f2ff900
|
@ -5,7 +5,7 @@
|
||||||
"workspaceFolder": "/workspace",
|
"workspaceFolder": "/workspace",
|
||||||
"features": {
|
"features": {
|
||||||
"ghcr.io/devcontainers/features/node:1": {
|
"ghcr.io/devcontainers/features/node:1": {
|
||||||
"version": "22.11.0"
|
"version": "22.15.0"
|
||||||
},
|
},
|
||||||
"ghcr.io/devcontainers-extra/features/pnpm:2": {
|
"ghcr.io/devcontainers-extra/features/pnpm:2": {
|
||||||
"version": "10.10.0"
|
"version": "10.10.0"
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
22.11.0
|
22.15.0
|
||||||
|
|
|
@ -1,5 +1,8 @@
|
||||||
## 2025.5.0
|
## 2025.5.0
|
||||||
|
|
||||||
|
### Note
|
||||||
|
- DockerのNode.jsが22.15.0に更新されました
|
||||||
|
|
||||||
### General
|
### General
|
||||||
-
|
-
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
# syntax = docker/dockerfile:1.4
|
# syntax = docker/dockerfile:1.4
|
||||||
|
|
||||||
ARG NODE_VERSION=22.11.0-bookworm
|
ARG NODE_VERSION=22.15.0-bookworm
|
||||||
|
|
||||||
# build assets & compile TypeScript
|
# build assets & compile TypeScript
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
import tsParser from '@typescript-eslint/parser';
|
import tsParser from '@typescript-eslint/parser';
|
||||||
|
import globals from 'globals';
|
||||||
import sharedConfig from '../shared/eslint.config.js';
|
import sharedConfig from '../shared/eslint.config.js';
|
||||||
|
|
||||||
export default [
|
export default [
|
||||||
|
@ -6,6 +7,13 @@ export default [
|
||||||
{
|
{
|
||||||
ignores: ['**/node_modules', 'built', '@types/**/*', 'migration'],
|
ignores: ['**/node_modules', 'built', '@types/**/*', 'migration'],
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
languageOptions: {
|
||||||
|
globals: {
|
||||||
|
...globals.node,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
{
|
{
|
||||||
files: ['**/*.ts', '**/*.tsx'],
|
files: ['**/*.ts', '**/*.tsx'],
|
||||||
languageOptions: {
|
languageOptions: {
|
||||||
|
|
|
@ -0,0 +1,20 @@
|
||||||
|
#!/usr/bin/env node
|
||||||
|
import child_process from 'node:child_process';
|
||||||
|
import path from 'node:path';
|
||||||
|
import url from 'node:url';
|
||||||
|
|
||||||
|
import semver from 'semver';
|
||||||
|
|
||||||
|
const __filename = url.fileURLToPath(import.meta.url);
|
||||||
|
const __dirname = path.dirname(__filename);
|
||||||
|
|
||||||
|
const args = [];
|
||||||
|
args.push(...[
|
||||||
|
...semver.satisfies(process.version, '^20.17.0 || ^22.0.0') ? ['--no-experimental-require-module'] : [],
|
||||||
|
'--experimental-vm-modules',
|
||||||
|
'--experimental-import-meta-resolve',
|
||||||
|
path.join(__dirname, 'node_modules/jest/bin/jest.js'),
|
||||||
|
...process.argv.slice(2),
|
||||||
|
]);
|
||||||
|
|
||||||
|
child_process.spawn(process.execPath, args, { stdio: 'inherit' });
|
|
@ -22,12 +22,12 @@
|
||||||
"typecheck": "tsc --noEmit && tsc -p test --noEmit && tsc -p test-federation --noEmit",
|
"typecheck": "tsc --noEmit && tsc -p test --noEmit && tsc -p test-federation --noEmit",
|
||||||
"eslint": "eslint --quiet \"{src,test-federation}/**/*.ts\"",
|
"eslint": "eslint --quiet \"{src,test-federation}/**/*.ts\"",
|
||||||
"lint": "pnpm typecheck && pnpm eslint",
|
"lint": "pnpm typecheck && pnpm eslint",
|
||||||
"jest": "cross-env NODE_ENV=test node --experimental-vm-modules --experimental-import-meta-resolve node_modules/jest/bin/jest.js --forceExit --config jest.config.unit.cjs",
|
"jest": "cross-env NODE_ENV=test node ./jest.js --forceExit --config jest.config.unit.cjs",
|
||||||
"jest:e2e": "cross-env NODE_ENV=test node --experimental-vm-modules --experimental-import-meta-resolve node_modules/jest/bin/jest.js --forceExit --config jest.config.e2e.cjs",
|
"jest:e2e": "cross-env NODE_ENV=test node ./jest.js --forceExit --config jest.config.e2e.cjs",
|
||||||
"jest:fed": "node --experimental-vm-modules --experimental-import-meta-resolve node_modules/jest/bin/jest.js --forceExit --config jest.config.fed.cjs",
|
"jest:fed": "node ./jest.js --forceExit --config jest.config.fed.cjs",
|
||||||
"jest-and-coverage": "cross-env NODE_ENV=test node --experimental-vm-modules --experimental-import-meta-resolve node_modules/jest/bin/jest.js --coverage --forceExit --config jest.config.unit.cjs",
|
"jest-and-coverage": "cross-env NODE_ENV=test node ./jest.js --coverage --forceExit --config jest.config.unit.cjs",
|
||||||
"jest-and-coverage:e2e": "cross-env NODE_ENV=test node --experimental-vm-modules --experimental-import-meta-resolve node_modules/jest/bin/jest.js --coverage --forceExit --config jest.config.e2e.cjs",
|
"jest-and-coverage:e2e": "cross-env NODE_ENV=test node ./jest.js --coverage --forceExit --config jest.config.e2e.cjs",
|
||||||
"jest-clear": "cross-env NODE_ENV=test node --experimental-vm-modules --experimental-import-meta-resolve node_modules/jest/bin/jest.js --clearCache",
|
"jest-clear": "cross-env NODE_ENV=test node ./jest.js --clearCache",
|
||||||
"test": "pnpm jest",
|
"test": "pnpm jest",
|
||||||
"test:e2e": "pnpm build && pnpm build:test && pnpm jest:e2e",
|
"test:e2e": "pnpm build && pnpm build:test && pnpm jest:e2e",
|
||||||
"test:fed": "pnpm jest:fed",
|
"test:fed": "pnpm jest:fed",
|
||||||
|
|
|
@ -50,6 +50,10 @@ services:
|
||||||
source: ../jest.config.fed.cjs
|
source: ../jest.config.fed.cjs
|
||||||
target: /misskey/packages/backend/jest.config.fed.cjs
|
target: /misskey/packages/backend/jest.config.fed.cjs
|
||||||
read_only: true
|
read_only: true
|
||||||
|
- type: bind
|
||||||
|
source: ../jest.js
|
||||||
|
target: /misskey/packages/backend/jest.js
|
||||||
|
read_only: true
|
||||||
- type: bind
|
- type: bind
|
||||||
source: ../../misskey-js/built
|
source: ../../misskey-js/built
|
||||||
target: /misskey/packages/misskey-js/built
|
target: /misskey/packages/misskey-js/built
|
||||||
|
|
Loading…
Reference in New Issue