@@ -79,5 +79,27 @@ export default function () {
7979 . then ( ( ) => expectFileToMatch ( 'dist/main.bundle.js' ,
8080 '/base/deploy/assets/component-img-absolute.svg' ) )
8181 . then ( ( ) => expectFileToMatch ( 'dist/main.bundle.js' ,
82- / d e p l o y \/ c o m p o n e n t - i m g - r e l a t i v e \. [ 0 - 9 a - f ] { 20 } \. p n g / ) ) ;
82+ / d e p l o y \/ c o m p o n e n t - i m g - r e l a t i v e \. [ 0 - 9 a - f ] { 20 } \. p n g / ) )
83+ // Check with identical base-href and deploy-url flags.
84+ . then ( ( ) => ng ( 'build' , '--base-href=/base/' , '--deploy-url=/base/' ,
85+ '--extract-css' , '--aot' ) )
86+ . then ( ( ) => expectFileToMatch ( 'dist/styles.bundle.css' ,
87+ '/base/assets/global-img-absolute.svg' ) )
88+ . then ( ( ) => expectFileToMatch ( 'dist/styles.bundle.css' ,
89+ / g l o b a l - i m g - r e l a t i v e \. [ 0 - 9 a - f ] { 20 } \. p n g / ) )
90+ . then ( ( ) => expectFileToMatch ( 'dist/main.bundle.js' ,
91+ '/base/assets/component-img-absolute.svg' ) )
92+ . then ( ( ) => expectFileToMatch ( 'dist/main.bundle.js' ,
93+ / \/ b a s e \/ c o m p o n e n t - i m g - r e l a t i v e \. [ 0 - 9 a - f ] { 20 } \. p n g / ) )
94+ // Check with only base-href flag.
95+ . then ( ( ) => ng ( 'build' , '--base-href=/base/' ,
96+ '--extract-css' , '--aot' ) )
97+ . then ( ( ) => expectFileToMatch ( 'dist/styles.bundle.css' ,
98+ '/base/assets/global-img-absolute.svg' ) )
99+ . then ( ( ) => expectFileToMatch ( 'dist/styles.bundle.css' ,
100+ / g l o b a l - i m g - r e l a t i v e \. [ 0 - 9 a - f ] { 20 } \. p n g / ) )
101+ . then ( ( ) => expectFileToMatch ( 'dist/main.bundle.js' ,
102+ '/base/assets/component-img-absolute.svg' ) )
103+ . then ( ( ) => expectFileToMatch ( 'dist/main.bundle.js' ,
104+ / c o m p o n e n t - i m g - r e l a t i v e \. [ 0 - 9 a - f ] { 20 } \. p n g / ) ) ;
83105}
0 commit comments