Sha256: 2f36b2671861a79a0a5b822407c15cd540dacbf9aca77ec54f7cd29dd2e53fd8
Contents?: true
Size: 798 Bytes
Versions: 1
Compression:
Stored size: 798 Bytes
Contents
require_relative '../../spec_helper' class Empty end class MyClass attr_accessor :stuff end describe Object do describe '#deep_clone' do it 'returns a deep copy of the object' do a = [ [1,2] ] b = a.deep_clone a[0] << 3 b.should == [ [1,2] ] end end describe '#realsize' do context 'when the class has instance variables' do it 'returns an integer > 0' do s = MyClass.new s.stuff = 'my stuff' s.realsize.should > 0 end end context 'when the class has instance variables' do it 'returns nil' do s = Empty.new s.realsize.should == 0 end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
arachni-0.4.2 | spec/arachni/ruby/object_spec.rb |