Skip to content

Instantly share code, notes, and snippets.

@booo
Created September 26, 2011 11:30
Show Gist options
  • Select an option

  • Save booo/1242057 to your computer and use it in GitHub Desktop.

Select an option

Save booo/1242057 to your computer and use it in GitHub Desktop.
sinon = require "sinon"
assert = require "assert"
fn = ->
console.log "called..."
spy = sinon.spy fn
fn()
assert.ok spy.called
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment