diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/soap/calc/test_calc_cgi.rb | 2 | ||||
-rw-r--r-- | test/soap/marshal/test_marshal.rb | 23 |
2 files changed, 23 insertions, 2 deletions
diff --git a/test/soap/calc/test_calc_cgi.rb b/test/soap/calc/test_calc_cgi.rb index d1c85fe042..523379f302 100644 --- a/test/soap/calc/test_calc_cgi.rb +++ b/test/soap/calc/test_calc_cgi.rb @@ -57,7 +57,7 @@ class TestCalcCGI < Test::Unit::TestCase @calc.reset_stream end - def test_calc + def test_calc_cgi assert_equal(3, @calc.add(1, 2)) assert_equal(-1.1, @calc.sub(1.1, 2.2)) assert_equal(2.42, @calc.multi(1.1, 2.2)) diff --git a/test/soap/marshal/test_marshal.rb b/test/soap/marshal/test_marshal.rb index cfdab39ab2..2763fa8bcf 100644 --- a/test/soap/marshal/test_marshal.rb +++ b/test/soap/marshal/test_marshal.rb @@ -20,7 +20,6 @@ module MarshalTestLib end def marshaltest(o1) - #o1.instance_eval { remove_instance_variable '@v' if defined? @v } str = encode(o1) print str, "\n" if $DEBUG o2 = decode(str) @@ -174,6 +173,22 @@ module MarshalTestLib marshal_equal(0x3fff_ffff) end + def test_fixnum_ivar + o1 = 1 + o1.instance_eval { @iv = 2 } + marshal_equal(o1) {|o| o.instance_eval { @iv }} + ensure + 1.instance_eval { remove_instance_variable("@iv") } + end + + def test_fixnum_ivar_self + o1 = 1 + o1.instance_eval { @iv = 1 } + marshal_equal(o1) {|o| o.instance_eval { @iv }} + ensure + 1.instance_eval { remove_instance_variable("@iv") } + end + def test_float marshal_equal(-1.0) marshal_equal(0.0) @@ -193,6 +208,12 @@ module MarshalTestLib marshal_equal(o1) {|o| o.instance_eval { @iv }} end + def test_float_ivar_self + o1 = 5.5 + o1.instance_eval { @iv = o1 } + marshal_equal(o1) {|o| o.instance_eval { @iv }} + end + def test_float_extend o1 = 0.0/0.0 o1.extend(Mod1) |