import * as cdk from '@aws-cdk/core' ; import { SynthUtils } from '@aws-cdk/assert' ; import * as event from '../lib/event-stack' ; import * as s3 from '@aws-cdk/aws-s3' ; import * as sqs from '@aws-cdk/aws-sqs' ; test ( 'Test event stack' , ( ) => { const stack = new cdk . Stack ( ) ; new event . EventStack ( stack , 'MyTestStack' , { events : 'Create' , bucket : new s3 . Bucket ( stack , 'TestBucket' ) , prefix : 'test' , queue : new sqs . Queue ( stack , 'TestQueue' ) , } ) ; expect ( SynthUtils . toCloudFormation ( stack ) ) . toMatchSnapshot ( ) ; } ) ;