Corrected the check for the existence of jasmine

- The check `if(! jasmine)` throws a [ReferenceError](https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/ReferenceError)
- Javascript doesn't have an `Exception` object, instead it has an [Error](https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Error) object