Created
May 5, 2017 18:52
-
-
Save richardhyatt/fcfa566900abf2d9b2ca6b1b78bb6abe to your computer and use it in GitHub Desktop.
Unit Testing AWS Lambda Functions in Node.js #1
This file contains hidden or 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’; | |
| exports.handler = function( event, context, callback ) { | |
| if( (event.name === ‘Richard’) || (event.name === ‘rhyatt’ ) ) { | |
| return callback( null, { valid: true } ); | |
| } | |
| callback( new Error( ‘unknown name’ ) ); | |
| }; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment