@@ -15,8 +15,8 @@ import {
1515} from 'vitest' ;
1616
1717import { onHome , onTest } from '../src/actions' ;
18- import { readFile , writeFile } from '../src/helpers' ;
1918import { NPMRC , REGISTRIES } from '../src/constants' ;
19+ import { readFile , writeFile } from '../src/helpers' ;
2020
2121const isWin = process . platform === 'win32' ;
2222
@@ -98,7 +98,11 @@ it('nrm use <registry> local', async () => {
9898
9999 expect ( npmrc . registry ) . toBe ( REGISTRIES . cnpm . registry ) ;
100100
101- await coffee . spawn ( 'nrm' , [ 'current' ] , { shell : isWin } ) . expect ( 'stdout' , / c n p m / g) . expect ( 'code' , 0 ) . end ( ) ;
101+ await coffee
102+ . spawn ( 'nrm' , [ 'current' ] , { shell : isWin } )
103+ . expect ( 'stdout' , / c n p m / g)
104+ . expect ( 'code' , 0 )
105+ . end ( ) ;
102106} ) ;
103107
104108it ( 'nrm use <registry> local with user config' , async ( ) => {
@@ -115,7 +119,11 @@ it('nrm use <registry> local with user config', async () => {
115119 expect ( npmrc . registry ) . toBe ( REGISTRIES . cnpm . registry ) ;
116120 expect ( npmrc . abc ) . toBe ( '123' ) ;
117121
118- await coffee . spawn ( 'nrm' , [ 'current' ] , { shell : isWin } ) . expect ( 'stdout' , / c n p m / g) . expect ( 'code' , 0 ) . end ( ) ;
122+ await coffee
123+ . spawn ( 'nrm' , [ 'current' ] , { shell : isWin } )
124+ . expect ( 'stdout' , / c n p m / g)
125+ . expect ( 'code' , 0 )
126+ . end ( ) ;
119127} ) ;
120128
121129it ( 'nrm use without argument' , async ( ) => {
@@ -127,7 +135,9 @@ it('nrm use without argument', async () => {
127135 } ) ;
128136 } ) ;
129137
130- expect ( message ) . toBe ( `? Please select the registry you want to use (Use arrow keys)
138+ expect (
139+ message ,
140+ ) . toBe ( `? Please select the registry you want to use (Use arrow keys)
131141${ isWin ? '>' : '❯' } npm
132142 yarn
133143 tencent
0 commit comments