Last change
on this file was 439, checked in by coas-nagasima, 4 years ago |
mrubyを2.1.1に更新
|
-
Property svn:eol-style
set to
native
-
Property svn:mime-type
set to
text/x-ruby;charset=UTF-8
|
File size:
719 bytes
|
Rev | Line | |
---|
[270] | 1 | $:.unshift File.dirname(File.dirname(File.expand_path(__FILE__)))
|
---|
| 2 | require 'test/assert.rb'
|
---|
| 3 |
|
---|
[439] | 4 | GEMNAME = ""
|
---|
| 5 |
|
---|
[270] | 6 | def cmd(s)
|
---|
| 7 | case RbConfig::CONFIG['host_os']
|
---|
[331] | 8 | when /mswin(?!ce)|mingw|bccwin/
|
---|
[270] | 9 | "bin\\#{s}.exe"
|
---|
| 10 | else
|
---|
| 11 | "bin/#{s}"
|
---|
| 12 | end
|
---|
| 13 | end
|
---|
| 14 |
|
---|
| 15 | def shellquote(s)
|
---|
| 16 | case RbConfig::CONFIG['host_os']
|
---|
[331] | 17 | when /mswin(?!ce)|mingw|bccwin/
|
---|
[270] | 18 | "\"#{s}\""
|
---|
| 19 | else
|
---|
| 20 | "'#{s}'"
|
---|
| 21 | end
|
---|
| 22 | end
|
---|
| 23 |
|
---|
[439] | 24 | print "bintest - Command Binary Test\n\n"
|
---|
| 25 |
|
---|
[270] | 26 | ARGV.each do |gem|
|
---|
[439] | 27 | case gem
|
---|
| 28 | when '-v'; $mrbtest_verbose = true
|
---|
| 29 | end
|
---|
| 30 |
|
---|
[331] | 31 | case RbConfig::CONFIG['host_os']
|
---|
| 32 | when /mswin(?!ce)|mingw|bccwin/
|
---|
| 33 | gem = gem.gsub('\\', '/')
|
---|
| 34 | end
|
---|
| 35 |
|
---|
[270] | 36 | Dir["#{gem}/bintest/**/*.rb"].each do |file|
|
---|
[439] | 37 | GEMNAME.replace(File.basename(gem))
|
---|
[270] | 38 | load file
|
---|
| 39 | end
|
---|
| 40 | end
|
---|
| 41 |
|
---|
[439] | 42 | exit report
|
---|
Note:
See
TracBrowser
for help on using the repository browser.