summaryrefslogtreecommitdiff
path: root/test/ruby
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-05-07 13:24:55 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-05-07 13:24:55 +0000
commit10f263c10e8a22dfad49a573a87810416b53f4fa (patch)
treecf7ac9993a3155bb992e063238c34c144973c093 /test/ruby
parent98ad27497471cc85cb249ffd7693cd5547c886d5 (diff)
* numeric.c (bit_coerce): float should not be a valid operand of
bitwise operations. [ruby-dev:34583] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16316 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ruby')
-rw-r--r--test/ruby/test_numeric.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/ruby/test_numeric.rb b/test/ruby/test_numeric.rb
index 584139a7f8..b1edb8fe47 100644
--- a/test/ruby/test_numeric.rb
+++ b/test/ruby/test_numeric.rb
@@ -201,9 +201,9 @@ class TestNumeric < Test::Unit::TestCase
def test_num2long
assert_raise(TypeError) { 1 & nil }
- assert_equal(1, 1 & 1.0)
- assert_equal(0, 1 & 2147483648.0)
- assert_equal(0, 1 & 9223372036854777856.0)
+ assert_raise(TypeError) { 1 & 1.0 }
+ assert_raise(TypeError) { 1 & 2147483648.0 }
+ assert_raise(TypeError) { 1 & 9223372036854777856.0 }
o = Object.new
def o.to_int; 1; end
assert_equal(1, 1 & o)