@aws-cdk-testing/cli-integ 2.61.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (165) hide show
  1. package/LICENSE +201 -0
  2. package/NOTICE +16 -0
  3. package/README.md +151 -0
  4. package/bin/apply-patches +19 -0
  5. package/bin/download-and-run-old-tests +52 -0
  6. package/bin/query-github +2 -0
  7. package/bin/query-github.d.ts +1 -0
  8. package/bin/query-github.js +55 -0
  9. package/bin/run-suite +2 -0
  10. package/bin/run-suite.d.ts +1 -0
  11. package/bin/run-suite.js +126 -0
  12. package/bin/stage-distribution +2 -0
  13. package/bin/stage-distribution.d.ts +1 -0
  14. package/bin/stage-distribution.js +209 -0
  15. package/bin/test-root +2 -0
  16. package/bin/test-root.d.ts +1 -0
  17. package/bin/test-root.js +6 -0
  18. package/entrypoints/test-cli-regression-against-current-code.sh +11 -0
  19. package/entrypoints/test-cli-regression-against-latest-release.sh +11 -0
  20. package/entrypoints/test-cli-regression.bash +83 -0
  21. package/entrypoints/test.sh +12 -0
  22. package/lib/aws.d.ts +55 -0
  23. package/lib/aws.js +243 -0
  24. package/lib/corking.d.ts +13 -0
  25. package/lib/corking.js +34 -0
  26. package/lib/files.d.ts +15 -0
  27. package/lib/files.js +80 -0
  28. package/lib/github.d.ts +4 -0
  29. package/lib/github.js +43 -0
  30. package/lib/index.d.ts +12 -0
  31. package/lib/index.js +25 -0
  32. package/lib/integ-test.d.ts +11 -0
  33. package/lib/integ-test.js +55 -0
  34. package/lib/lists.d.ts +1 -0
  35. package/lib/lists.js +12 -0
  36. package/lib/memoize.d.ts +6 -0
  37. package/lib/memoize.js +19 -0
  38. package/lib/npm.d.ts +4 -0
  39. package/lib/npm.js +15 -0
  40. package/lib/package-sources/release-source.d.ts +22 -0
  41. package/lib/package-sources/release-source.js +67 -0
  42. package/lib/package-sources/repo-source.d.ts +23 -0
  43. package/lib/package-sources/repo-source.js +92 -0
  44. package/lib/package-sources/repo-tools/npm +2 -0
  45. package/lib/package-sources/repo-tools/npm.d.ts +1 -0
  46. package/lib/package-sources/repo-tools/npm.js +42 -0
  47. package/lib/package-sources/source.d.ts +24 -0
  48. package/lib/package-sources/source.js +3 -0
  49. package/lib/package-sources/subprocess.d.ts +3 -0
  50. package/lib/package-sources/subprocess.js +18 -0
  51. package/lib/resource-pool.d.ts +54 -0
  52. package/lib/resource-pool.js +120 -0
  53. package/lib/resources.d.ts +1 -0
  54. package/lib/resources.js +6 -0
  55. package/lib/shell.d.ts +59 -0
  56. package/lib/shell.js +118 -0
  57. package/lib/staging/codeartifact.d.ts +44 -0
  58. package/lib/staging/codeartifact.js +258 -0
  59. package/lib/staging/maven.d.ts +5 -0
  60. package/lib/staging/maven.js +83 -0
  61. package/lib/staging/npm.d.ts +4 -0
  62. package/lib/staging/npm.js +56 -0
  63. package/lib/staging/nuget.d.ts +4 -0
  64. package/lib/staging/nuget.js +71 -0
  65. package/lib/staging/parallel-shell.d.ts +6 -0
  66. package/lib/staging/parallel-shell.js +46 -0
  67. package/lib/staging/pypi.d.ts +4 -0
  68. package/lib/staging/pypi.js +49 -0
  69. package/lib/staging/usage-dir.d.ts +31 -0
  70. package/lib/staging/usage-dir.js +87 -0
  71. package/lib/with-aws.d.ts +13 -0
  72. package/lib/with-aws.js +60 -0
  73. package/lib/with-cdk-app.d.ts +146 -0
  74. package/lib/with-cdk-app.js +398 -0
  75. package/lib/with-packages.d.ts +5 -0
  76. package/lib/with-packages.js +14 -0
  77. package/lib/with-sam.d.ts +33 -0
  78. package/lib/with-sam.js +240 -0
  79. package/lib/with-temporary-directory.d.ts +5 -0
  80. package/lib/with-temporary-directory.js +32 -0
  81. package/lib/xpmutex.d.ts +43 -0
  82. package/lib/xpmutex.js +207 -0
  83. package/package.json +73 -0
  84. package/resources/cdk-apps/app/app.js +463 -0
  85. package/resources/cdk-apps/app/cdk.json +7 -0
  86. package/resources/cdk-apps/app/docker/Dockerfile +2 -0
  87. package/resources/cdk-apps/app/docker/Dockerfile.Custom +2 -0
  88. package/resources/cdk-apps/app/lambda/index.js +4 -0
  89. package/resources/cdk-apps/app/lambda/response.json +3 -0
  90. package/resources/cdk-apps/app/nested-stack.js +49 -0
  91. package/resources/cdk-apps/cfn-include-app/.gitignore +1 -0
  92. package/resources/cdk-apps/cfn-include-app/cdk.json +4 -0
  93. package/resources/cdk-apps/cfn-include-app/cfn-include-app.js +21 -0
  94. package/resources/cdk-apps/cfn-include-app/example-template.json +13 -0
  95. package/resources/cdk-apps/sam_cdk_integ_app/bin/test-app.js +11 -0
  96. package/resources/cdk-apps/sam_cdk_integ_app/cdk.json +6 -0
  97. package/resources/cdk-apps/sam_cdk_integ_app/lib/nested-stack.js +19 -0
  98. package/resources/cdk-apps/sam_cdk_integ_app/lib/test-stack.js +134 -0
  99. package/resources/cdk-apps/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/.no-packagejson-validator +0 -0
  100. package/resources/cdk-apps/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/Dockerfile +9 -0
  101. package/resources/cdk-apps/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/app.js +22 -0
  102. package/resources/cdk-apps/sam_cdk_integ_app/src/docker/DockerImageFunctionConstruct/package.json +18 -0
  103. package/resources/cdk-apps/sam_cdk_integ_app/src/go/GoFunctionConstruct/go.mod +5 -0
  104. package/resources/cdk-apps/sam_cdk_integ_app/src/go/GoFunctionConstruct/go.sum +17 -0
  105. package/resources/cdk-apps/sam_cdk_integ_app/src/go/GoFunctionConstruct/main.go +17 -0
  106. package/resources/cdk-apps/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/.no-packagejson-validator +0 -0
  107. package/resources/cdk-apps/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/app.ts +16 -0
  108. package/resources/cdk-apps/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/package-lock.json +12 -0
  109. package/resources/cdk-apps/sam_cdk_integ_app/src/nodejs/NodeJsFunctionConstruct/package.json +5 -0
  110. package/resources/cdk-apps/sam_cdk_integ_app/src/python/Function/app.py +15 -0
  111. package/resources/cdk-apps/sam_cdk_integ_app/src/python/Function/requirements.txt +1 -0
  112. package/resources/cdk-apps/sam_cdk_integ_app/src/python/Layer/layer_version_dependency.py +5 -0
  113. package/resources/cdk-apps/sam_cdk_integ_app/src/python/Layer/requirements.txt +1 -0
  114. package/resources/cdk-apps/sam_cdk_integ_app/src/rest-api-definition.yaml +12 -0
  115. package/resources/cli-regression-patches/v1.119.0/NOTES.md +5 -0
  116. package/resources/cli-regression-patches/v1.119.0/cli.integtest.js +659 -0
  117. package/resources/cli-regression-patches/v1.130.0/NOTES.md +12 -0
  118. package/resources/cli-regression-patches/v1.130.0/app/app.js +378 -0
  119. package/resources/cli-regression-patches/v1.130.0/bootstrapping.integtest.js +220 -0
  120. package/resources/cli-regression-patches/v1.44.0/NOTES.md +18 -0
  121. package/resources/cli-regression-patches/v1.44.0/bootstrapping.integtest.js +126 -0
  122. package/resources/cli-regression-patches/v1.44.0/test.sh +26 -0
  123. package/resources/cli-regression-patches/v1.61.1/NOTES.md +2 -0
  124. package/resources/cli-regression-patches/v1.61.1/skip-tests.txt +16 -0
  125. package/resources/cli-regression-patches/v1.62.0/NOTES.md +2 -0
  126. package/resources/cli-regression-patches/v1.62.0/aws-helpers.js +245 -0
  127. package/resources/cli-regression-patches/v1.63.0/NOTES.md +1 -0
  128. package/resources/cli-regression-patches/v1.63.0/skip-tests.txt +7 -0
  129. package/resources/cli-regression-patches/v1.64.0/NOTES.md +3 -0
  130. package/resources/cli-regression-patches/v1.64.0/cdk-helpers.js +325 -0
  131. package/resources/cli-regression-patches/v1.64.0/cli.integtest.js +599 -0
  132. package/resources/cli-regression-patches/v1.64.1/NOTES.md +3 -0
  133. package/resources/cli-regression-patches/v1.64.1/cdk-helpers.js +324 -0
  134. package/resources/cli-regression-patches/v1.64.1/cli.integtest.js +599 -0
  135. package/resources/cli-regression-patches/v1.67.0/NOTES.md +2 -0
  136. package/resources/cli-regression-patches/v1.67.0/cdk-helpers.js +331 -0
  137. package/resources/cloud-assemblies/0.36.0/InitStack.template.json +1 -0
  138. package/resources/cloud-assemblies/0.36.0/manifest.json +19 -0
  139. package/resources/cloud-assemblies/1.10.0-lookup-default-vpc/InitStack.template.json +2 -0
  140. package/resources/cloud-assemblies/1.10.0-lookup-default-vpc/manifest.json.js +37 -0
  141. package/resources/cloud-assemblies/1.10.0-request-azs/InitStack.template.json +2 -0
  142. package/resources/cloud-assemblies/1.10.0-request-azs/manifest.json.js +34 -0
  143. package/resources/integ.jest.config.js +25 -0
  144. package/skip-tests.txt +8 -0
  145. package/tests/cli-integ-tests/README.md +47 -0
  146. package/tests/cli-integ-tests/bootstrapping.integtest.d.ts +1 -0
  147. package/tests/cli-integ-tests/bootstrapping.integtest.js +271 -0
  148. package/tests/cli-integ-tests/cli.integtest.d.ts +1 -0
  149. package/tests/cli-integ-tests/cli.integtest.js +1029 -0
  150. package/tests/init-csharp/init-csharp.integtest.d.ts +1 -0
  151. package/tests/init-csharp/init-csharp.integtest.js +14 -0
  152. package/tests/init-fsharp/init-fsharp.integtest.d.ts +1 -0
  153. package/tests/init-fsharp/init-fsharp.integtest.js +14 -0
  154. package/tests/init-java/init-java.integtest.d.ts +1 -0
  155. package/tests/init-java/init-java.integtest.js +14 -0
  156. package/tests/init-javascript/init-javascript.integtest.d.ts +1 -0
  157. package/tests/init-javascript/init-javascript.integtest.js +15 -0
  158. package/tests/init-python/init-python.integtest.d.ts +1 -0
  159. package/tests/init-python/init-python.integtest.js +19 -0
  160. package/tests/init-typescript-app/init-typescript-app.integtest.d.ts +1 -0
  161. package/tests/init-typescript-app/init-typescript-app.integtest.js +49 -0
  162. package/tests/init-typescript-lib/init-typescript-lib.integtest.d.ts +1 -0
  163. package/tests/init-typescript-lib/init-typescript-lib.integtest.js +13 -0
  164. package/tests/uberpackage/uberpackage.integtest.d.ts +1 -0
  165. package/tests/uberpackage/uberpackage.integtest.js +11 -0
@@ -0,0 +1,134 @@
1
+ var path = require('path');
2
+ var { NestedStack1 } = require('./nested-stack');
3
+ if (process.env.PACKAGE_LAYOUT_VERSION === '1') {
4
+ var { Stack } = require('@aws-cdk/core');
5
+ var { Runtime, LayerVersion, Code, Function, DockerImageFunction, DockerImageCode } = require('@aws-cdk/aws-lambda');
6
+ var { SpecRestApi, ApiDefinition } = require('@aws-cdk/aws-apigateway');
7
+ var { NodejsFunction } = require('@aws-cdk/aws-lambda-nodejs');
8
+ var { GoFunction } = require('@aws-cdk/aws-lambda-go');
9
+ var { PythonFunction, PythonLayerVersion } = require('@aws-cdk/aws-lambda-python');
10
+ var { Role, ServicePrincipal, PolicyStatement } = require('@aws-cdk/aws-iam');
11
+ var { RetentionDays } = require('@aws-cdk/aws-logs');
12
+ } else {
13
+ var { Stack } = require('aws-cdk-lib');
14
+ var { Runtime, LayerVersion, Code, Function, DockerImageFunction, DockerImageCode } = require('aws-cdk-lib/aws-lambda');
15
+ var { SpecRestApi, ApiDefinition } = require('aws-cdk-lib/aws-apigateway');
16
+ var { NodejsFunction } = require('aws-cdk-lib/aws-lambda-nodejs');
17
+ var { GoFunction } = require('@aws-cdk/aws-lambda-go-alpha');
18
+ var { PythonFunction, PythonLayerVersion } = require('@aws-cdk/aws-lambda-python-alpha');
19
+ var { Role, ServicePrincipal, PolicyStatement } = require('aws-cdk-lib/aws-iam');
20
+ var { RetentionDays } = require('aws-cdk-lib/aws-logs');
21
+ }
22
+
23
+ const isRunningOnCodeBuild = !!process.env.CODEBUILD_BUILD_ID;
24
+
25
+ class CDKSupportDemoRootStack extends Stack{
26
+ constructor(scope, id, props) {
27
+ super(scope, id, props);
28
+ // Python Runtime
29
+ // Layers
30
+ new PythonLayerVersion(this, 'PythonLayerVersion', {
31
+ compatibleRuntimes: [
32
+ Runtime.PYTHON_3_7,
33
+ ],
34
+ entry: './src/python/Layer',
35
+ });
36
+ new LayerVersion(this, 'LayerVersion', {
37
+ compatibleRuntimes: [
38
+ Runtime.PYTHON_3_7,
39
+ ],
40
+ code: Code.fromAsset('./src/python/Layer'),
41
+ });
42
+ new LayerVersion(this, 'BundledLayerVersionPythonRuntime', {
43
+ compatibleRuntimes: [
44
+ Runtime.PYTHON_3_7,
45
+ ],
46
+ code: Code.fromAsset('./src/python/Layer', {
47
+ bundling: {
48
+ command: [
49
+ '/bin/sh',
50
+ '-c',
51
+ 'rm -rf /tmp/asset-input && mkdir /tmp/asset-input && cp * /tmp/asset-input && cd /tmp/asset-input && pip install -r requirements.txt -t . && mkdir /asset-output/python && cp -R /tmp/asset-input/* /asset-output/python',
52
+ ],
53
+ image: Runtime.PYTHON_3_7.bundlingImage,
54
+ user: 'root',
55
+ }
56
+ }),
57
+ });
58
+
59
+ // ZIP package type Functions
60
+ new PythonFunction(this, 'PythonFunction', {
61
+ entry: './src/python/Function',
62
+ index: 'app.py',
63
+ handler: 'lambda_handler',
64
+ runtime: Runtime.PYTHON_3_7,
65
+ functionName: 'pythonFunc',
66
+ logRetention: RetentionDays.THREE_MONTHS,
67
+ });
68
+ new Function(this, 'FunctionPythonRuntime', {
69
+ runtime: Runtime.PYTHON_3_7,
70
+ code: Code.fromAsset('./src/python/Function'),
71
+ handler: 'app.lambda_handler',
72
+ });
73
+ new Function(this, 'BundledFunctionPythonRuntime', {
74
+ runtime: Runtime.PYTHON_3_7,
75
+ code: Code.fromAsset('./src/python/Function/', {
76
+ bundling: {
77
+ command: [
78
+ '/bin/sh',
79
+ '-c',
80
+ 'rm -rf /tmp/asset-input && mkdir /tmp/asset-input && cp * /tmp/asset-input && cd /tmp/asset-input && pip install -r requirements.txt -t . && cp -R /tmp/asset-input/* /asset-output',
81
+ ],
82
+ image: Runtime.PYTHON_3_7.bundlingImage,
83
+ user: 'root',
84
+ }
85
+ }),
86
+ handler: 'app.lambda_handler',
87
+ });
88
+
89
+ // NodeJs Runtime
90
+ new NodejsFunction(this, 'NodejsFunction', {
91
+ entry: path.join(__dirname, '../src/nodejs/NodeJsFunctionConstruct/app.ts'),
92
+ depsLockFilePath: path.join(__dirname, '../src/nodejs/NodeJsFunctionConstruct/package-lock.json'),
93
+ bundling: {
94
+ forceDockerBundling: true,
95
+ },
96
+ handler: 'lambdaHandler',
97
+ });
98
+
99
+ // Go Runtime
100
+ new GoFunction(this, 'GoFunction', {
101
+ entry: './src/go/GoFunctionConstruct',
102
+ bundling: {
103
+ forcedDockerBundling: true,
104
+ // Only use Google proxy in the CI tests, as it is blocked on workstations
105
+ goProxies: isRunningOnCodeBuild ? [GoFunction.GOOGLE_GOPROXY, 'direct'] : undefined,
106
+ },
107
+ });
108
+
109
+ // Image Package Type Functions
110
+ new DockerImageFunction(this, 'DockerImageFunction', {
111
+ code: DockerImageCode.fromImageAsset('./src/docker/DockerImageFunctionConstruct', {
112
+ file: 'Dockerfile',
113
+ }),
114
+ });
115
+
116
+ // Spec Rest Api
117
+ new SpecRestApi(this, 'SpecRestAPI', {
118
+ apiDefinition: ApiDefinition.fromAsset('./src/rest-api-definition.yaml'),
119
+ });
120
+ // Role to be used as credentials for the Spec rest APi
121
+ // it is used inside the spec rest api definition file
122
+ new Role(this, 'SpecRestApiRole', {
123
+ assumedBy: new ServicePrincipal('apigateway.amazonaws.com'),
124
+ roleName: 'SpecRestApiRole',
125
+ }).addToPolicy(new PolicyStatement({
126
+ actions: ['lambda:InvokeFunction'],
127
+ resources: ['*'],
128
+ }));
129
+
130
+ // Nested Stack
131
+ new NestedStack1(this, 'NestedStack', {});
132
+ }
133
+ }
134
+ exports.CDKSupportDemoRootStack = CDKSupportDemoRootStack;
@@ -0,0 +1,9 @@
1
+ FROM public.ecr.aws/lambda/nodejs:14
2
+
3
+ # Assumes your function is named "app.js", and there is a package.json file in the app directory
4
+ COPY app.js package.json ./
5
+
6
+ RUN npm install
7
+
8
+ # Set the CMD to your handler (could also be done as a parameter override outside of the Dockerfile)
9
+ CMD [ "app.lambdaHandler" ]
@@ -0,0 +1,22 @@
1
+ var gen = require('unique-names-generator');
2
+
3
+ const colorName = gen.uniqueNamesGenerator({
4
+ dictionaries: [gen.colors]
5
+ });
6
+
7
+ exports.lambdaHandler = async(event, context) => {
8
+ let response;
9
+
10
+ try {
11
+ response = {
12
+ 'statusCode': 200,
13
+ 'body': JSON.stringify({
14
+ message: "Hello World",
15
+ })
16
+ };
17
+ } catch (err) {
18
+ console.log(err);
19
+ return err;
20
+ }
21
+ return response;
22
+ };
@@ -0,0 +1,18 @@
1
+ {
2
+ "name": "DockerImageFunctionConstruct",
3
+ "description": "testing docker lambda function ",
4
+ "version": "0.1.0",
5
+ "bin": {
6
+ "randomColors": "bin/app.js"
7
+ },
8
+ "scripts": {
9
+ "build": "tsc",
10
+ "watch": "tsc -w",
11
+ "test": "jest",
12
+ "cdk": "cdk"
13
+ },
14
+ "license": "Apache-2.0",
15
+ "dependencies": {
16
+ "unique-names-generator": "^4.6.0"
17
+ }
18
+ }
@@ -0,0 +1,5 @@
1
+ require github.com/aws/aws-lambda-go v1.28.0
2
+
3
+ module hello-world
4
+
5
+ go 1.15
@@ -0,0 +1,17 @@
1
+ github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
2
+ github.com/aws/aws-lambda-go v1.28.0 h1:fZiik1PZqW2IyAN4rj+Y0UBaO1IDFlsNo9Zz/XnArK4=
3
+ github.com/aws/aws-lambda-go v1.28.0/go.mod h1:jJmlefzPfGnckuHdXX7/80O3BvUUi12XOkbv4w9SGLU=
4
+ github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU=
5
+ github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU=
6
+ github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
7
+ github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
8
+ github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
9
+ github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
10
+ github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc=
11
+ github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
12
+ github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
13
+ github.com/urfave/cli/v2 v2.2.0/go.mod h1:SE9GqnLQmjVa0iPEY0f1w3ygNIYcIJ0OKPMoW2caLfQ=
14
+ gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
15
+ gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
16
+ gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
17
+ gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
@@ -0,0 +1,17 @@
1
+ package main
2
+
3
+ import (
4
+ "github.com/aws/aws-lambda-go/events"
5
+ "github.com/aws/aws-lambda-go/lambda"
6
+ )
7
+
8
+ func handler(request events.APIGatewayProxyRequest) (events.APIGatewayProxyResponse, error) {
9
+ return events.APIGatewayProxyResponse{
10
+ Body: "{\"message\": \"Hello World\"}",
11
+ StatusCode: 200,
12
+ }, nil
13
+ }
14
+
15
+ func main() {
16
+ lambda.Start(handler)
17
+ }
@@ -0,0 +1,16 @@
1
+ let response;
2
+
3
+ exports.lambdaHandler = async(event, context) => {
4
+ try {
5
+ response = {
6
+ 'statusCode': 200,
7
+ 'body': JSON.stringify({
8
+ message: `Hello World`,
9
+ })
10
+ };
11
+ } catch (err) {
12
+ console.log(err);
13
+ return err;
14
+ }
15
+ return response;
16
+ };
@@ -0,0 +1,12 @@
1
+ {
2
+ "name": "hello_world",
3
+ "version": "1.0.0",
4
+ "lockfileVersion": 2,
5
+ "requires": true,
6
+ "packages": {
7
+ "": {
8
+ "name": "hello_world",
9
+ "version": "1.0.0"
10
+ }
11
+ }
12
+ }
@@ -0,0 +1,5 @@
1
+ {
2
+ "name": "hello_world",
3
+ "version": "1.0.0",
4
+ "main": "app.js"
5
+ }
@@ -0,0 +1,15 @@
1
+ from geonamescache import GeonamesCache
2
+ import json
3
+
4
+
5
+ def lambda_handler(event, context):
6
+
7
+ response = {
8
+ "statusCode": 200,
9
+ "body": json.dumps(
10
+ {
11
+ "message": "Hello World",
12
+ }
13
+ ),
14
+ }
15
+ return response
@@ -0,0 +1,5 @@
1
+ from geonamescache import GeonamesCache
2
+
3
+
4
+ def get_dependency():
5
+ return 5
@@ -0,0 +1,12 @@
1
+ openapi: '3.0.2'
2
+ info:
3
+ title: API Gateway IP Filtering Example API
4
+
5
+ paths:
6
+ "/restapis/spec/pythonFunction":
7
+ get:
8
+ x-amazon-apigateway-integration:
9
+ httpMethod: POST
10
+ type: AWS_PROXY
11
+ uri: arn:${AWS::Partition}:apigateway:${AWS::Region}:lambda:path/2015-03-31/functions/arn:${AWS::Partition}:lambda:${AWS::Region}:${AWS::AccountId}:function:pythonFunc:$LATEST/invocations
12
+ credentials: arn:${AWS::Partition}:iam::${AWS::AccountId}:role/SpecRestApiRole
@@ -0,0 +1,5 @@
1
+ This [PR](https://github.com/aws/aws-cdk/pull/16205) added a node version check to our CLI courtesy of [`@jsii/check-node/run`](https://github.com/aws/jsii/tree/main/packages/%40jsii/check-node).
2
+
3
+ This check now causes the CLI to print a deprecation warning that changes the output of the `synth` command. We don't consider this a breaking change since we have no guarantess for CLI output, but it did break some our integ tests (namely `cdk synth`) that used to rely on a specific output.
4
+
5
+ This patch brings the [fix](https://github.com/aws/aws-cdk/pull/16216) into the regression suite.