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
chore: upgrade cdk-from-cfn dependency to 0.157.0 (#29967)
### Reason for this change
The latest version of `cdk-from-cfn` is 0.157.0 which has introduced improved error types and error messages. As a result, I am manually bumping the version so that I can fix the unit tests that were testing the old error messages.
### Description of changes
Bumped `cdk-from-cfn` to 0.157.0, updated our error handling, and fixed broken unit tests.
### Description of how you validated changes
Fixed broken unit tests and ensured that no existing unit tests are failing.
### Checklist
- [x] My code adheres to the [CONTRIBUTING GUIDE](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md) and [DESIGN GUIDELINES](https://github.com/aws/aws-cdk/blob/main/docs/DESIGN_GUIDELINES.md)
----
*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
})).rejects.toThrowError('CannotGenerateTemplateStack could not be generated because template and/or language inputs caused the source code to panic');
920
-
expect(stderrMock.mock.calls[1][0]).toContain(' ❌ Migrate failed for `cannot-generate-template`: CannotGenerateTemplateStack could not be generated because template and/or language inputs caused the source code to panic');
919
+
})).rejects.toThrowError('CannotGenerateTemplateStack could not be generated because rust is not a supported language');
920
+
expect(stderrMock.mock.calls[1][0]).toContain(' ❌ Migrate failed for `cannot-generate-template`: CannotGenerateTemplateStack could not be generated because rust is not a supported language');
921
921
});
922
922
923
923
cliTest('migrate succeeds for valid template from local path when no lanugage is provided',async(workDir)=>{
Copy file name to clipboardExpand all lines: packages/aws-cdk/test/commands/migrate.test.ts
+1-1
Original file line number
Diff line number
Diff line change
@@ -134,7 +134,7 @@ describe('Migrate Function Tests', () => {
134
134
});
135
135
136
136
test('generateStack throws error when called for other language',()=>{
137
-
expect(()=>generateStack(validTemplate,'BadBadBad','php')).toThrowError('BadBadBadStack could not be generated because template and/or language inputs caused the source code to panic');
137
+
expect(()=>generateStack(validTemplate,'BadBadBad','php')).toThrowError('BadBadBadStack could not be generated because php is not a supported language');
138
138
});
139
139
140
140
test('generateStack throws error for invalid resource property',()=>{
0 commit comments