handle exceptions
Add javascript jazmine framework to test the API
first jasmine test running successfully