Skip to content

Commit b2af1e4

Browse files
author
Hogan Bobertz
committed
bug fix for cli integ tests
1 parent fc3650c commit b2af1e4

1 file changed

Lines changed: 4 additions & 11 deletions

File tree

packages/@aws-cdk-testing/cli-integ/tests/cli-integ-tests/cli.integtest.ts

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { promises as fs, existsSync } from 'fs';
22
import * as os from 'os';
33
import * as path from 'path';
4-
import { AwsClients, TestFixture, integTest, cloneDirectory, shell, withDefaultFixture, retry, sleep, randomInteger, withSamIntegrationFixture, RESOURCES_DIR, withCDKMigrateFixture, withExtendedTimeoutFixture } from '../../lib';
4+
import { integTest, cloneDirectory, shell, withDefaultFixture, retry, sleep, randomInteger, withSamIntegrationFixture, RESOURCES_DIR, withCDKMigrateFixture, withExtendedTimeoutFixture } from '../../lib';
55

66
jest.setTimeout(2 * 60 * 60_000); // Includes the time to acquire locks, worst-case single-threaded runtime
77

@@ -687,22 +687,15 @@ integTest('cdk migrate --from-scan for resources with Write Only Properties gene
687687
['migrate', '--stack-name', migrateStackName, '--from-stack'],
688688
{ modEnv: { MIGRATE_INTEG_TEST: '1' }, neverRequireApproval: true, verbose: true, captureStderr: false },
689689
);
690-
const awsClients = await AwsClients.default(fixture.output);
691-
const fixtureJr = new TestFixture(
692-
path.join(fixture.integTestDir, migrateStackName),
693-
fixture.stackNamePrefix,
694-
fixture.output,
695-
awsClients,
696-
'',
697-
);
698-
await fixtureJr.cdkDeploy('migrate-stack', { neverRequireApproval: true, verbose: true, captureStderr: false });
690+
await fixture.shell(['cd', path.join(fixture.integTestDir, migrateStackName)]);
691+
await fixture.cdk(['deploy', migrateStackName], { neverRequireApproval: true, verbose: true, captureStderr: false });
699692
const response = await fixture.aws.cloudFormation('describeStacks', {
700693
StackName: migrateStackName,
701694
});
702695

703696
expect(response.Stacks?.[0].StackStatus).toEqual('UPDATE_COMPLETE');
704697
} finally {
705-
await fixture.cdkDestroy(migrateStackName);
698+
await fixture.cdkDestroy('migrate-stack');
706699
}
707700
}));
708701
});

0 commit comments

Comments
 (0)