webrat/lib/webrat/core_extensions/deprecate.rb
Bryan Helmkamp 03914fd293 Whitespace
2009-04-07 20:30:12 -04:00

9 lines
260 B
Ruby

class Module #:nodoc:
def webrat_deprecate(old_method_name, new_method_name)
define_method old_method_name do |*args|
warn "#{old_method_name} is deprecated. Use #{new_method_name} instead."
__send__(new_method_name, *args)
end
end
end