summaryrefslogtreecommitdiff
path: root/test/ruby
diff options
context:
space:
mode:
authorkazu <kazu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-02-02 11:21:12 +0000
committerkazu <kazu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-02-02 11:21:12 +0000
commit59f502295fb48b6a7ef6c2f9a36cb7d1efeabb18 (patch)
tree26b55ef7977336a73b2f03f198d733d0c6faece6 /test/ruby
parent02d7ad9722f4a32085e4a7f6d59b27ecaadb486c (diff)
Fix test
Followup to r62158 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62160 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ruby')
-rw-r--r--test/ruby/test_system.rb8
1 files changed, 2 insertions, 6 deletions
diff --git a/test/ruby/test_system.rb b/test/ruby/test_system.rb
index 0c0ad33fb6..af80009fea 100644
--- a/test/ruby/test_system.rb
+++ b/test/ruby/test_system.rb
@@ -170,13 +170,9 @@ class TestSystem < Test::Unit::TestCase
assert_raise(Errno::ENOENT) do
system('feature_14235', exception: true)
end
- assert_raise(RuntimeError) do
+ e = assert_raise(RuntimeError) do
system("'#{ruby}' -e 'exit 1'", exception: true)
end
- begin
- system("'#{ruby}' -e 'exit 1'", exception: true)
- rescue RuntimeError => e
- assert_equal true, e.message.include?('status (1)')
- end
+ assert_match /\ACommand failed with exit 1:/, e.message
end
end