You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
refactor(toolkit-lib): remove requireApproval option from diff (#372)
`requireApproval` is deprecated and has been moved to the `CliIoHost`.
this PR removes the last place where `requireApproval` was necessary in
`tmp-toolkit-helpers`, in `formatSecurityDiff`. `formatSecurityDiff` now
makes no _decisions_ on what to print; it returns the diff and a
`permissionChangeType` for the `IoHost` to interpret. this is a slight
behavior change, so all consumers of `formatSecurityDiff have been
updated accordingly (`deploy` and `diff` in `toolkit-lib` and in the
CLI).
`requireApproval` is now a vestigial structure only in use in the CLI.
---
By submitting this pull request, I confirm that my contribution is made
under the terms of the Apache-2.0 license
---------
Co-authored-by: Momo Kornher <[email protected]>
Copy file name to clipboardExpand all lines: packages/@aws-cdk-testing/cli-integ/tests/cli-integ-tests/cdk-lib-security-related-changes-without-a-cli-are-expected-to-fail-when-approval-is-required.integtest.ts
-3
Original file line number
Diff line number
Diff line change
@@ -13,9 +13,6 @@ integTest(
13
13
neverRequireApproval: false,
14
14
});
15
15
16
-
expect(stdErr).toContain(
17
-
'This deployment will make potentially sensitive changes according to your current security approval level',
18
-
);
19
16
expect(stdErr).toContain(
20
17
'"--require-approval" is enabled and stack includes security-sensitive updates',
ioDefaultHelper.warning(`This deployment will make potentially sensitive changes according to your current security approval level (--require-approval ${options.requireApproval}).`);
298
-
ioDefaultHelper.warning('Please confirm you intend to make the following modifications:\n');
299
-
try{
300
-
// formatSecurityChanges updates the stream with the formatted security diff
0 commit comments