{"action":"created","issue":{"url":"https://api.github.com/repos/jasmine/jasmine-npm/issues/31","labels_url":"https://api.github.com/repos/jasmine/jasmine-npm/issues/31/labels{/name}","comments_url":"https://api.github.com/repos/jasmine/jasmine-npm/issues/31/comments","events_url":"https://api.github.com/repos/jasmine/jasmine-npm/issues/31/events","html_url":"https://github.com/jasmine/jasmine-npm/issues/31","id":58840224,"number":31,"title":"Jasmine + Supertest","user":{"login":"svileng","id":351592,"avatar_url":"https://avatars.githubusercontent.com/u/351592?v=3","gravatar_id":"","url":"https://api.github.com/users/svileng","html_url":"https://github.com/svileng","followers_url":"https://api.github.com/users/svileng/followers","following_url":"https://api.github.com/users/svileng/following{/other_user}","gists_url":"https://api.github.com/users/svileng/gists{/gist_id}","starred_url":"https://api.github.com/users/svileng/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/svileng/subscriptions","organizations_url":"https://api.github.com/users/svileng/orgs","repos_url":"https://api.github.com/users/svileng/repos","events_url":"https://api.github.com/users/svileng/events{/privacy}","received_events_url":"https://api.github.com/users/svileng/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-02-25T02:22:00Z","updated_at":"2015-02-26T03:27:10Z","closed_at":null,"body":"I'm using [supertest](http://github.com/visionmedia/supertest) for testing Express applications. I found that `jasmine` totally breaks `supertest`'s expect matchers — there are no errors, everything just passes with green, even when the assertion is false. When I replaced `jasmine` with `mocha`, `supertest` started working as expected.\r\n\r\n```\r\n\"express\": \"^4.11.2\",\r\n\"supertest\": \"^0.15.0\"`\r\n```"},"comment":{"url":"https://api.github.com/repos/jasmine/jasmine-npm/issues/comments/76116202","html_url":"https://github.com/jasmine/jasmine-npm/issues/31#issuecomment-76116202","issue_url":"https://api.github.com/repos/jasmine/jasmine-npm/issues/31","id":76116202,"user":{"login":"amavisca","id":1253724,"avatar_url":"https://avatars.githubusercontent.com/u/1253724?v=3","gravatar_id":"","url":"https://api.github.com/users/amavisca","html_url":"https://github.com/amavisca","followers_url":"https://api.github.com/users/amavisca/followers","following_url":"https://api.github.com/users/amavisca/following{/other_user}","gists_url":"https://api.github.com/users/amavisca/gists{/gist_id}","starred_url":"https://api.github.com/users/amavisca/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/amavisca/subscriptions","organizations_url":"https://api.github.com/users/amavisca/orgs","repos_url":"https://api.github.com/users/amavisca/repos","events_url":"https://api.github.com/users/amavisca/events{/privacy}","received_events_url":"https://api.github.com/users/amavisca/received_events","type":"User","site_admin":false},"created_at":"2015-02-26T03:27:10Z","updated_at":"2015-02-26T03:27:10Z","body":"I assume it's the done callback.\r\n\r\nThe done function in jasmine doesn't take an error argument. You can pass an error argument to done.fail. The example on supertest's README using jasmine would be:\r\n\r\n```\r\nvar request = require('supertest')\r\n  , express = require('express');\r\n\r\nvar app = express();\r\n\r\napp.get('/user', function(req, res){\r\n  res.send(200, { name: 'tobi' });\r\n});\r\n\r\ndescribe('GET /users', function(){\r\n  it('respond with json', function(done){\r\n    request(app)\r\n      .get('/user')\r\n      .set('Accept', 'application/json')\r\n      .expect('Content-Type', /json/)\r\n      .expect(200, done.fail);\r\n  })\r\n})\r\n```"}}