@@ -42,7 +42,7 @@ export default async function () {
42
42
43
43
const { stdout } = await execWithEnv (
44
44
'ng' ,
45
- [ 'version ' ] ,
45
+ [ 'config ' ] ,
46
46
{
47
47
...DEFAULT_ENV ,
48
48
SHELL : '/bin/bash' ,
@@ -74,7 +74,7 @@ export default async function () {
74
74
75
75
const { stdout } = await execWithEnv (
76
76
'ng' ,
77
- [ 'version ' ] ,
77
+ [ 'config ' ] ,
78
78
{
79
79
...DEFAULT_ENV ,
80
80
SHELL : '/bin/bash' ,
@@ -112,7 +112,7 @@ export default async function () {
112
112
113
113
const { stdout : stdout1 } = await execWithEnv (
114
114
'ng' ,
115
- [ 'version ' ] ,
115
+ [ 'config ' ] ,
116
116
{
117
117
...DEFAULT_ENV ,
118
118
SHELL : '/bin/bash' ,
@@ -136,7 +136,7 @@ export default async function () {
136
136
// User modifies their configuration and removes `ng completion`.
137
137
await fs . writeFile ( bashrc , '# Some new commands...' ) ;
138
138
139
- const { stdout : stdout2 } = await execWithEnv ( 'ng' , [ 'version ' ] , {
139
+ const { stdout : stdout2 } = await execWithEnv ( 'ng' , [ 'config ' ] , {
140
140
...DEFAULT_ENV ,
141
141
SHELL : '/bin/bash' ,
142
142
HOME : home ,
@@ -165,7 +165,7 @@ export default async function () {
165
165
166
166
const { stdout : stdout1 } = await execWithEnv (
167
167
'ng' ,
168
- [ 'version ' ] ,
168
+ [ 'config ' ] ,
169
169
{
170
170
...DEFAULT_ENV ,
171
171
SHELL : '/bin/bash' ,
@@ -178,7 +178,7 @@ export default async function () {
178
178
throw new Error ( 'First execution did not prompt for autocompletion setup.' ) ;
179
179
}
180
180
181
- const { stdout : stdout2 } = await execWithEnv ( 'ng' , [ 'version ' ] , {
181
+ const { stdout : stdout2 } = await execWithEnv ( 'ng' , [ 'config ' ] , {
182
182
...DEFAULT_ENV ,
183
183
SHELL : '/bin/bash' ,
184
184
HOME : home ,
@@ -211,7 +211,7 @@ export default async function () {
211
211
212
212
const err = await execAndCaptureError (
213
213
'ng' ,
214
- [ 'version ' ] ,
214
+ [ 'config ' ] ,
215
215
{
216
216
...DEFAULT_ENV ,
217
217
SHELL : '/bin/bash' ,
@@ -231,7 +231,7 @@ export default async function () {
231
231
232
232
const { stdout : stdout2 } = await execWithEnv (
233
233
'ng' ,
234
- [ 'version ' ] ,
234
+ [ 'config ' ] ,
235
235
{
236
236
...DEFAULT_ENV ,
237
237
SHELL : '/bin/bash' ,
@@ -283,7 +283,7 @@ export default async function () {
283
283
284
284
// Does *not* prompt user for CI executions.
285
285
{
286
- const { stdout } = await execWithEnv ( 'ng' , [ 'version ' ] , {
286
+ const { stdout } = await execWithEnv ( 'ng' , [ 'config ' ] , {
287
287
...DEFAULT_ENV ,
288
288
CI : 'true' ,
289
289
NG_FORCE_TTY : undefined ,
@@ -296,7 +296,7 @@ export default async function () {
296
296
297
297
// Does *not* prompt user for non-TTY executions.
298
298
{
299
- const { stdout } = await execWithEnv ( 'ng' , [ 'version ' ] , {
299
+ const { stdout } = await execWithEnv ( 'ng' , [ 'config ' ] , {
300
300
...DEFAULT_ENV ,
301
301
NG_FORCE_TTY : 'false' ,
302
302
} ) ;
@@ -308,7 +308,7 @@ export default async function () {
308
308
309
309
// Does *not* prompt user for executions without a `$HOME`.
310
310
{
311
- const { stdout } = await execWithEnv ( 'ng' , [ 'version ' ] , {
311
+ const { stdout } = await execWithEnv ( 'ng' , [ 'config ' ] , {
312
312
...DEFAULT_ENV ,
313
313
HOME : undefined ,
314
314
} ) ;
@@ -323,7 +323,7 @@ export default async function () {
323
323
324
324
// Does *not* prompt user for executions without a `$SHELL`.
325
325
{
326
- const { stdout } = await execWithEnv ( 'ng' , [ 'version ' ] , {
326
+ const { stdout } = await execWithEnv ( 'ng' , [ 'config ' ] , {
327
327
...DEFAULT_ENV ,
328
328
SHELL : undefined ,
329
329
} ) ;
@@ -338,7 +338,7 @@ export default async function () {
338
338
339
339
// Does *not* prompt user for executions from unknown shells.
340
340
{
341
- const { stdout } = await execWithEnv ( 'ng' , [ 'version ' ] , {
341
+ const { stdout } = await execWithEnv ( 'ng' , [ 'config ' ] , {
342
342
...DEFAULT_ENV ,
343
343
SHELL : '/usr/bin/unknown' ,
344
344
} ) ;
@@ -364,7 +364,7 @@ source <(ng completion script)
364
364
` . trim ( ) ,
365
365
) ;
366
366
367
- const { stdout } = await execWithEnv ( 'ng' , [ 'version ' ] , {
367
+ const { stdout } = await execWithEnv ( 'ng' , [ 'config ' ] , {
368
368
...DEFAULT_ENV ,
369
369
SHELL : '/bin/bash' ,
370
370
HOME : home ,
@@ -383,7 +383,7 @@ source <(ng completion script)
383
383
const bashrc = path . join ( home , '.bashrc' ) ;
384
384
await fs . writeFile ( bashrc , `# Other content...` ) ;
385
385
386
- await execAndWaitForOutputToMatch ( 'ng' , [ 'version ' ] , AUTOCOMPLETION_PROMPT , {
386
+ await execAndWaitForOutputToMatch ( 'ng' , [ 'config ' ] , AUTOCOMPLETION_PROMPT , {
387
387
...DEFAULT_ENV ,
388
388
SHELL : '/bin/bash' ,
389
389
HOME : home ,
@@ -411,7 +411,7 @@ source <(ng completion script)
411
411
const localCliBinary = path . join ( localCliDir , 'ng' ) ;
412
412
const pathDirs = process . env [ 'PATH' ] ! . split ( ':' ) ;
413
413
const pathEnvVar = [ ...pathDirs , localCliDir ] . join ( ':' ) ;
414
- const { stdout } = await execWithEnv ( localCliBinary , [ 'version ' ] , {
414
+ const { stdout } = await execWithEnv ( localCliBinary , [ 'config ' ] , {
415
415
...DEFAULT_ENV ,
416
416
SHELL : '/bin/bash' ,
417
417
HOME : home ,
@@ -437,7 +437,7 @@ async function windowsTests(): Promise<void> {
437
437
const bashrc = path . join ( home , '.bashrc' ) ;
438
438
await fs . writeFile ( bashrc , `# Other content...` ) ;
439
439
440
- const { stdout } = await execWithEnv ( 'ng' , [ 'version ' ] , { ...env } ) ;
440
+ const { stdout } = await execWithEnv ( 'ng' , [ 'config ' ] , { ...env } ) ;
441
441
442
442
if ( AUTOCOMPLETION_PROMPT . test ( stdout ) ) {
443
443
throw new Error (
0 commit comments