@modern-js/plugin-testing 2.67.11 → 2.68.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cjs/cli/index.js
CHANGED
@@ -85,7 +85,7 @@ const testingPlugin = () => {
|
|
85
85
|
const appContext = api.useAppContext();
|
86
86
|
testingExportsUtils = (0, import_utils.createRuntimeExportsUtils)(appContext.internalDirectory, "testing");
|
87
87
|
return {
|
88
|
-
|
88
|
+
resolve: {
|
89
89
|
alias: {
|
90
90
|
// The module-tools alias configuration is different and more specific than app-tools.
|
91
91
|
// So for the time being, the @ alias is configured here.
|
@@ -101,13 +101,14 @@ const testingPlugin = () => {
|
|
101
101
|
testingExportsUtils.addExport(`export * from '${testingPath}'`);
|
102
102
|
},
|
103
103
|
jestConfig: async (utils, next) => {
|
104
|
+
var _userConfig_resolve;
|
104
105
|
const appContext = api.useAppContext();
|
105
106
|
const userConfig = api.useResolvedConfigContext();
|
106
107
|
const apiOnly = await (0, import_utils.isApiOnly)(appContext.appDirectory);
|
107
108
|
if (apiOnly) {
|
108
109
|
return next(utils);
|
109
110
|
}
|
110
|
-
const alias = (0, import_utils.mergeAlias)(userConfig.
|
111
|
+
const alias = (0, import_utils.mergeAlias)(((_userConfig_resolve = userConfig.resolve) === null || _userConfig_resolve === void 0 ? void 0 : _userConfig_resolve.alias) || {});
|
111
112
|
if (testingExportsUtils) {
|
112
113
|
alias["@modern-js/runtime/testing"] = [
|
113
114
|
testingExportsUtils.getPath()
|
package/dist/esm/cli/index.js
CHANGED
@@ -66,7 +66,7 @@ var testingPlugin = function() {
|
|
66
66
|
var appContext = api.useAppContext();
|
67
67
|
testingExportsUtils = createRuntimeExportsUtils(appContext.internalDirectory, "testing");
|
68
68
|
return {
|
69
|
-
|
69
|
+
resolve: {
|
70
70
|
alias: {
|
71
71
|
// The module-tools alias configuration is different and more specific than app-tools.
|
72
72
|
// So for the time being, the @ alias is configured here.
|
@@ -83,7 +83,7 @@ var testingPlugin = function() {
|
|
83
83
|
},
|
84
84
|
jestConfig: function() {
|
85
85
|
var _ref = _async_to_generator(function(utils, next) {
|
86
|
-
var appContext, userConfig, apiOnly, alias;
|
86
|
+
var _userConfig_resolve, appContext, userConfig, apiOnly, alias;
|
87
87
|
return _ts_generator(this, function(_state) {
|
88
88
|
switch (_state.label) {
|
89
89
|
case 0:
|
@@ -101,7 +101,7 @@ var testingPlugin = function() {
|
|
101
101
|
next(utils)
|
102
102
|
];
|
103
103
|
}
|
104
|
-
alias = mergeAlias(userConfig.
|
104
|
+
alias = mergeAlias(((_userConfig_resolve = userConfig.resolve) === null || _userConfig_resolve === void 0 ? void 0 : _userConfig_resolve.alias) || {});
|
105
105
|
if (testingExportsUtils) {
|
106
106
|
alias["@modern-js/runtime/testing"] = [
|
107
107
|
testingExportsUtils.getPath()
|
@@ -49,7 +49,7 @@ const testingPlugin = () => {
|
|
49
49
|
const appContext = api.useAppContext();
|
50
50
|
testingExportsUtils = createRuntimeExportsUtils(appContext.internalDirectory, "testing");
|
51
51
|
return {
|
52
|
-
|
52
|
+
resolve: {
|
53
53
|
alias: {
|
54
54
|
// The module-tools alias configuration is different and more specific than app-tools.
|
55
55
|
// So for the time being, the @ alias is configured here.
|
@@ -65,13 +65,14 @@ const testingPlugin = () => {
|
|
65
65
|
testingExportsUtils.addExport(`export * from '${testingPath}'`);
|
66
66
|
},
|
67
67
|
jestConfig: async (utils, next) => {
|
68
|
+
var _userConfig_resolve;
|
68
69
|
const appContext = api.useAppContext();
|
69
70
|
const userConfig = api.useResolvedConfigContext();
|
70
71
|
const apiOnly = await isApiOnly(appContext.appDirectory);
|
71
72
|
if (apiOnly) {
|
72
73
|
return next(utils);
|
73
74
|
}
|
74
|
-
const alias = mergeAlias(userConfig.
|
75
|
+
const alias = mergeAlias(((_userConfig_resolve = userConfig.resolve) === null || _userConfig_resolve === void 0 ? void 0 : _userConfig_resolve.alias) || {});
|
75
76
|
if (testingExportsUtils) {
|
76
77
|
alias["@modern-js/runtime/testing"] = [
|
77
78
|
testingExportsUtils.getPath()
|
package/package.json
CHANGED
@@ -15,7 +15,7 @@
|
|
15
15
|
"modern",
|
16
16
|
"modern.js"
|
17
17
|
],
|
18
|
-
"version": "2.
|
18
|
+
"version": "2.68.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",
|
@@ -130,19 +130,19 @@
|
|
130
130
|
"supertest": "^6.1.6",
|
131
131
|
"ts-jest": "^29.1.0",
|
132
132
|
"yargs": "^17.0.1",
|
133
|
-
"@modern-js/babel-compiler": "2.
|
134
|
-
"@modern-js/babel-preset": "2.
|
135
|
-
"@modern-js/bff-core": "2.
|
136
|
-
"@modern-js/plugin": "2.
|
137
|
-
"@modern-js/prod-server": "2.
|
138
|
-
"@modern-js/server-core": "2.
|
139
|
-
"@modern-js/types": "2.
|
140
|
-
"@modern-js/utils": "2.
|
133
|
+
"@modern-js/babel-compiler": "2.68.0",
|
134
|
+
"@modern-js/babel-preset": "2.68.0",
|
135
|
+
"@modern-js/bff-core": "2.68.0",
|
136
|
+
"@modern-js/plugin": "2.68.0",
|
137
|
+
"@modern-js/prod-server": "2.68.0",
|
138
|
+
"@modern-js/server-core": "2.68.0",
|
139
|
+
"@modern-js/types": "2.68.0",
|
140
|
+
"@modern-js/utils": "2.68.0"
|
141
141
|
},
|
142
142
|
"peerDependencies": {
|
143
143
|
"react": ">=17",
|
144
144
|
"react-dom": ">=17",
|
145
|
-
"@modern-js/runtime": "^2.
|
145
|
+
"@modern-js/runtime": "^2.68.0"
|
146
146
|
},
|
147
147
|
"peerDependenciesMeta": {
|
148
148
|
"@modern-js/runtime": {
|
@@ -159,8 +159,8 @@
|
|
159
159
|
"react": "^18.3.1",
|
160
160
|
"react-dom": "^18.3.1",
|
161
161
|
"typescript": "^5",
|
162
|
-
"@modern-js/core": "2.
|
163
|
-
"@modern-js/runtime": "2.
|
162
|
+
"@modern-js/core": "2.68.0",
|
163
|
+
"@modern-js/runtime": "2.68.0",
|
164
164
|
"@scripts/build": "2.66.0",
|
165
165
|
"@scripts/jest-config": "2.66.0"
|
166
166
|
},
|