summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-02-02 16:44:22 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-02-02 16:44:22 +0000
commit8b242a0d09bec00b2cfc1c779edaaac453bf05bc (patch)
treeabd1bda8048d584841f6e51c762c83efb9993559
parent0d829c4af4857ef5ca3446dd39c00f789ab39d3a (diff)
test_system.rb: tests without shell
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62168 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--test/ruby/test_system.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/ruby/test_system.rb b/test/ruby/test_system.rb
index e1b03322cf..c56e2a13c4 100644
--- a/test/ruby/test_system.rb
+++ b/test/ruby/test_system.rb
@@ -167,12 +167,18 @@ class TestSystem < Test::Unit::TestCase
system('feature_14235', exception: false)
end
assert_nothing_raised do
+ system(ruby, "-e", "abort", exception: false)
+ end
+ assert_nothing_raised do
system("'#{ruby}' -e abort", exception: false)
end
assert_raise(Errno::ENOENT) do
system('feature_14235', exception: true)
end
assert_raise_with_message(RuntimeError, /\ACommand failed with exit /) do
+ system(ruby, "-e", "abort", exception: true)
+ end
+ assert_raise_with_message(RuntimeError, /\ACommand failed with exit /) do
system("'#{ruby}' -e abort", exception: true)
end
end