きりかノート 3冊め

おあそびプログラミング

ruby-1.8.7-p294の動作確認をしてみた

[ruby-dev:41577] (予告) 1.8.7 のリリースを出そうとしていますを見たので試してみた。といっても./configure && make && sudo make install && make test-allするだけの簡単なお仕事。

例によってTCPServer.open()が失敗するのでMacPorts版でつかってるパッチを当てる。

で再度トライすると2F1Eになった。

Finished in 602.062503 seconds.

  1) Failure:
test_connection_refused_in_request(TestHTTP::HTTPConnectionTest) [./test/net/http/test_connection.rb:20]:
[ruby-core:28028].
<EOFError> exception expected but was
Class: <Errno::ECONNRESET>
Message: <"Connection reset by peer">
---Backtrace---
/Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/net/protocol.rb:135:in `sysread'
/Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/net/protocol.rb:135:in `rbuf_fill'
/Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/timeout.rb:67:in `timeout'
/Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/timeout.rb:101:in `timeout'
/Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/net/protocol.rb:134:in `rbuf_fill'
/Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/net/protocol.rb:116:in `readuntil'
/Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/net/protocol.rb:126:in `readline'
/Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/net/http.rb:2028:in `read_status_line'
/Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/net/http.rb:2017:in `read_new'
/Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/net/http.rb:1051:in `request'
/Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/net/http.rb:1037:in `request'
/Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/net/http.rb:543:in `start'
/Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/net/http.rb:1035:in `request'
/Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/net/http.rb:948:in `request_get'
./test/net/http/test_connection.rb:22:in `test_connection_refused_in_request'
./test/net/http/test_connection.rb:20:in `test_connection_refused_in_request'
---------------

  2) Failure:
test_readpartial_pos(TestIO)
    [./test/ruby/test_io.rb:28:in `test_readpartial_pos'
     /Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/open-uri.rb:32:in `open_uri_original_open'
     /Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/open-uri.rb:32:in `open'
     ./test/ruby/test_io.rb:25:in `test_readpartial_pos'
     ./test/ruby/test_io.rb:9:in `mkcdtmpdir'
     ./test/ruby/test_io.rb:8:in `chdir'
     ./test/ruby/test_io.rb:8:in `mkcdtmpdir'
     /Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/tmpdir.rb:129:in `mktmpdir'
     ./test/ruby/test_io.rb:7:in `mkcdtmpdir'
     ./test/ruby/test_io.rb:23:in `test_readpartial_pos']:
<2> expected but was
<0>.

  3) Error:
test_filehandler(WEBrick::TestFileHandler):
NameError: undefined local variable or method `log' for #<WEBrick::TestFileHandler:0x103637b40>
    ./test/webrick/test_filehandler.rb:96:in `test_filehandler'
    /Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/net/http.rb:1054:in `request'
    /Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/net/http.rb:2144:in `reading_body'
    /Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/net/http.rb:1053:in `request'
    /Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/net/http.rb:1037:in `request'
    /Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/net/http.rb:543:in `start'
    /Volumes/CHome/kimuraw/work/ruby-1.8.7/lib/net/http.rb:1035:in `request'
    ./test/webrick/test_filehandler.rb:95:in `test_filehandler'
    ./test/webrick/utils.rb:38:in `call'
    ./test/webrick/utils.rb:38:in `start_server'
    ./test/webrick/utils.rb:46:in `start_httpserver'
    ./test/webrick/test_filehandler.rb:79:in `test_filehandler'

2208 tests, 1670312 assertions, 2 failures, 1 errors
make: *** [test-all] Error 1

1は例外クラスが期待するものとちがうようだ。このテストは1.8.7と1.8で期待される例外がちがっているのだけど、そういうもの?あとでruby-devにメールしてみよう。

2はいつもでてるやつ(前に調べたけどよくわかんなかった)。

3はなんかおかしい。テストスクリプト中で未定義の変数?があるって。

とりあえず3について調べた結果、1.8(1.8.8dev)からコードをいくつか持ってくればよさそうなことがわかったのでredmineのチケットに書いておいた。

さてつぎは1.9.2-preview3だ。せっかく告知があったんだから、みんなも動作確認するんだ!