Advertisement
Guest User

Untitled

a guest
Mar 31st, 2015
264
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.62 KB | None | 0 0
  1. # WARNING:
  2. # Horrible things happening here for development reasons.
  3. # Do not leave this in.
  4. require 'colorize'
  5.  
  6. module Zing
  7. module PlayerRecommender
  8. class Todo
  9. def self.warn
  10. str ||= ''
  11. caller_locations(2, 1).first.tap do |loc|
  12. puts "#{loc.label}".green.bold + " mocked but not implemented!!!!111:".red.bold
  13. puts " #{loc.path}:#{loc.lineno}".red
  14. end
  15. end
  16. end
  17. end
  18. end
  19.  
  20. class Object
  21. def fake_return(output)
  22. Zing::PlayerRecommender::Todo.warn
  23. return output
  24. end
  25.  
  26. def self.fake_return(output)
  27. Zing::PlayerRecommender::Todo.warn
  28. return output
  29. end
  30. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement