Skip to content

Commit

Permalink
test: Use node.js test runner
Browse files Browse the repository at this point in the history
  • Loading branch information
avaly committed Nov 11, 2024
1 parent d53721a commit 5fb117f
Show file tree
Hide file tree
Showing 19 changed files with 1,351 additions and 2,425 deletions.
2 changes: 0 additions & 2 deletions .npmrc
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,3 @@ save-prefix=""
# These next two lines are the default in pnpm
public-hoist-pattern[]="*eslint*"
public-hoist-pattern[]="*prettier*"
# This is installed by jest
public-hoist-pattern[]="@jest/globals"
4 changes: 2 additions & 2 deletions eslint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -176,10 +176,9 @@ export default typescriptEslint.config(
{
files: ['**/*.js', '**/*.mjs', '**/*.ts'],
languageOptions: {
ecmaVersion: 2022,
ecmaVersion: 2024,
globals: {
...globals.node,
...globals.jest,
},
sourceType: 'module',
},
Expand All @@ -193,6 +192,7 @@ export default typescriptEslint.config(
{
files: ['**/__tests__/*.test.ts'],
rules: {
'@typescript-eslint/no-floating-promises': 'off',
'@typescript-eslint/no-unused-expressions': 'off',
'@typescript-eslint/unbound-method': 'off',
'no-unused-expressions': 'off',
Expand Down
12 changes: 6 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,10 @@
"pretty": "prettier '**/*.{js,md,ts}' --write",
"pretty:ci": "prettier '**/*.{js,md,ts}' --check",
"release": "standard-version --infile docs/CHANGELOG.md",
"test": "jest",
"test": "node --experimental-test-module-mocks --import tsx --test **/__tests__/*.test.ts",
"test:build": "./tests/run.sh",
"test:types": "tsc",
"watch": "jest --watchAll",
"watch": "node --experimental-test-module-mocks --import tsx --watch --test **/__tests__/*.test.ts",
"watch:types": "tsc --watch"
},
"devDependencies": {
Expand All @@ -64,7 +64,7 @@
"@commitlint/config-conventional": "19.5.0",
"@eslint/eslintrc": "3.1.0",
"@eslint/js": "9.13.0",
"@types/node": "20.16.13",
"@types/node": "22.9.0",
"arg": "5.0.2",
"docsify-cli": "4.4.4",
"eslint": "9.13.0",
Expand All @@ -73,9 +73,8 @@
"eslint-plugin-import": "2.31.0",
"eslint-plugin-prettier": "5.2.1",
"eslint-plugin-promise": "7.1.0",
"globals": "15.9.0",
"globals": "15.12.0",
"husky": "9.1.4",
"jest": "29.7.0",
"jsdoc-api": "9.3.1",
"jsdoc-parse": "6.2.1",
"lint-staged": "15.2.9",
Expand All @@ -87,6 +86,7 @@
"standard-version": "9.5.0",
"ts-expect": "1.3.0",
"ts-node": "10.9.2",
"tsx": "4.19.2",
"typescript": "5.6.2",
"typescript-eslint": "8.11.0"
},
Expand Down Expand Up @@ -123,7 +123,7 @@
"trailingComma": "es5"
},
"volta": {
"node": "20.18.0",
"node": "22.11.0",
"pnpm": "9.12.2"
},
"packageManager": "[email protected]"
Expand Down
Loading

0 comments on commit 5fb117f

Please sign in to comment.