summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-10-19 15:59:35 (GMT)
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-10-19 15:59:35 (GMT)
commit8fe3d0285fce27fc206a593c7131e8df72808f41 (patch)
tree141311d22801550eaa92b07d19d7af9d7debda20 /bin
parent295c75cb7ccaee5d3050f60f9daff85e2f6ae050 (diff)
* lib/test/unit.rb (Test::Unit.setup_argv): call given block for
filtering files. * test/runner.rb: search srcdir/test/arg, srcdir/arg. * bin/testrb: show usage if no files given. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19849 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'bin')
-rwxr-xr-xbin/testrb8
1 files changed, 7 insertions, 1 deletions
diff --git a/bin/testrb b/bin/testrb
index cd3837f..2e323f5 100755
--- a/bin/testrb
+++ b/bin/testrb
@@ -1,3 +1,9 @@
#!/usr/bin/env ruby
require 'test/unit'
-Test::Unit.setup_argv
+Test::Unit.setup_argv {|files|
+ if files.empty?
+ puts "Usage: testrb [options] tests..."
+ exit 1
+ end
+ files
+}