Skip to content

Commit

Permalink
add unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
badmintoncryer committed Sep 10, 2024
1 parent eb1f1be commit 9fd9bad
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions packages/aws-cdk-lib/aws-apigatewayv2/test/http/api.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -234,6 +234,19 @@ describe('HttpApi', () => {
});
});

test('routeSelectionExpression is enabled', () => {
const stack = new Stack();
new HttpApi(stack, 'api', {
routeSelectionExpression: true,
});

Template.fromStack(stack).hasResourceProperties('AWS::ApiGatewayV2::Api', {
Name: 'api',
ProtocolType: 'HTTP',
RouteSelectionExpression: '$request.method $request.path',
});
});

test('can add a vpc links', () => {
// GIVEN
const stack = new Stack();
Expand Down

0 comments on commit 9fd9bad

Please sign in to comment.