Skip to content

Instantly share code, notes, and snippets.

🤔
Looking for productive ways to have fun

musicin3d

🤔
Looking for productive ways to have fun
View GitHub Profile
@musicin3d
musicin3d / testUtil.js
Last active Feb 18, 2018
Test case utility for supertests, featuring a dirty monkey patch for printing response body when expect() fails.
View testUtil.js
/*
* Inspired by a patch by github.com/RyanMcDonald.
* https://github.com/visionmedia/supertest/issues/367#issuecomment-250627577
* No rights reserved. :)
*/
const request = require('supertest')
let oldAssertStatus = null
You can’t perform that action at this time.