File tree 1 file changed +5
-2
lines changed
packages/angular_devkit/build_angular/src/protractor
1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -58,8 +58,11 @@ export class ProtractorBuilder implements Builder<ProtractorBuilderOptions> {
58
58
private _startDevServer ( options : ProtractorBuilderOptions ) {
59
59
const architect = this . context . architect ;
60
60
const [ project , targetName , configuration ] = ( options . devServerTarget as string ) . split ( ':' ) ;
61
- // Override browser build watch setting.
62
- const overrides = { watch : false , host : options . host , port : options . port } ;
61
+ // Override dev server watch setting.
62
+ const overrides : Partial < DevServerBuilderOptions > = { watch : false } ;
63
+ // Also override the port and host if they are defined in protractor options.
64
+ if ( options . host !== undefined ) { overrides . host = options . host ; }
65
+ if ( options . port !== undefined ) { overrides . port = options . port ; }
63
66
const targetSpec = { project, target : targetName , configuration, overrides } ;
64
67
const builderConfig = architect . getBuilderConfiguration < DevServerBuilderOptions > ( targetSpec ) ;
65
68
let devServerDescription : BuilderDescription ;
You can’t perform that action at this time.
0 commit comments