summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-02-24 07:48:31 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-02-24 07:48:31 +0000
commit9e0683523ac1a995b9c30c94115d2cb66f2d76bb (patch)
tree8529aa46c86f6ada13e243d08d218fc1145bb8c8
parentd64c926eba3a317f4756e048d2ef7522c463636d (diff)
test_array.rb: fix test for r39466
* test/ruby/test_array.rb (test_sample_random): remove adjustment for the bug fixed by r39466. [ruby-core:52779] [Bug #7935] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39470 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--test/ruby/test_array.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/ruby/test_array.rb b/test/ruby/test_array.rb
index 3ab0895f8c6..17f2ef66c44 100644
--- a/test/ruby/test_array.rb
+++ b/test/ruby/test_array.rb
@@ -2055,14 +2055,14 @@ class TestArray < Test::Unit::TestCase
ary = (0...10000).to_a
assert_raise(ArgumentError) {ary.sample(1, 2, random: nil)}
gen0 = proc do |max|
- (max+1)/2
+ max/2
end
class << gen0
alias rand call
end
gen1 = proc do |max|
ary.replace([])
- (max+1)/2
+ max/2
end
class << gen1
alias rand call