Created
August 28, 2017 11:19
-
-
Save petebarber/ea4f0e41cbd7d764993db842e1afd4e5 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
const assert = require("assert"); | |
const sinon = require("sinon"); | |
const aws = require("aws-sdk"); | |
const spawn = require("child_process").spawn; | |
aws.config.update({region: "us-east-1" }); | |
describe("awsLambdaToTest", function() | |
{ | |
let dynamoInstance; | |
let db; | |
beforeEach(function() | |
{ | |
dynamoInstance = spawn('/usr/local/bin/dynamodb-local', ['-inMemory']); | |
db = new aws.DynamoDB({ endpoint: "http://localhost:8000" }); | |
}); | |
afterEach(() => dynamoInstance.kill()); | |
// Tests... | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment