Sha256: 021f8a0ecae03cd478015b629181d12b2ec7b6b6d4b662273b222aa655eafae6
Contents?: true
Size: 318 Bytes
Versions: 6
Compression:
Stored size: 318 Bytes
Contents
require File.expand_path(File.dirname(__FILE__) + '/../spec_helper') describe Array do it "should define rand, a way to get a random variable from an array" do a = [1,2] a.should be_include(a.rand) # 9.31322574615479e-10 chance of failing 30.times.map {a.rand}.uniq.sort.should eql([1,2]) end end
Version data entries
6 entries across 6 versions & 1 rubygems