Skip to content

Commit e0f3d40

Browse files
committed
test(e2e): use port assigner
1 parent b70f151 commit e0f3d40

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

test/e2e/Progress.test.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ const { resolve } = require('path');
88
const testServer = require('../helpers/test-server');
99
const reloadConfig = require('../fixtures/reload-config/webpack.config');
1010
const runBrowser = require('../helpers/run-browser');
11+
const port = require('../ports-map').Progress;
1112

1213
const cssFilePath = resolve(__dirname, '../fixtures/reload-config/main.css');
1314

@@ -19,7 +20,7 @@ describe('client progress', () => {
1920
'body { background-color: rgb(0, 0, 255); }'
2021
);
2122
const options = {
22-
port: 9000,
23+
port,
2324
host: '0.0.0.0',
2425
inline: true,
2526
hot: true,
@@ -56,7 +57,7 @@ describe('client progress', () => {
5657
});
5758
});
5859

59-
page.goto('http://localhost:9000/main');
60+
page.goto(`http://localhost:${port}/main`);
6061
page.on('console', ({ _text }) => {
6162
res.push(_text);
6263
});

test/ports-map.js

+1
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ const portsList = {
3535
'sockPath-option': 1,
3636
'stats-option': 1,
3737
ProvidePlugin: 1,
38+
Progress: 1,
3839
};
3940

4041
let startPort = 8079;

0 commit comments

Comments
 (0)