diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/ruby/test_system.rb | 4 | ||||
-rw-r--r-- | test/xsd/test_noencoding.rb | 6 |
2 files changed, 8 insertions, 2 deletions
diff --git a/test/ruby/test_system.rb b/test/ruby/test_system.rb index d756e4a2d5..71eb7ad183 100644 --- a/test/ruby/test_system.rb +++ b/test/ruby/test_system.rb @@ -61,8 +61,8 @@ class TestSystem < Test::Unit::TestCase dir << "/" end - for script in Dir["#{dir}{lib,sample,ext}/**/*.rb"] - assert_nothing_raised(Exception) do + assert_nothing_raised(Exception) do + for script in Dir["#{dir}{lib,sample,ext}/**/*.rb"] valid_syntax? IO::read(script), script end end diff --git a/test/xsd/test_noencoding.rb b/test/xsd/test_noencoding.rb index f4a2232faa..48119ec1f7 100644 --- a/test/xsd/test_noencoding.rb +++ b/test/xsd/test_noencoding.rb @@ -13,6 +13,12 @@ class TestEmptyCharset < Test::Unit::TestCase def test_wsdl begin xml = WSDL::XMLSchema::Parser.new.parse(File.open(@file) { |f| f.read }) + rescue RuntimeError + if XSD::XMLParser.const_defined?("REXMLParser") + STDERR.puts("rexml cannot handle euc-jp without iconv/uconv.") + return + end + raise rescue Errno::EINVAL # unsupported encoding return |