mirror of
https://github.com/iconify/iconify.git
synced 2024-12-22 01:38:56 +00:00
Remove jest from core package, use vitest only
This commit is contained in:
parent
6a034033cb
commit
de31dd36ba
@ -1,11 +0,0 @@
|
|||||||
const { buildConfiguration } = require('./jest.shared.config.cjs');
|
|
||||||
|
|
||||||
/** @type {import('ts-jest/dist/types').InitialOptionsTsJest} */
|
|
||||||
module.exports = buildConfiguration({
|
|
||||||
moduleFileExtensions: ['ts', 'cjs', 'js'],
|
|
||||||
globals: {
|
|
||||||
'ts-jest': {
|
|
||||||
useESM: false,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
});
|
|
@ -1,10 +0,0 @@
|
|||||||
import pkg from './jest.shared.config.cjs';
|
|
||||||
|
|
||||||
export default pkg.buildConfiguration({
|
|
||||||
moduleFileExtensions: ['ts', 'mjs', 'js'],
|
|
||||||
globals: {
|
|
||||||
'ts-jest': {
|
|
||||||
useESM: true,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
})
|
|
@ -1,25 +0,0 @@
|
|||||||
/**
|
|
||||||
* Jest shared configuration: see https://jestjs.io/docs/ecmascript-modules.
|
|
||||||
*
|
|
||||||
* @param {import('ts-jest/dist/types').InitialOptionsTsJest} configuration
|
|
||||||
* @return {import('ts-jest/dist/types').InitialOptionsTsJest}
|
|
||||||
*/
|
|
||||||
function buildConfiguration(configuration) {
|
|
||||||
return Object.assign(
|
|
||||||
{},
|
|
||||||
{
|
|
||||||
verbose: true,
|
|
||||||
testEnvironment: 'node',
|
|
||||||
moduleDirectories: ['node_modules', 'src'],
|
|
||||||
extensionsToTreatAsEsm: ['.ts'],
|
|
||||||
transform: {
|
|
||||||
'^.+\\.ts$': 'ts-jest',
|
|
||||||
},
|
|
||||||
testMatch: ['**/tests/**/*-test.ts'],
|
|
||||||
},
|
|
||||||
configuration
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
exports.buildConfiguration = buildConfiguration;
|
|
||||||
module.exports = { buildConfiguration };
|
|
@ -17,10 +17,7 @@
|
|||||||
"lint": "eslint --fix src/**/*.ts",
|
"lint": "eslint --fix src/**/*.ts",
|
||||||
"prebuild": "pnpm run lint && pnpm run clean",
|
"prebuild": "pnpm run lint && pnpm run clean",
|
||||||
"build": "unbuild",
|
"build": "unbuild",
|
||||||
"test:jest-cjs": "jest --clearCache --config=jest.config.cjs && jest --runInBand --config=jest.config.cjs",
|
"test": "vitest"
|
||||||
"test:jest-esm": "cross-env NODE_OPTIONS=--experimental-vm-modules jest --clearCache --config=jest.config.mjs && cross-env NODE_OPTIONS=--experimental-vm-modules jest --runInBand --config=jest.config.mjs",
|
|
||||||
"test": "pnpm run test:jest-cjs && pnpm run test:jest-esm",
|
|
||||||
"vitest": "vitest --config vitest.config.mjs"
|
|
||||||
},
|
},
|
||||||
"sideEffects": false,
|
"sideEffects": false,
|
||||||
"exports": {
|
"exports": {
|
||||||
@ -139,15 +136,11 @@
|
|||||||
"@types/jest": "^27.5.2",
|
"@types/jest": "^27.5.2",
|
||||||
"@types/node": "^17.0.45",
|
"@types/node": "^17.0.45",
|
||||||
"@typescript-eslint/eslint-plugin": "^5.28.0",
|
"@typescript-eslint/eslint-plugin": "^5.28.0",
|
||||||
"cross-env": "^7.0.3",
|
|
||||||
"cross-fetch": "^3.1.5",
|
"cross-fetch": "^3.1.5",
|
||||||
"eslint": "^8.18.0",
|
"eslint": "^8.18.0",
|
||||||
"eslint-config-prettier": "^8.5.0",
|
"eslint-config-prettier": "^8.5.0",
|
||||||
"eslint-plugin-prettier": "^4.0.0",
|
"eslint-plugin-prettier": "^4.0.0",
|
||||||
"jest": "28.0.0-alpha.11",
|
|
||||||
"rimraf": "^3.0.2",
|
"rimraf": "^3.0.2",
|
||||||
"ts-jest": "28.0.0-next.3",
|
|
||||||
"ts-node": "^10.8.1",
|
|
||||||
"unbuild": "^0.7.4",
|
"unbuild": "^0.7.4",
|
||||||
"vitest": "^0.7.13"
|
"vitest": "^0.7.13"
|
||||||
}
|
}
|
||||||
|
@ -226,7 +226,6 @@
|
|||||||
"@types/debug": "^4.1.7",
|
"@types/debug": "^4.1.7",
|
||||||
"@types/jest": "^27.5.2",
|
"@types/jest": "^27.5.2",
|
||||||
"@typescript-eslint/eslint-plugin": "^5.28.0",
|
"@typescript-eslint/eslint-plugin": "^5.28.0",
|
||||||
"cross-env": "^7.0.3",
|
|
||||||
"eslint": "^8.18.0",
|
"eslint": "^8.18.0",
|
||||||
"eslint-config-prettier": "^8.5.0",
|
"eslint-config-prettier": "^8.5.0",
|
||||||
"eslint-plugin-prettier": "^4.0.0",
|
"eslint-plugin-prettier": "^4.0.0",
|
||||||
|
@ -13,7 +13,6 @@ importers:
|
|||||||
'@types/debug': ^4.1.7
|
'@types/debug': ^4.1.7
|
||||||
'@types/jest': ^27.5.2
|
'@types/jest': ^27.5.2
|
||||||
'@typescript-eslint/eslint-plugin': ^5.28.0
|
'@typescript-eslint/eslint-plugin': ^5.28.0
|
||||||
cross-env: ^7.0.3
|
|
||||||
debug: ^4.3.4
|
debug: ^4.3.4
|
||||||
eslint: ^8.18.0
|
eslint: ^8.18.0
|
||||||
eslint-config-prettier: ^8.5.0
|
eslint-config-prettier: ^8.5.0
|
||||||
@ -36,7 +35,6 @@ importers:
|
|||||||
'@types/debug': 4.1.7
|
'@types/debug': 4.1.7
|
||||||
'@types/jest': 27.5.2
|
'@types/jest': 27.5.2
|
||||||
'@typescript-eslint/eslint-plugin': 5.30.5_6zdoc3rn4mpiddqwhppni2mnnm
|
'@typescript-eslint/eslint-plugin': 5.30.5_6zdoc3rn4mpiddqwhppni2mnnm
|
||||||
cross-env: 7.0.3
|
|
||||||
eslint: 8.19.0
|
eslint: 8.19.0
|
||||||
eslint-config-prettier: 8.5.0_eslint@8.19.0
|
eslint-config-prettier: 8.5.0_eslint@8.19.0
|
||||||
eslint-plugin-prettier: 4.2.1_7uxdfn2xinezdgvmbammh6ev5i
|
eslint-plugin-prettier: 4.2.1_7uxdfn2xinezdgvmbammh6ev5i
|
||||||
@ -795,14 +793,6 @@ packages:
|
|||||||
safe-buffer: 5.1.2
|
safe-buffer: 5.1.2
|
||||||
dev: true
|
dev: true
|
||||||
|
|
||||||
/cross-env/7.0.3:
|
|
||||||
resolution: {integrity: sha512-+/HKd6EgcQCJGh2PSjZuUitQBQynKor4wrFbRg4DtAgS1aWO+gU52xpH7M9ScGgXSYmAVS9bIJ8EzuaGw0oNAw==}
|
|
||||||
engines: {node: '>=10.14', npm: '>=6', yarn: '>=1'}
|
|
||||||
hasBin: true
|
|
||||||
dependencies:
|
|
||||||
cross-spawn: 7.0.3
|
|
||||||
dev: true
|
|
||||||
|
|
||||||
/cross-spawn/7.0.3:
|
/cross-spawn/7.0.3:
|
||||||
resolution: {integrity: sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==}
|
resolution: {integrity: sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==}
|
||||||
engines: {node: '>= 8'}
|
engines: {node: '>= 8'}
|
||||||
|
Loading…
Reference in New Issue
Block a user