- AWS Serverless (Lambda) function that interacts with UoA ServiceNow
- Build using the Serverless Framework
- Supports unit testing and debugging with Visual Studio Code
- Install Serverless Framework globally
npm install -g serverless
- Install NPM modules
npm install
- To run the tests locally simply execute:
npm start
- Inside Visual Studio Code hit
F5
and selectDebug
as config file. Attach breakpoints as desired.
- To run all unit tests once simply execute:
npm test
- To run all unit tests and have them watch your files for changes:
npm run testw
- To deploy to AWS execute (Note: will only deploy after all unit tests have passed):
npm run deploy
- By default the above command deploys to the
dev
stage - You can optionally pass a
-- --stage STAGE_NAME
flag (Note: the extra--
)
npm run deploy -- --stage=test
- To get information about the currently deployed endpoints, region, stage, layers etc execute:
sls info
sls invoke -f serverless-now
- For general Serverless Framework help run:
sls help
- Serverless Mocha Plugin