From f0f58cdd31be873c3b6ae7f96c034bdbdfb30cab Mon Sep 17 00:00:00 2001 From: Samson Keung Date: Thu, 29 Aug 2024 13:04:44 -0700 Subject: [PATCH] liniting fixes --- .../test/integ.s3-bucket-origin-default.ts | 2 +- .../test/integ.s3-bucket-origin-oai.ts | 6 +++--- .../test/integ.s3-static-website-origin.ts | 8 ++++---- .../aws-cloudfront-origins/test/s3-bucket-origin.test.ts | 4 ++-- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/packages/@aws-cdk-testing/framework-integ/test/aws-cloudfront-origins/test/integ.s3-bucket-origin-default.ts b/packages/@aws-cdk-testing/framework-integ/test/aws-cloudfront-origins/test/integ.s3-bucket-origin-default.ts index 87c0864cf7acb..07bcca05bbc24 100644 --- a/packages/@aws-cdk-testing/framework-integ/test/aws-cloudfront-origins/test/integ.s3-bucket-origin-default.ts +++ b/packages/@aws-cdk-testing/framework-integ/test/aws-cloudfront-origins/test/integ.s3-bucket-origin-default.ts @@ -13,7 +13,7 @@ const bucket = new s3.Bucket(stack, 'Bucket', { }); const s3Origin = origins.S3BucketOrigin.withBucketDefaults(bucket); const distribution = new cloudfront.Distribution(stack, 'Distribution', { - defaultBehavior: { origin: s3Origin}, + defaultBehavior: { origin: s3Origin }, }); const integ = new IntegTest(app, 's3-origin-oac', { diff --git a/packages/@aws-cdk-testing/framework-integ/test/aws-cloudfront-origins/test/integ.s3-bucket-origin-oai.ts b/packages/@aws-cdk-testing/framework-integ/test/aws-cloudfront-origins/test/integ.s3-bucket-origin-oai.ts index 778b2b1e60d2d..4141d515a7f5c 100644 --- a/packages/@aws-cdk-testing/framework-integ/test/aws-cloudfront-origins/test/integ.s3-bucket-origin-oai.ts +++ b/packages/@aws-cdk-testing/framework-integ/test/aws-cloudfront-origins/test/integ.s3-bucket-origin-oai.ts @@ -14,7 +14,7 @@ const originAccessIdentity = new cloudfront.OriginAccessIdentity(stack, 'OriginA }); const s3Origin = origins.S3BucketOrigin.withOriginAccessIdentity(bucket, { originAccessIdentity }); const distribution = new cloudfront.Distribution(stack, 'Distribution', { - defaultBehavior: { origin: s3Origin}, + defaultBehavior: { origin: s3Origin }, }); const integ = new IntegTest(app, 's3-origin-oac', { @@ -48,6 +48,6 @@ integ.assertions.awsApiCall('CloudFront', 'getCloudFrontOriginAccessIdentity', { CloudFrontOriginAccessIdentityConfig: { CallerReference: Match.stringLikeRegexp('^[A-Za-z0-9-]+$'), Comment: 'OAI for my awesome test s3 origin', - } - } + }, + }, })); diff --git a/packages/@aws-cdk-testing/framework-integ/test/aws-cloudfront-origins/test/integ.s3-static-website-origin.ts b/packages/@aws-cdk-testing/framework-integ/test/aws-cloudfront-origins/test/integ.s3-static-website-origin.ts index b132b1bac1ad9..6efec1b7a660d 100644 --- a/packages/@aws-cdk-testing/framework-integ/test/aws-cloudfront-origins/test/integ.s3-static-website-origin.ts +++ b/packages/@aws-cdk-testing/framework-integ/test/aws-cloudfront-origins/test/integ.s3-static-website-origin.ts @@ -11,7 +11,7 @@ const stack = new cdk.Stack(app, 'cloudfront-s3-static-website-origin'); const bucket = new s3.Bucket(stack, 'Bucket', { removalPolicy: cdk.RemovalPolicy.DESTROY, }); -const s3Origin = new origins.S3StaticWebsiteOrigin({bucket}); +const s3Origin = new origins.S3StaticWebsiteOrigin({ bucket }); const distribution = new cloudfront.Distribution(stack, 'Distribution', { defaultBehavior: { origin: s3Origin, @@ -36,9 +36,9 @@ integ.assertions.awsApiCall('CloudFront', 'getDistributionConfig', { HTTPSPort: 443, OriginProtocolPolicy: 'http-only', OriginSslProtocols: { - Items: ['TLSv1.2'] - } - } + Items: ['TLSv1.2'], + }, + }, }), ]), }, diff --git a/packages/aws-cdk-lib/aws-cloudfront-origins/test/s3-bucket-origin.test.ts b/packages/aws-cdk-lib/aws-cloudfront-origins/test/s3-bucket-origin.test.ts index 43a6087de09a0..31c53a9755079 100644 --- a/packages/aws-cdk-lib/aws-cloudfront-origins/test/s3-bucket-origin.test.ts +++ b/packages/aws-cdk-lib/aws-cloudfront-origins/test/s3-bucket-origin.test.ts @@ -698,7 +698,7 @@ describe('S3BucketOrigin', () => { it('should warn user bucket policy is not updated', () => { Annotations.fromStack(stack).hasWarning('/Default/MyDistributionA/Origin1', - 'Cannot update bucket policy of an imported bucket. You will need to update the policy manually instead.\n' + + 'Cannot update bucket policy of an imported bucket. You will need to update the policy manually instead.\n' + 'See the "Setting up OAC with imported S3 buckets" section of module\'s README for more info. [ack: @aws-cdk/aws-cloudfront-origins:updateImportedBucketPolicyOac]'); }); @@ -1150,7 +1150,7 @@ describe('S3BucketOrigin', () => { it('should warn user bucket policy is not updated', () => { Annotations.fromStack(distributionStack).hasWarning('/distributionStack/MyDistributionA/Origin1', - 'Cannot update bucket policy of an imported bucket. You will need to update the policy manually instead.\n' + + 'Cannot update bucket policy of an imported bucket. You will need to update the policy manually instead.\n' + 'See the "Setting up OAI with imported S3 buckets (legacy)" section of module\'s README for more info. [ack: @aws-cdk/aws-cloudfront-origins:updateImportedBucketPolicyOai]'); });