File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change 4
4
* Reminder that this script is meant to be runnable without installing
5
5
* dependencies. It can therefore not rely on any external libraries.
6
6
*/
7
- import { spawn } from "node:child_process" ;
7
+ import { spawn , spawnSync } from "node:child_process" ;
8
8
import * as fs from "node:fs" ;
9
9
import { URL , fileURLToPath } from "node:url" ;
10
10
import * as util from "node:util" ;
@@ -327,8 +327,7 @@ if (platforms.length === 0) {
327
327
} )
328
328
. then ( ( ) => {
329
329
showBanner ( `Reconfigure existing app` ) ;
330
- $ (
331
- PACKAGE_MANAGER ,
330
+ const args = [
332
331
"configure-test-app" ,
333
332
"-p" ,
334
333
"android" ,
@@ -340,7 +339,11 @@ if (platforms.length === 0) {
340
339
"visionos" ,
341
340
"-p" ,
342
341
"windows"
343
- ) ;
342
+ ] ;
343
+ const { status } = spawnSync ( PACKAGE_MANAGER , args , { stdio : "inherit" } ) ;
344
+ if ( status !== 1 ) {
345
+ throw new Error ( "Expected an error" ) ;
346
+ }
344
347
} )
345
348
. then ( ( ) => {
346
349
showBanner ( green ( "✔ Pass" ) ) ;
You can’t perform that action at this time.
0 commit comments