aws-lambda-helper
Advanced tools
Comparing version 2.21.0 to 2.22.0
@@ -389,2 +389,3 @@ 'use strict'; | ||
params2.items = results; | ||
params2.provider = AwsHelper._context.functionName; | ||
pushToSNSTopic(params2, function (err, data) { | ||
@@ -391,0 +392,0 @@ if (err) { |
{ | ||
"name": "aws-lambda-helper", | ||
"version": "2.21.0", | ||
"version": "2.22.0", | ||
"description": "Collection of helper methods for lambda", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
@@ -11,3 +11,4 @@ // this test needs to run *FIRST* for some reason ... any help figuring out why much appreciated. | ||
AwsHelper.init({ | ||
invokedFunctionArn: process.env.INVOKED_FUNCTION_ARN | ||
invokedFunctionArn: process.env.INVOKED_FUNCTION_ARN, | ||
functionName: 'test-lambda' | ||
}); | ||
@@ -40,9 +41,8 @@ done(); | ||
}; | ||
const expected = JSON.stringify({ | ||
default: JSON.stringify(params) | ||
}); | ||
const expected = Object.assign({ provider: 'test-lambda' }, params); | ||
AwsHelper.pushResultToClient(params, function (err) { | ||
assert(!err); | ||
assert.equal(AWS.SNS.prototype.publish.callCount, 1); | ||
assert.equal(AWS.SNS.prototype.publish.calls[0].args[0].Message, expected); | ||
const message = JSON.parse(JSON.parse(AWS.SNS.prototype.publish.calls[0].args[0].Message).default); | ||
assert.deepEqual(message, expected); | ||
done(); | ||
@@ -49,0 +49,0 @@ }); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
203501
30
1658