Skip to content

Commit f4cf6aa

Browse files
committed
test: use random devserver ports
1 parent 585a1c9 commit f4cf6aa

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

packages/angular_devkit/build_angular/src/builders/dev-server/specs/works_spec.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ describe('Dev Server Builder', () => {
3434
expect(output.success).toBe(true);
3535

3636
// When webpack-dev-server doesn't have `contentBase: false`, this will serve the repo README.
37-
const response = await fetch('http://localhost:4200/README.md', {
37+
const response = await fetch(`http://localhost:${output.port}/README.md`, {
3838
headers: {
3939
'Accept': 'text/html',
4040
},

packages/angular_devkit/build_angular/test/hello-world-app/protractor.conf.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ exports.config = {
2323
},
2424
},
2525
directConnect: true,
26-
baseUrl: 'http://localhost:4200/',
26+
baseUrl: 'http://localhost:0/',
2727
framework: 'jasmine',
2828
jasmineNodeOpts: {
2929
showColors: true,

packages/schematics/angular/e2e/files/protractor.conf.js.template

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ exports.config = {
1717
},
1818
directConnect: true,
1919
SELENIUM_PROMISE_MANAGER: false,
20-
baseUrl: 'http://localhost:4200/',
20+
baseUrl: 'http://localhost:0/',
2121
framework: 'jasmine',
2222
jasmineNodeOpts: {
2323
showColors: true,

tests/legacy-cli/e2e/assets/12.0-project/e2e/protractor.conf.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ exports.config = {
1414
browserName: 'chrome',
1515
},
1616
directConnect: true,
17-
baseUrl: 'http://localhost:4200/',
17+
baseUrl: 'http://localhost:0/',
1818
framework: 'jasmine',
1919
jasmineNodeOpts: {
2020
showColors: true,

0 commit comments

Comments
 (0)