Forum: Ruby rbtree tests fail on 1.8.2, but not on 1.8.4

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
159cd33667611645164e8623de42f67e?d=identicon&s=25 Toby DiPasquale (Guest)
on 2006-03-08 20:00
Hi all,

I dug up the rbtree 0.1.3 tarball from the RAA cache and am trying to
build it. It builds fine, but the tests fail. Unfortunately for me, this
test is indicative of the exact functionality I require.

What's wierd is that the test fails on ruby 1.8.2, but it passes on ruby
1.8.4. Does anyone have any ideas about why this would occur and what I
can do about it (other than just moving up to 1.8.4...) ?

Output from attempt with 1.8.2:

<snip>
rodimus:~/ruby-rbtree> ruby extconf.rb
checking for allocation framework... yes
checking for rb_obj_init_copy()... yes
checking for rb_block_proc()... yes
checking for rb_yield_values()... yes
checking for rb_marshal_dump()... yes
checking for rb_marshal_load()... yes
checking for inline keyword... __inline
creating Makefile
rodimus:~/ruby-rbtree> make
gcc -fPIC -O2 -g -pipe -march=i386 -mcpu=i686  -fPIC -std=c89 -pedantic
-Wall -Wno-long-long  -I. -I/usr/lib/ruby/1.8/i386-linux
-I/usr/lib/ruby/1.8/i386-linux -I.  -DNDEBUG -DHAVE_OBJECT_ALLOCATE
-DHAVE_RB_OBJ_INIT_COPY -DHAVE_RB_BLOCK_PROC -DHAVE_RB_YIELD_VALUES
-DHAVE_RB_MARSHAL_DUMP -DHAVE_RB_MARSHAL_LOAD -Dinline=__inline  -c
dict.c
gcc -fPIC -O2 -g -pipe -march=i386 -mcpu=i686  -fPIC -std=c89 -pedantic
-Wall -Wno-long-long  -I. -I/usr/lib/ruby/1.8/i386-linux
-I/usr/lib/ruby/1.8/i386-linux -I.  -DNDEBUG -DHAVE_OBJECT_ALLOCATE
-DHAVE_RB_OBJ_INIT_COPY -DHAVE_RB_BLOCK_PROC -DHAVE_RB_YIELD_VALUES
-DHAVE_RB_MARSHAL_DUMP -DHAVE_RB_MARSHAL_LOAD -Dinline=__inline  -c
rbtree.c
gcc -shared  -L'/usr/lib' -Wl,-R'/usr/lib' -o rbtree.so dict.o rbtree.o
-Wl,-R -Wl,/usr/lib -L/usr/lib -L. -lruby  -ldl -lcrypt -lm   -lc
rodimus:~/ruby-rbtree> ruby test.rb
Loaded suite test
Started
....................................................test.rb:201:
warning: block supersedes default value argument
...............F................
Finished in 0.02627 seconds.

  1) Failure:
test_readjust(RBTreeTest) [test.rb:592]:
<ArgumentError> exception expected but was
Class: <NoMethodError>
Message: <"undefined method `>' for false:FalseClass">
---Backtrace---
test.rb:592:in `readjust'
test.rb:592:in `test_readjust'
test.rb:592:in `assert_raise'
test.rb:592:in `test_readjust'
---------------

84 tests, 278 assertions, 1 failures, 0 errors
rodimus:~/ruby-rbtree> ruby --version
ruby 1.8.2 (2004-12-25) [i386-linux]
rodimus:~/ruby-rbtree>
</snip>

Here's the output from the same process on Ruby 1.8.4 (extconf and make
output removed for brevity):

<snip>
puma:~/rbtree-0.1.3> ruby test.rb
Loaded suite test
Started
....................................................test.rb:201:
warning: block supersedes default value argument
...............test.rb:609: warning: RBTree#readjust() uses current
comparison block, use RBTree#readjust(nil) to set default comparison
block
.................
Finished in 0.134389 seconds.

84 tests, 287 assertions, 0 failures, 0 errors
puma:~/rbtree-0.1.3> ruby --version
ruby 1.8.4 (2005-12-24) [i686-linux]
puma:~/rbtree-0.1.3>
</snip>

--
Toby DiPasquale
Cb48ca5059faf7409a5ab3745a964696?d=identicon&s=25 unknown (Guest)
on 2006-03-08 20:10
(Received via mailing list)
On Thu, 9 Mar 2006, Toby DiPasquale wrote:

> Hi all,
>
> I dug up the rbtree 0.1.3 tarball from the RAA cache and am trying to
> build it. It builds fine, but the tests fail. Unfortunately for me, this
> test is indicative of the exact functionality I require.
>
> What's wierd is that the test fails on ruby 1.8.2, but it passes on ruby
> 1.8.4. Does anyone have any ideas about why this would occur and what I
> can do about it (other than just moving up to 1.8.4...) ?

i can confirm the above at least... may have time later to look into it.


more later...

-a
This topic is locked and can not be replied to.