File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
tests/legacy-cli/e2e/tests/build Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change 1+ import { SemVer } from 'semver' ;
12import { getGlobalVariable } from '../../utils/env' ;
23import { replaceInFile } from '../../utils/fs' ;
34import { installPackage , installWorkspacePackages } from '../../utils/packages' ;
45import { ng } from '../../utils/process' ;
56import { isPrereleaseCli , updateJsonFile } from '../../utils/project' ;
7+ import { readNgVersion } from '../../utils/version' ;
68
79const snapshots = require ( '../../ng-snapshot/package.json' ) ;
810
911export default async function ( ) {
10- const tag = await isPrereleaseCli ( ) ? '@next' : '' ;
12+ const tag = ( await isPrereleaseCli ( ) ) ? '@next' : `@ ${ new SemVer ( readNgVersion ( ) ) . major } ` ;
1113 await ng ( 'add' , `@angular/material${ tag } ` , '--skip-confirmation' ) ;
1214
1315 const isSnapshotBuild = getGlobalVariable ( 'argv' ) [ 'ng-snapshots' ] ;
@@ -28,7 +30,7 @@ export default async function () {
2830
2931 await installWorkspacePackages ( ) ;
3032 } else {
31- await installPackage ( ' @angular/material-moment-adapter' ) ;
33+ await installPackage ( ` @angular/material-moment-adapter${ tag } ` ) ;
3234 }
3335
3436 await installPackage ( 'moment' ) ;
You can’t perform that action at this time.
0 commit comments