@modern-js/plugin-testing 2.20.0 → 2.21.0
Sign up to get free protection for your applications and to get access to all the features.
- package/CHANGELOG.md +33 -0
- package/dist/cjs/cli/bff/index.js +3 -0
- package/dist/esm/cli/bff/index.js +3 -0
- package/dist/esm-node/cli/bff/index.js +3 -0
- package/dist/types/base/config/index.d.ts +0 -1
- package/dist/types/base/config/patches/assetsModule.d.ts +0 -1
- package/dist/types/base/config/patches/filemock.d.ts +0 -1
- package/dist/types/base/config/patches/transformer.d.ts +0 -1
- package/dist/types/base/config/testConfigOperator.d.ts +0 -2
- package/dist/types/base/runJest.d.ts +0 -2
- package/dist/types/base/utils.d.ts +0 -1
- package/dist/types/cli/bff/index.d.ts +0 -2
- package/dist/types/cli/bff/mockAPI.d.ts +0 -1
- package/dist/types/cli/index.d.ts +0 -2
- package/dist/types/runtime-testing/app.d.ts +0 -3
- package/dist/types/runtime-testing/customRender.d.ts +0 -2
- package/package.json +21 -21
package/CHANGELOG.md
CHANGED
@@ -1,5 +1,38 @@
|
|
1
1
|
# @modern-js/plugin-testing
|
2
2
|
|
3
|
+
## 2.21.0
|
4
|
+
|
5
|
+
### Patch Changes
|
6
|
+
|
7
|
+
- 5424051: fix: the proxy should not recreated when exists
|
8
|
+
fix: proxy server 不应该被重新创建当存在时
|
9
|
+
- 26dcf3a: chore: bump typescript to v5 in devDependencies
|
10
|
+
|
11
|
+
chore: 升级 devDependencies 中的 typescript 版本到 v5
|
12
|
+
|
13
|
+
- 8b7c6d4: chore: update reduck
|
14
|
+
chore: 更新 reduck
|
15
|
+
- ad78387: chore(deps): bump babel-related dependencies to latest version
|
16
|
+
|
17
|
+
chore(deps): 升级 babel 相关依赖到最新版本
|
18
|
+
|
19
|
+
- Updated dependencies [cfc5bda]
|
20
|
+
- Updated dependencies [e81eeaf]
|
21
|
+
- Updated dependencies [26dcf3a]
|
22
|
+
- Updated dependencies [0a1aa3b]
|
23
|
+
- Updated dependencies [056627f]
|
24
|
+
- Updated dependencies [8b7c6d4]
|
25
|
+
- Updated dependencies [807f04a]
|
26
|
+
- Updated dependencies [0fc15ca]
|
27
|
+
- Updated dependencies [43b4e83]
|
28
|
+
- Updated dependencies [ad78387]
|
29
|
+
- @modern-js/prod-server@2.21.0
|
30
|
+
- @modern-js/runtime@2.21.0
|
31
|
+
- @modern-js/utils@2.21.0
|
32
|
+
- @modern-js/babel-compiler@2.21.0
|
33
|
+
- @modern-js/babel-preset-app@2.21.0
|
34
|
+
- @modern-js/plugin@2.21.0
|
35
|
+
|
3
36
|
## 2.20.0
|
4
37
|
|
5
38
|
### Patch Changes
|
@@ -5,7 +5,6 @@ import { TestConfigOperator } from './testConfigOperator';
|
|
5
5
|
/**
|
6
6
|
* Parse jest config
|
7
7
|
*/
|
8
|
-
|
9
8
|
declare const getJestUtils: (testConfig: TestConfig) => TestConfigOperator;
|
10
9
|
declare const patchConfig: (testOperator: TestConfigOperator) => Promise<JestConfigTypes.InitialOptions>;
|
11
10
|
export declare const DEFAULT_RESOLVER_PATH: string;
|
@@ -1,5 +1,4 @@
|
|
1
1
|
import { JestConfig, TestConfig } from '../types';
|
2
|
-
|
3
2
|
declare class TestConfigOperator {
|
4
3
|
private _testConfig;
|
5
4
|
private _jestConfig;
|
@@ -16,5 +15,4 @@ declare class TestConfigOperator {
|
|
16
15
|
}): void;
|
17
16
|
getFinalConfig(): any;
|
18
17
|
}
|
19
|
-
|
20
18
|
export { TestConfigOperator };
|
@@ -14,12 +14,10 @@ type Argv = Omit<Config.Argv, '_' | '$0'>;
|
|
14
14
|
/**
|
15
15
|
* Node API: execute jest
|
16
16
|
*/
|
17
|
-
|
18
17
|
export declare function runJest(config: Argv, pwd?: string): Promise<void>;
|
19
18
|
/**
|
20
19
|
* Node API: run test
|
21
20
|
*/
|
22
|
-
|
23
21
|
export declare function runTest(api: PluginAPI<{
|
24
22
|
hooks: Hooks;
|
25
23
|
userConfig: UserConfig;
|
@@ -6,7 +6,6 @@ interface TSConfig {
|
|
6
6
|
/**
|
7
7
|
* Read `compilerOptions` in the current pwd's tsconfig.json file
|
8
8
|
*/
|
9
|
-
|
10
9
|
export declare const readCompilerOptions: (pwd?: string, filename?: string) => TSConfig['compilerOptions'];
|
11
10
|
export declare const getModuleNameMapper: (alias: any) => any;
|
12
11
|
export {};
|
@@ -16,11 +16,9 @@ export declare const setJestConfigForBFF: ({
|
|
16
16
|
routes: any[];
|
17
17
|
utils: TestConfigOperator;
|
18
18
|
}) => Promise<void>;
|
19
|
-
|
20
19
|
declare const _default: () => CliPlugin<{
|
21
20
|
hooks: Hooks;
|
22
21
|
userConfig: UserConfig;
|
23
22
|
normalizedConfig: Required<UserConfig>;
|
24
23
|
}>;
|
25
|
-
|
26
24
|
export default _default;
|
@@ -3,11 +3,9 @@ import { TestConfigOperator } from '../base';
|
|
3
3
|
import type { Hooks } from '../base/hook';
|
4
4
|
import type { UserConfig } from '../base/config';
|
5
5
|
export declare const mergeUserJestConfig: (testUtils: TestConfigOperator) => void;
|
6
|
-
|
7
6
|
declare const _default: () => CliPlugin<{
|
8
7
|
hooks: Hooks;
|
9
8
|
userConfig: UserConfig;
|
10
9
|
normalizedConfig: Required<UserConfig>;
|
11
10
|
}>;
|
12
|
-
|
13
11
|
export default _default;
|
@@ -4,7 +4,6 @@ interface CreateAppProps {
|
|
4
4
|
entry?: string;
|
5
5
|
children?: React.ReactElement;
|
6
6
|
}
|
7
|
-
|
8
7
|
declare class ModernRuntime {
|
9
8
|
private options;
|
10
9
|
constructor(options: UserConfig<{
|
@@ -21,7 +20,5 @@ declare class ModernRuntime {
|
|
21
20
|
}>): void;
|
22
21
|
createApp(props?: CreateAppProps): React.ComponentType<any>;
|
23
22
|
}
|
24
|
-
|
25
23
|
declare const _default: ModernRuntime;
|
26
|
-
|
27
24
|
export default _default;
|
package/package.json
CHANGED
@@ -15,7 +15,7 @@
|
|
15
15
|
"modern",
|
16
16
|
"modern.js"
|
17
17
|
],
|
18
|
-
"version": "2.
|
18
|
+
"version": "2.21.0",
|
19
19
|
"jsnext:source": "./src/cli/index.ts",
|
20
20
|
"types": "./dist/types/cli/index.d.ts",
|
21
21
|
"main": "./dist/cjs/cli/index.js",
|
@@ -97,12 +97,12 @@
|
|
97
97
|
}
|
98
98
|
},
|
99
99
|
"dependencies": {
|
100
|
-
"@babel/core": "^7.
|
101
|
-
"@babel/preset-env": "^7.
|
102
|
-
"@modern-js-reduck/plugin-auto-actions": "^1.
|
103
|
-
"@modern-js-reduck/plugin-effects": "^1.
|
104
|
-
"@modern-js-reduck/plugin-immutable": "^1.
|
105
|
-
"@modern-js-reduck/store": "^1.
|
100
|
+
"@babel/core": "^7.21.8",
|
101
|
+
"@babel/preset-env": "^7.21.5",
|
102
|
+
"@modern-js-reduck/plugin-auto-actions": "^1.1.10",
|
103
|
+
"@modern-js-reduck/plugin-effects": "^1.1.10",
|
104
|
+
"@modern-js-reduck/plugin-immutable": "^1.1.10",
|
105
|
+
"@modern-js-reduck/store": "^1.1.10",
|
106
106
|
"@testing-library/jest-dom": "^5.14.1",
|
107
107
|
"@testing-library/react": "^13.4.0",
|
108
108
|
"@types/testing-library__jest-dom": "^5.14.3",
|
@@ -114,19 +114,19 @@
|
|
114
114
|
"jest": "^29.5.0",
|
115
115
|
"jest-environment-jsdom": "^29.5.0",
|
116
116
|
"@jest/types": "^29.5.0",
|
117
|
-
"ts-jest": "^29.0
|
117
|
+
"ts-jest": "^29.1.0",
|
118
118
|
"yargs": "^17.0.1",
|
119
119
|
"@swc/helpers": "0.5.1",
|
120
|
-
"@modern-js/babel-compiler": "2.
|
121
|
-
"@modern-js/utils": "2.
|
122
|
-
"@modern-js/babel-preset-app": "2.
|
123
|
-
"@modern-js/plugin": "2.
|
124
|
-
"@modern-js/prod-server": "2.
|
120
|
+
"@modern-js/babel-compiler": "2.21.0",
|
121
|
+
"@modern-js/utils": "2.21.0",
|
122
|
+
"@modern-js/babel-preset-app": "2.21.0",
|
123
|
+
"@modern-js/plugin": "2.21.0",
|
124
|
+
"@modern-js/prod-server": "2.21.0"
|
125
125
|
},
|
126
126
|
"peerDependencies": {
|
127
127
|
"react": ">=17",
|
128
128
|
"react-dom": ">=17",
|
129
|
-
"@modern-js/runtime": "^2.
|
129
|
+
"@modern-js/runtime": "^2.21.0"
|
130
130
|
},
|
131
131
|
"peerDependenciesMeta": {
|
132
132
|
"@modern-js/runtime": {
|
@@ -140,13 +140,13 @@
|
|
140
140
|
"@types/supertest": "^2.0.11",
|
141
141
|
"@types/node": "^14",
|
142
142
|
"@types/yargs": "^17.0.2",
|
143
|
-
"typescript": "^
|
144
|
-
"@modern-js/core": "2.
|
145
|
-
"@modern-js/types": "2.
|
146
|
-
"@modern-js/runtime": "2.
|
147
|
-
"@modern-js/bff-core": "2.
|
148
|
-
"@scripts/build": "2.
|
149
|
-
"@scripts/jest-config": "2.
|
143
|
+
"typescript": "^5",
|
144
|
+
"@modern-js/core": "2.21.0",
|
145
|
+
"@modern-js/types": "2.21.0",
|
146
|
+
"@modern-js/runtime": "2.21.0",
|
147
|
+
"@modern-js/bff-core": "2.21.0",
|
148
|
+
"@scripts/build": "2.21.0",
|
149
|
+
"@scripts/jest-config": "2.21.0"
|
150
150
|
},
|
151
151
|
"sideEffects": false,
|
152
152
|
"modernConfig": {},
|