Bug #1878
closedtestrb can not execute tests in sub directory
Description
=begin
1.9.2-preview1 の testrb コマンドがサブディレクトリのテストを実行できません。
$ ruby192 -v
ruby 1.9.2dev (2009-07-18 trunk 24186) [i686-linux]
$ mkdir test
$ echo 'require "test/unit"; class A<Test::Unit::TestCase; def test_a; assert_match(/a/, "a"); end; end' > test/test_a.rb
$ echo 'require "test/unit"; class B<Test::Unit::TestCase; def test_b; assert_match(/a/, "b"); end; end' > test/test_b.rb
$ ls test
test_a.rb test_b.rb
$ testrb192 test
test/test_a.rb: no such file to load -- test/test_a.rb
test/test_b.rb: no such file to load -- test/test_b.rb
Loaded suite test
Started
Finished in 0.000456 seconds.
0 tests, 0 assertions, 0 failures, 0 errors, 0 skips
$
こんな感じで、サブディレクトリのテストを読んでくれません。
Ruby 1.9.1 ではもちろん成功します。
$ ruby191 -v
ruby 1.9.1p243 (2009-07-16 revision 24175) [i686-linux]
$ testrb191 test
Loaded suite test
Started
.F
Finished in 0.002952 seconds.
- Failure:
test_b(B) [/tmp/z2/test/test_b.rb:1]:
Expected /a/ to match "b".
2 tests, 4 assertions, 1 failures, 0 errors, 0 skips
(注: assertionsの数が多いのは既知の問題、1.9.2にて解決したはず。)
=end
Updated by nobu (Nobuyoshi Nakada) over 14 years ago
- Status changed from Open to Closed
- % Done changed from 0 to 100
=begin
Applied in changeset r24397.
=end