@cumulusds/aws-apig-bypass 0.2.2 → 0.2.3
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.
- package/.flowconfig +6 -8
- package/lib/lambda-invoke.js.flow +1 -1
- package/package.json +4 -3
- package/src/lambda-invoke.js +1 -1
- package/test/unit/index.test.js +3 -8
package/.flowconfig
CHANGED
|
@@ -1,14 +1,12 @@
|
|
|
1
1
|
[ignore]
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
[include]
|
|
2
|
+
<PROJECT_ROOT>/node_modules/config-chain/test/broken.json
|
|
3
|
+
<PROJECT_ROOT>/node_modules/license-checker/tests/config/custom_format_broken.json
|
|
4
|
+
<PROJECT_ROOT>/lib
|
|
6
5
|
|
|
7
6
|
[libs]
|
|
7
|
+
node_modules/@cumulusds/flow-aws-sdk/index.js
|
|
8
|
+
node_modules/@cumulusds/flow-aws-sdk/clients
|
|
9
|
+
node_modules/@cumulusds/flow-aws-sdk/lib
|
|
8
10
|
|
|
9
11
|
[lints]
|
|
10
12
|
all=error
|
|
11
|
-
|
|
12
|
-
[options]
|
|
13
|
-
|
|
14
|
-
[strict]
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cumulusds/aws-apig-bypass",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.3",
|
|
4
4
|
"description": "Client for API Gateway handlers, bypassing API Gateway by directly invoking the Lambda",
|
|
5
5
|
"repository": "https://github.com/CumulusDS/aws-apig-bypass",
|
|
6
6
|
"author": "Cumulus Digital Systems",
|
|
@@ -60,7 +60,8 @@
|
|
|
60
60
|
"@babel/plugin-proposal-optional-chaining": "^7.12.7",
|
|
61
61
|
"@babel/preset-env": "^7.0.0",
|
|
62
62
|
"@babel/preset-flow": "^7.0.0",
|
|
63
|
-
"@cumulusds/flow-aws-sdk": "^2.818.
|
|
63
|
+
"@cumulusds/flow-aws-sdk": "^2.818.3",
|
|
64
|
+
"aws-sdk": "^2.977.0",
|
|
64
65
|
"babel-eslint": "10.0.3",
|
|
65
66
|
"babel-jest": "^24.9.0",
|
|
66
67
|
"eslint": "^7.5.0",
|
|
@@ -71,7 +72,7 @@
|
|
|
71
72
|
"eslint-plugin-jest": "^21.15.1",
|
|
72
73
|
"eslint-plugin-prettier": "^2.6.0",
|
|
73
74
|
"flow-aws-lambda": "^1.0.6",
|
|
74
|
-
"flow-bin": "^0.
|
|
75
|
+
"flow-bin": "^0.142.0",
|
|
75
76
|
"flow-copy-source": "^2.0.9",
|
|
76
77
|
"flow-coverage-report": "^0.8.0",
|
|
77
78
|
"flow-typed": "^3.2.1",
|
package/src/lambda-invoke.js
CHANGED
package/test/unit/index.test.js
CHANGED
|
@@ -1,8 +1,5 @@
|
|
|
1
1
|
// @flow
|
|
2
2
|
|
|
3
|
-
import type { Lambda$InvocationResponse } from "@cumulusds/flow-aws-sdk/clients/lambda";
|
|
4
|
-
import type { AWSError } from "@cumulusds/flow-aws-sdk/lib/error";
|
|
5
|
-
import type { Request } from "@cumulusds/flow-aws-sdk/lib/request";
|
|
6
3
|
import type { APIGatewayHandlerClient } from "../../src/create-client";
|
|
7
4
|
import { createAPIGatewayEvent, createClient } from "../../src";
|
|
8
5
|
import { LambdaInvokeError } from "../../src/create-lambda-client";
|
|
@@ -18,12 +15,10 @@ describe("createClient", () => {
|
|
|
18
15
|
// $FlowFixMe
|
|
19
16
|
const resolvedValue: Lambda$InvocationResponse = { StatusCode, Payload, LogResult };
|
|
20
17
|
|
|
21
|
-
// $FlowFixMe[incompatible-
|
|
22
|
-
const
|
|
18
|
+
// $FlowFixMe[incompatible-call]
|
|
19
|
+
const invoke = jest.fn(() => ({
|
|
23
20
|
promise: jest.fn().mockResolvedValue(resolvedValue)
|
|
24
|
-
};
|
|
25
|
-
|
|
26
|
-
const invoke = jest.fn(() => request);
|
|
21
|
+
}));
|
|
27
22
|
const Lambda = {
|
|
28
23
|
invoke
|
|
29
24
|
};
|