Skip to content

Commit c12960f

Browse files
committed
test: update
1 parent 58d5af4 commit c12960f

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

packages/aws-cdk/test/commands/init.test.ts

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1369,8 +1369,6 @@ describe('constructs version', () => {
13691369
type: 'app',
13701370
language,
13711371
packageManager: packageManager as JsPackageManager,
1372-
canUseNetwork: true,
1373-
generateOnly: false,
13741372
workDir,
13751373
});
13761374

@@ -1386,12 +1384,13 @@ describe('constructs version', () => {
13861384
ioHelper,
13871385
type: 'app',
13881386
language: 'typescript',
1389-
canUseNetwork: false,
1390-
generateOnly: true,
13911387
workDir,
13921388
});
13931389

1394-
expect(await fs.pathExists(path.join(workDir, 'package.json'))).toBeTruthy();
1390+
const installCalls = spawnSpy.mock.calls.filter(
1391+
([cmd, args]) => cmd === 'npm' && args.includes('install'),
1392+
);
1393+
expect(installCalls.length).toBeGreaterThan(0);
13951394
});
13961395

13971396
cliTest('ignores package manager option for non-JavaScript languages', async (workDir) => {

0 commit comments

Comments
 (0)