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 9, 2024
1 parent 9dac180 commit dba7fc4
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 dba7fc4

Please sign in to comment.