diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-04-20 10:21:42 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-04-20 10:21:42 +0000 |
commit | cbaf61b276492532f4348f284322c88fcfe6efb5 (patch) | |
tree | c033e00bcaaac02624f2cd09c7609a1b1b3c1967 /test/ruby/test_system.rb | |
parent | 2b222b9b1773d8ae574c4d39b312b83615ecb700 (diff) | |
download | ruby-cbaf61b276492532f4348f284322c88fcfe6efb5.tar.gz |
* test/ruby/test_system.rb (TestSystem#valid_syntax): return false
on syntax error.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27416 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ruby/test_system.rb')
-rw-r--r-- | test/ruby/test_system.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/test/ruby/test_system.rb b/test/ruby/test_system.rb index 1819982250..fbed36ad57 100644 --- a/test/ruby/test_system.rb +++ b/test/ruby/test_system.rb @@ -10,6 +10,8 @@ class TestSystem < Test::Unit::TestCase } code.force_encoding("us-ascii") catch {|tag| eval(code, binding, fname, 0)} + rescue SyntaxError + false end def test_system |