Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(spec2cdk): ICfnResource extends IConstruct #27862

Merged
merged 1 commit into from
Nov 6, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/awslint/lib/rules/construct.ts
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ constructLinter.add({

constructLinter.add({
code: 'construct-interface-extends-iconstruct',
message: 'construct interface must extend core.IConstruct',
message: 'construct interface must extend constructs.IConstruct',
eval: e => {
if (!e.ctx.interfaceType) { return; }
const interfaceBase = e.ctx.sys.findInterface(e.ctx.core.constructInterface.fqn);
Expand Down
1 change: 1 addition & 0 deletions tools/@aws-cdk/spec2cdk/lib/cdk/resource-class.ts
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ export class ResourceClass extends ClassType {
summary: `Attributes for \`${classNameFromResource(props.resource)}\`.`,
stability: Stability.External,
},
extends: [CONSTRUCTS.IConstruct],
});

super(scope, {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import * as cfn_parse from "aws-cdk-lib/core/lib/helpers-internal";
*
* @stability external
*/
export interface ICfnResource {
export interface ICfnResource extends constructs.IConstruct {
/**
* The identifier of the resource.
*
Expand Down Expand Up @@ -165,7 +165,7 @@ import * as cfn_parse from "aws-cdk-lib/core/lib/helpers-internal";
*
* @stability external
*/
export interface ICfnResource {
export interface ICfnResource extends constructs.IConstruct {
/**
* The identifier of the resource
*
Expand Down Expand Up @@ -310,7 +310,7 @@ import * as cfn_parse from "aws-cdk-lib/core/lib/helpers-internal";
*
* @stability external
*/
export interface ICfnSomething {
export interface ICfnSomething extends constructs.IConstruct {
/**
* The identifier of the resource
*
Expand Down Expand Up @@ -470,7 +470,7 @@ import * as cfn_parse from "aws-cdk-lib/core/lib/helpers-internal";
*
* @stability external
*/
export interface ICfnResource {
export interface ICfnResource extends constructs.IConstruct {
/**
* The identifier of the resource
*
Expand Down Expand Up @@ -630,7 +630,7 @@ import * as cfn_parse from "aws-cdk-lib/core/lib/helpers-internal";
*
* @stability external
*/
export interface ICfnResource {
export interface ICfnResource extends constructs.IConstruct {
/**
* The identifier of the resource
*
Expand Down Expand Up @@ -790,7 +790,7 @@ import * as cfn_parse from "aws-cdk-lib/core/lib/helpers-internal";
*
* @stability external
*/
export interface ICfnResource {
export interface ICfnResource extends constructs.IConstruct {
/**
* The arn of the resource
*
Expand Down Expand Up @@ -935,7 +935,7 @@ import * as cfn_parse from "aws-cdk-lib/core/lib/helpers-internal";
*
* @stability external
*/
export interface ICfnResource {
export interface ICfnResource extends constructs.IConstruct {
/**
* The identifier of the resource
*
Expand Down
Loading