Skip to content

Commit

Permalink
fix unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
0618 committed Feb 19, 2024
1 parent c1e905c commit e4b96a1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions packages/backend/src/engine/amplify_stack.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { CfnElement, Stack } from 'aws-cdk-lib';
import { Stack } from 'aws-cdk-lib';

/**
* Amplify-specific Stack implementation to handle cross-cutting concerns for all Amplify stacks
Expand All @@ -7,7 +7,7 @@ export class AmplifyStack extends Stack {
/**
* Overrides Stack.allocateLogicalId to prevent redundant nested stack logical IDs
*/
allocateLogicalId = (element: CfnElement): string => {
allocateLogicalId = (element: CfnEleme_cnt): string => {

Check failure on line 10 in packages/backend/src/engine/amplify_stack.ts

View workflow job for this annotation

GitHub Actions / build

Cannot find name 'CfnEleme_cnt'.

Check failure on line 10 in packages/backend/src/engine/amplify_stack.ts

View workflow job for this annotation

GitHub Actions / test_with_baseline_dependencies

Cannot find name 'CfnEleme_cnt'.
// Nested stack logical IDs have a redundant structure of <name>NestedStack<name>NestedStackResource<hash>
// This rewrites the nested stack logical ID to <name><hash>
const defaultId = super.allocateLogicalId(element);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,10 @@ export class ProjectEnvironmentMainStackCreator implements MainStackCreator {
*/
getOrCreateMainStack = (): Stack => {
if (this.mainStack === undefined) {
const backendIdentifierConversions = new BackendIdentifierConversions();
this.mainStack = new AmplifyStack(
this.scope,
BackendIdentifierConversions.toStackName(this.backendId)
backendIdentifierConversions.toStackName(this.backendId)

Check failure on line 28 in packages/backend/src/project_environment_main_stack_creator.ts

View workflow job for this annotation

GitHub Actions / build

Property 'toStackName' does not exist on type 'BackendIdentifierConversions'. Did you mean to access the static member 'BackendIdentifierConversions.toStackName' instead?

Check failure on line 28 in packages/backend/src/project_environment_main_stack_creator.ts

View workflow job for this annotation

GitHub Actions / test_with_baseline_dependencies

Property 'toStackName' does not exist on type 'BackendIdentifierConversions'. Did you mean to access the static member 'BackendIdentifierConversions.toStackName' instead?
);
}

Expand Down

0 comments on commit e4b96a1

Please sign in to comment.