Skip to content

Commit

Permalink
lint files
Browse files Browse the repository at this point in the history
  • Loading branch information
ivanbarlog committed Nov 22, 2024
1 parent 2ea314a commit e6d0d12
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1306,7 +1306,7 @@ test('with origin access control id', () => {
CustomOriginConfig: {
OriginProtocolPolicy: 'https-only',
},
OriginAccessControlId: "test-origin-access-control-id"
OriginAccessControlId: 'test-origin-access-control-id',
}],
},
});
Expand Down
20 changes: 10 additions & 10 deletions packages/aws-cdk-lib/aws-cloudfront/test/test-origin.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Construct } from "constructs";
import { Construct } from 'constructs';
import {
CfnDistribution,
IOrigin,
Expand All @@ -7,24 +7,24 @@ import {
OriginBindOptions,
OriginProps,
OriginProtocolPolicy,
} from "../lib";
} from '../lib';

/** Used for testing common Origin functionality */
export class TestOrigin extends OriginBase {
constructor(domainName: string, props: OriginProps = {}) {
super(domainName, props);
}
protected renderCustomOriginConfig():
| CfnDistribution.CustomOriginConfigProperty
| undefined {
| CfnDistribution.CustomOriginConfigProperty
| undefined {
return { originProtocolPolicy: OriginProtocolPolicy.HTTPS_ONLY };
}
}

export class TestOriginGroup implements IOrigin {
constructor(
private readonly primaryDomainName: string,
private readonly secondaryDomainName: string
private readonly secondaryDomainName: string,
) {}
/* eslint-disable @cdklabs/no-core-construct */
public bind(scope: Construct, options: OriginBindOptions): OriginBindConfig {
Expand All @@ -42,23 +42,23 @@ export class TestOriginGroup implements IOrigin {
}

export function defaultOrigin(domainName?: string, originId?: string): IOrigin {
return new TestOrigin(domainName ?? "www.example.com", {
return new TestOrigin(domainName ?? 'www.example.com', {
originId,
});
}

export function defaultOriginGroup(): IOrigin {
return new TestOriginGroup("www.example.com", "foo.example.com");
return new TestOriginGroup('www.example.com', 'foo.example.com');
}

export function defaultOriginWithOriginAccessControl(
domainName?: string,
originId?: string,
originAccessControlId?: string
originAccessControlId?: string,
): IOrigin {
return new TestOrigin(domainName ?? "www.example.com", {
return new TestOrigin(domainName ?? 'www.example.com', {
originId,
originAccessControlId:
originAccessControlId ?? "test-origin-access-control-id",
originAccessControlId ?? 'test-origin-access-control-id',
});
}

0 comments on commit e6d0d12

Please sign in to comment.