-
Notifications
You must be signed in to change notification settings - Fork 4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(aws-ssm): correctly emit Association.Name
The rename used to happen in the cfnspec, which helped the model generate correct names, but the code generator would lose the ability to access the original name, and so it could not be emitted correctly. Add a property renaming feature to the 'cfn2ts' code generator (configured via a special entry in package.json). Fixes #852.
- Loading branch information
Rico Huijbers
committed
Oct 5, 2018
1 parent
a67b2d9
commit d131223
Showing
6 changed files
with
100 additions
and
50 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import { expect, haveResource } from '@aws-cdk/assert'; | ||
import cdk = require('@aws-cdk/cdk'); | ||
import { Test } from 'nodeunit'; | ||
import ssm = require('../lib'); | ||
|
||
export = { | ||
'association name is rendered properly in L1 construct'(test: Test) { | ||
// GIVEN | ||
const stack = new cdk.Stack(); | ||
|
||
// WHEN | ||
new ssm.cloudformation.AssociationResource(stack, 'Assoc', { | ||
documentName: 'document', | ||
}); | ||
|
||
// THEN | ||
expect(stack).to(haveResource('AWS::SSM::Association', { | ||
Name: 'document', | ||
})); | ||
|
||
test.done(); | ||
} | ||
}; |
16 changes: 0 additions & 16 deletions
16
packages/@aws-cdk/cfnspec/spec-source/500_SSM_AssociationName_patch.json
This file was deleted.
Oops, something went wrong.
9 changes: 0 additions & 9 deletions
9
packages/@aws-cdk/cfnspec/spec-source/500_SSM_AssociationName_patch.md
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters