Skip to content

Instantly share code, notes, and snippets.

@greyblake
Created July 9, 2013 15:02
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save greyblake/5958083 to your computer and use it in GitHub Desktop.
Save greyblake/5958083 to your computer and use it in GitHub Desktop.
# Override some stuff to detect FacotoryGirl usage out of `it`
module RSpec
module Core
class ExampleGroup
class << self
# redefine to do nothing
def it(*args)
end
end
end
end
end
def FactoryGirl.create(*args)
puts "\n\n==="
puts "Crime detected"
puts caller[0]
puts "===\n\n"
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment