Method: MethodSequenceChecker#its_ok_watcher_proc
- Defined in:
- lib/pippi/checks/method_sequence_checker.rb
#its_ok_watcher_proc(clazz, method_name) ⇒ Object
76 77 78 79 80 81 82 83 84 85 86 |
# File 'lib/pippi/checks/method_sequence_checker.rb', line 76 def its_ok_watcher_proc(clazz, method_name) proc do |*args, &blk| begin singleton_class.ancestors.find { |x| x == clazz }.instance_eval { remove_method method_name } rescue NameError return super(*args, &blk) else return super(*args, &blk) end end end |