diff --git a/lib/plugins/aws/deploy/compile/events/stream/index.test.js b/lib/plugins/aws/deploy/compile/events/stream/index.test.js index 91dff7c8b..6c6a127db 100644 --- a/lib/plugins/aws/deploy/compile/events/stream/index.test.js +++ b/lib/plugins/aws/deploy/compile/events/stream/index.test.js @@ -346,13 +346,13 @@ describe('AwsCompileStreamEvents', () => { events: [ { stream: { - arn: {'Fn::GetAtt': ['SomeDdbTable', 'StreamArn']}, + arn: { 'Fn::GetAtt': ['SomeDdbTable', 'StreamArn'] }, type: 'dynamodb', }, }, { stream: { - arn: {'Fn::ImportValue': 'ForeignKinesis'}, + arn: { 'Fn::ImportValue': 'ForeignKinesis' }, type: 'kinesis', }, }, @@ -364,39 +364,39 @@ describe('AwsCompileStreamEvents', () => { // dynamodb version expect(awsCompileStreamEvents.serverless.service - .provider.compiledCloudFormationTemplate.Resources.FirstEventSourceMappingDynamodbSomeDdbTable - .Properties.EventSourceArn + .provider.compiledCloudFormationTemplate.Resources + .FirstEventSourceMappingDynamodbSomeDdbTable.Properties.EventSourceArn ).to.deep.equal( - {'Fn::GetAtt': ['SomeDdbTable', 'StreamArn']} + { 'Fn::GetAtt': ['SomeDdbTable', 'StreamArn'] } ); expect(awsCompileStreamEvents.serverless.service .provider.compiledCloudFormationTemplate.Resources.IamRoleLambdaExecution .Properties.Policies[0].PolicyDocument.Statement[0] ).to.deep.equal( { - "Action": [ - "dynamodb:GetRecords", - "dynamodb:GetShardIterator", - "dynamodb:DescribeStream", - "dynamodb:ListStreams" + Action: [ + 'dynamodb:GetRecords', + 'dynamodb:GetShardIterator', + 'dynamodb:DescribeStream', + 'dynamodb:ListStreams', ], - "Effect": "Allow", - "Resource": [ + Effect: 'Allow', + Resource: [ { - "Fn::GetAtt": [ - "SomeDdbTable", - "StreamArn" - ] - } - ] + 'Fn::GetAtt': [ + 'SomeDdbTable', + 'StreamArn', + ], + }, + ], } ); // and now kinesis expect(awsCompileStreamEvents.serverless.service - .provider.compiledCloudFormationTemplate.Resources.FirstEventSourceMappingKinesisForeignKinesis - .Properties.EventSourceArn + .provider.compiledCloudFormationTemplate.Resources + .FirstEventSourceMappingKinesisForeignKinesis.Properties.EventSourceArn ).to.deep.equal( - {'Fn::ImportValue': 'ForeignKinesis'} + { 'Fn::ImportValue': 'ForeignKinesis' } ); }); @@ -406,7 +406,7 @@ describe('AwsCompileStreamEvents', () => { events: [ { stream: { - arn: {'Fn::GetAtt': ['SomeDdbTable', 'StreamArn']}, + arn: { 'Fn::GetAtt': ['SomeDdbTable', 'StreamArn'] }, }, }, ],