Sha256: 7ea55882ba7836bbcfe05687f2ff1c1e4fd1c19d09db6cd82fabac3381a02acb
Contents?: true
Size: 318 Bytes
Versions: 5
Compression:
Stored size: 318 Bytes
Contents
require 'stubba/class_method' module Stubba class InstanceMethod < ClassMethod def stub raise cannot_replace_method_error unless exists? define_new_method end def unstub # intentionally empty end def exists? object.respond_to?(method) end end end
Version data entries
5 entries across 5 versions & 1 rubygems