diff options
author | kou <kou@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-11-19 13:11:20 +0000 |
---|---|---|
committer | kou <kou@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-11-19 13:11:20 +0000 |
commit | 54142064c4dc8559e3c6d13a1fdb95bcb5f06d95 (patch) | |
tree | 800df2bee7b2aaf2bac20ab13db944983a8c447c /test/rexml/test_core.rb | |
parent | 91c0ff4f7d28856645b72d09f58dbabfa5e862ad (diff) | |
download | ruby-54142064c4dc8559e3c6d13a1fdb95bcb5f06d95.tar.gz |
* test/rexml/test_core.rb
(Tester#test_pretty_format_long_text_finite): skip a test that
uses long string on small memory system. [ruby-dev:42599]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29835 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/rexml/test_core.rb')
-rw-r--r-- | test/rexml/test_core.rb | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/test/rexml/test_core.rb b/test/rexml/test_core.rb index d9280f6aed..90d83f11a5 100644 --- a/test/rexml/test_core.rb +++ b/test/rexml/test_core.rb @@ -1156,7 +1156,16 @@ EOL long_text = 'aaaa ' * n xml = "<doc>#{long_text}</doc>" formatter = REXML::Formatters::Pretty.new - document = REXML::Document.new(xml) + document = nil + begin + document = REXML::Document.new(xml) + rescue REXML::ParseException + skip_message = "skip this test because we can't check Pretty#wrap " + + "works without #<SystemStackError: stack level too deep> on " + + "small memory system. #<RegexpError: failed to allocate memory> " + + "will be raised on the system. See also [ruby-dev:42599]." + return skip_message + end output = "" assert_nothing_raised do formatter.write(document, output) |