@cypress/webpack-dev-server 3.10.0 → 3.11.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/devServer.js
CHANGED
|
@@ -50,7 +50,7 @@ function devServer(devServerConfig) {
|
|
|
50
50
|
if (!result.server.options.port) {
|
|
51
51
|
return reject(new Error(`Expected port ${result.server.options.port} to be a number`));
|
|
52
52
|
}
|
|
53
|
-
debug(
|
|
53
|
+
debug(`Component testing webpack server ${result.version} started on port %s`, result.server.options.port);
|
|
54
54
|
resolve({
|
|
55
55
|
port: result.server.options.port,
|
|
56
56
|
// Close is for unit testing only. We kill this child process which will handle the closing of the server
|
|
@@ -10,7 +10,7 @@ const OUTPUT_PATH = path_1.default.join(__dirname, 'dist');
|
|
|
10
10
|
const OsSeparatorRE = RegExp(`\\${path_1.default.sep}`, 'g');
|
|
11
11
|
const posixSeparator = '/';
|
|
12
12
|
function makeCypressWebpackConfig(config) {
|
|
13
|
-
const { devServerConfig: { cypressConfig: { port, projectRoot, devServerPublicPathRoute, supportFile, indexHtmlFile, isTextTerminal: isRunMode, }, specs: files, devServerEvents, framework, }, sourceWebpackModulesResult: { webpack: { module: webpack, majorVersion: webpackMajorVersion, }, htmlWebpackPlugin: { module: HtmlWebpackPlugin, majorVersion: htmlWebpackPluginVersion, importPath: htmlWebpackPluginImportPath, }, webpackDevServer: { majorVersion: webpackDevServerMajorVersion, }, }, } = config;
|
|
13
|
+
const { devServerConfig: { cypressConfig: { experimentalJustInTimeCompile, port, projectRoot, devServerPublicPathRoute, supportFile, indexHtmlFile, isTextTerminal: isRunMode, }, specs: files, devServerEvents, framework, }, sourceWebpackModulesResult: { webpack: { module: webpack, majorVersion: webpackMajorVersion, }, htmlWebpackPlugin: { module: HtmlWebpackPlugin, majorVersion: htmlWebpackPluginVersion, importPath: htmlWebpackPluginImportPath, }, webpackDevServer: { majorVersion: webpackDevServerMajorVersion, }, }, } = config;
|
|
14
14
|
const webpackDevServerPort = port !== null && port !== void 0 ? port : undefined;
|
|
15
15
|
debug(`Using HtmlWebpackPlugin version ${htmlWebpackPluginVersion} from ${htmlWebpackPluginImportPath}`);
|
|
16
16
|
const optimization = {
|
|
@@ -56,9 +56,11 @@ function makeCypressWebpackConfig(config) {
|
|
|
56
56
|
devtool: 'inline-source-map',
|
|
57
57
|
};
|
|
58
58
|
if (isRunMode) {
|
|
59
|
+
// if experimentalJustInTimeCompile is configured, we need to watch for file changes as the spec entries are going to be updated per test
|
|
60
|
+
const ignored = experimentalJustInTimeCompile ? /node_modules/ : '**/*';
|
|
59
61
|
// Disable file watching when executing tests in `run` mode
|
|
60
62
|
finalConfig.watchOptions = {
|
|
61
|
-
ignored
|
|
63
|
+
ignored,
|
|
62
64
|
};
|
|
63
65
|
}
|
|
64
66
|
if (webpackDevServerMajorVersion === 5) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cypress/webpack-dev-server",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.11.0",
|
|
4
4
|
"description": "Launches Webpack Dev Server for Component Testing",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"semver": "^7.5.3",
|
|
26
26
|
"speed-measure-webpack-plugin": "1.4.2",
|
|
27
27
|
"tslib": "^2.3.1",
|
|
28
|
-
"webpack-dev-server": "^4.
|
|
28
|
+
"webpack-dev-server": "^4.15.2",
|
|
29
29
|
"webpack-merge": "^5.4.0"
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|