Sha256: 55885ef33ea37dc4a27b35f5475a3ba4fcd32867e0da316fc53b15450fd6a4da
Contents?: true
Size: 380 Bytes
Versions: 9
Compression:
Stored size: 380 Bytes
Contents
def describe_private *args, &block example = describe *args, &block klass = args[0] if klass.is_a? Class saved_private_instance_methods = klass.private_instance_methods example.before do klass.class_eval { public *saved_private_instance_methods } end example.after do klass.class_eval { private *saved_private_instance_methods } end end end
Version data entries
9 entries across 9 versions & 1 rubygems