fix(ui): repair configuration for tests to start
parent
f1aa45ff71
commit
299764cbcd
|
@ -24,6 +24,7 @@
|
||||||
},
|
},
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
"@parcel/core": "^2.6.2",
|
||||||
"@parcel/transformer-sass": "^2.6.2",
|
"@parcel/transformer-sass": "^2.6.2",
|
||||||
"assert": "^2.0.0",
|
"assert": "^2.0.0",
|
||||||
"events": "^3.3.0",
|
"events": "^3.3.0",
|
||||||
|
|
|
@ -0,0 +1,24 @@
|
||||||
|
{
|
||||||
|
"plugins": [
|
||||||
|
"@babel/plugin-transform-runtime",
|
||||||
|
"@babel/plugin-proposal-class-properties",
|
||||||
|
"babel-plugin-lodash",
|
||||||
|
[
|
||||||
|
"babel-plugin-module-resolver",
|
||||||
|
{
|
||||||
|
"root": ["./src"],
|
||||||
|
"alias": {
|
||||||
|
"src": "./src",
|
||||||
|
"shared": "./src/shared",
|
||||||
|
"style": "./src/style",
|
||||||
|
"utils": "./src/utils"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
],
|
||||||
|
"presets": [
|
||||||
|
"@babel/preset-env",
|
||||||
|
"@babel/preset-typescript",
|
||||||
|
"@babel/preset-react"
|
||||||
|
]
|
||||||
|
}
|
|
@ -1,6 +1,12 @@
|
||||||
module.exports = {
|
module.exports = {
|
||||||
projects: [
|
projects: [
|
||||||
{
|
{
|
||||||
|
globals: {
|
||||||
|
'ts-jest': {
|
||||||
|
babelConfig: './.babelrc.jest',
|
||||||
|
tsconfig: './tsconfig.test.json',
|
||||||
|
},
|
||||||
|
},
|
||||||
displayName: 'test',
|
displayName: 'test',
|
||||||
testPathIgnorePatterns: [
|
testPathIgnorePatterns: [
|
||||||
'build',
|
'build',
|
||||||
|
@ -12,7 +18,7 @@ module.exports = {
|
||||||
setupFiles: ['<rootDir>/test/setup.js'],
|
setupFiles: ['<rootDir>/test/setup.js'],
|
||||||
transform: {
|
transform: {
|
||||||
'^.+\\.tsx?$': 'ts-jest',
|
'^.+\\.tsx?$': 'ts-jest',
|
||||||
'^.+\\.js$': 'babel-jest',
|
'^.+\\.js$': ['babel-jest', {configFile: './.babelrc.jest'}],
|
||||||
},
|
},
|
||||||
testRegex: '(/__tests__/.*|(\\.|/)(test|spec))\\.(jsx?|tsx?)$',
|
testRegex: '(/__tests__/.*|(\\.|/)(test|spec))\\.(jsx?|tsx?)$',
|
||||||
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'json', 'node'],
|
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'json', 'node'],
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
"name": "chronograf-ui",
|
"name": "chronograf-ui",
|
||||||
"version": "1.9.4",
|
"version": "1.9.4",
|
||||||
"private": true,
|
"private": true,
|
||||||
"license": "AGPL-3.0",
|
"license": "MIT",
|
||||||
"description": "",
|
"description": "",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
|
@ -53,6 +53,8 @@
|
||||||
"@babel/plugin-transform-runtime": "^7.1.0",
|
"@babel/plugin-transform-runtime": "^7.1.0",
|
||||||
"@babel/preset-env": "^7.13.9",
|
"@babel/preset-env": "^7.13.9",
|
||||||
"@babel/preset-react": "^7.0.0",
|
"@babel/preset-react": "^7.0.0",
|
||||||
|
"@babel/preset-typescript": "^7.18.6",
|
||||||
|
"@parcel/core": "^2.6.2",
|
||||||
"@parcel/config-default": "^2.6.2",
|
"@parcel/config-default": "^2.6.2",
|
||||||
"@parcel/transformer-typescript-tsc": "^2.6.2",
|
"@parcel/transformer-typescript-tsc": "^2.6.2",
|
||||||
"@types/chroma-js": "^1.3.4",
|
"@types/chroma-js": "^1.3.4",
|
||||||
|
@ -82,7 +84,7 @@
|
||||||
"autoprefixer": "^6.3.1",
|
"autoprefixer": "^6.3.1",
|
||||||
"babel-core": "^7.0.0-bridge",
|
"babel-core": "^7.0.0-bridge",
|
||||||
"babel-eslint": "^10.0.1",
|
"babel-eslint": "^10.0.1",
|
||||||
"babel-jest": "^23.6.0",
|
"babel-jest": "^26.6.3yarn",
|
||||||
"babel-plugin-lodash": "^3.3.4",
|
"babel-plugin-lodash": "^3.3.4",
|
||||||
"babel-plugin-module-resolver": "^4.1.0",
|
"babel-plugin-module-resolver": "^4.1.0",
|
||||||
"enzyme": "^3.6.0",
|
"enzyme": "^3.6.0",
|
||||||
|
@ -101,7 +103,7 @@
|
||||||
"http-proxy-middleware": "^0.18.0",
|
"http-proxy-middleware": "^0.18.0",
|
||||||
"identity-obj-proxy": "^3.0.0",
|
"identity-obj-proxy": "^3.0.0",
|
||||||
"jest": "^26.6.3",
|
"jest": "^26.6.3",
|
||||||
"jest-runner-eslint": "^0.10.0",
|
"jest-runner-eslint": "^1.0.1",
|
||||||
"node-sass": "^7.0.0",
|
"node-sass": "^7.0.0",
|
||||||
"parcel": "^2.0.0",
|
"parcel": "^2.0.0",
|
||||||
"prettier": "2.2.1",
|
"prettier": "2.2.1",
|
||||||
|
|
|
@ -0,0 +1,42 @@
|
||||||
|
{
|
||||||
|
"compilerOptions": {
|
||||||
|
"types": [
|
||||||
|
"node",
|
||||||
|
"lodash",
|
||||||
|
"enzyme",
|
||||||
|
"react",
|
||||||
|
"prop-types",
|
||||||
|
"jest",
|
||||||
|
"react-router",
|
||||||
|
"text-encoding",
|
||||||
|
"react-dnd",
|
||||||
|
"react-dnd-html5-backend"
|
||||||
|
],
|
||||||
|
"target": "es6",
|
||||||
|
"module": "es2020",
|
||||||
|
"moduleResolution": "node",
|
||||||
|
"lib": ["es6", "es2017", "dom", "webworker","ES2020.Promise"],
|
||||||
|
"skipLibCheck": true,
|
||||||
|
"isolatedModules": false,
|
||||||
|
"esModuleInterop": true,
|
||||||
|
"jsx": "react",
|
||||||
|
"experimentalDecorators": true,
|
||||||
|
"emitDecoratorMetadata": true,
|
||||||
|
"noImplicitAny": false,
|
||||||
|
"noImplicitUseStrict": false,
|
||||||
|
"noUnusedParameters": true,
|
||||||
|
"noUnusedLocals": true,
|
||||||
|
"removeComments": true,
|
||||||
|
"noLib": false,
|
||||||
|
"preserveConstEnums": true,
|
||||||
|
"suppressImplicitAnyIndexErrors": true,
|
||||||
|
"allowSyntheticDefaultImports": true,
|
||||||
|
"allowJs": true,
|
||||||
|
"checkJs": false,
|
||||||
|
"sourceMap": true,
|
||||||
|
"baseUrl": "./",
|
||||||
|
"rootDir": "./",
|
||||||
|
"outDir": "./build"
|
||||||
|
},
|
||||||
|
"exclude": ["assets", "build", "node_modules", "cypress"]
|
||||||
|
}
|
Loading…
Reference in New Issue