diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-06-05 06:15:55 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-06-05 06:15:55 +0000 |
commit | 2c2ae5b16450db3597815d190c557e82c10104d6 (patch) | |
tree | 22f191b373645b7989e2f205ab8dd617b19c969e /test | |
parent | f75ab0150dfa44f00921f60f1e43b3b3637d62dc (diff) | |
download | ruby-2c2ae5b16450db3597815d190c557e82c10104d6.tar.gz |
* test/ruby/envutil.rb (EnvUtil#invoke_ruby): support for child
process env.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@28171 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
-rw-r--r-- | test/ruby/envutil.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/test/ruby/envutil.rb b/test/ruby/envutil.rb index c5215e4bdd..8f792d249f 100644 --- a/test/ruby/envutil.rb +++ b/test/ruby/envutil.rb @@ -75,7 +75,11 @@ module EnvUtil opt[:in] = in_c opt[:out] = out_c if capture_stdout opt[:err] = err_c if capture_stderr - pid = spawn(EnvUtil.rubybin, *args, opt) + case args.first + when Hash + child_env = [args.shift] + end + pid = spawn(*child_env, EnvUtil.rubybin, *args, opt) in_c.close out_c.close if capture_stdout err_c.close if capture_stderr |