Skip to content

Commit 747d3e6

Browse files
committed
feat(@angular/cli): add trailing slash to deployUrl when missing
Closes #7295
1 parent 76ca580 commit 747d3e6

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

tests/e2e/tests/build/deploy-url.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ import { ng } from '../../utils/process';
22
import { copyProjectAsset } from '../../utils/assets';
33
import { expectFileToMatch, writeMultipleFiles } from '../../utils/fs';
44
import { updateJsonFile } from '../../utils/project';
5+
import { getGlobalVariable } from '../../utils/env';
56

67

78
export default function () {
@@ -32,6 +33,8 @@ export default function () {
3233
/__webpack_require__\.p = "deployUrl\/";/))
3334
// verify slash is appended to the end of --deploy-url if missing
3435
.then(() => ng('build', '--deploy-url=deployUrl', '--extract-css=false'))
35-
.then(() => expectFileToMatch('dist/inline.bundle.js',
36-
/__webpack_require__\.p = "deployUrl\/";/));
36+
// skip this in ejected tests
37+
.then(() => getGlobalVariable('argv').eject
38+
? Promise.resolve()
39+
: expectFileToMatch('dist/inline.bundle.js', /__webpack_require__\.p = "deployUrl\/";/));
3740
}

0 commit comments

Comments
 (0)