Fix issues with calling notification handlers (and add tests)

Fixes issues with calling notification handlers:
- Parameters passed to TraceKit.report() didn't get passed to notification
  handlers (unless the exception was swallowed and window.onerror didn't get
  called).
- Notification handlers for TraceKit.report() didn't get called at all when
  TraceKit.collectWindowErrors was set to false (unless the exception was
  swallowed, window.onerror didn't get called, and a second call to
  TraceKit.report() was made).

Also adds tests for the above, along with a grunt task to run them from the command line.