diff options
| author | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-05-22 02:40:50 +0000 |
|---|---|---|
| committer | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-05-22 02:40:50 +0000 |
| commit | db440bc6f04e7e4e4c2986a5ef17b698735e7899 (patch) | |
| tree | e7186a3a991eacf48d45765839d56d1e207a8ecc /test/ruby/test_continuation.rb | |
| parent | 0bfca51164c04af58981f554077a257e53ab2eb7 (diff) | |
| download | ruby-db440bc6f04e7e4e4c2986a5ef17b698735e7899.tar.gz ruby-db440bc6f04e7e4e4c2986a5ef17b698735e7899.tar.xz ruby-db440bc6f04e7e4e4c2986a5ef17b698735e7899.zip | |
* test/ruby/envutil.rb (assert_normal_exit): capture stdout and stderr
of the child process.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@16520 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ruby/test_continuation.rb')
| -rw-r--r-- | test/ruby/test_continuation.rb | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/test/ruby/test_continuation.rb b/test/ruby/test_continuation.rb index 09787c158..f8302abdc 100644 --- a/test/ruby/test_continuation.rb +++ b/test/ruby/test_continuation.rb @@ -51,5 +51,17 @@ class TestContinuation < Test::Unit::TestCase c.call } end + + def test_ary_flatten + assert_normal_exit %q{ + require 'continuation' + n = 0 + o = Object.new + def o.to_ary() callcc {|k| $k = k; [1,2,3]} end + [10,20,o,30,o,40].flatten.inspect + n += 1 + $k.call if n < 100 + }, '[ruby-dev:34798]' + end end |
