diff options
author | nari <nari@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-03-13 14:52:00 +0000 |
---|---|---|
committer | nari <nari@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-03-13 14:52:00 +0000 |
commit | 2f7ca893a35abcde7e994c582055bd672c459058 (patch) | |
tree | 22ffb7d58cd3437a747402db1ed6b68b5285717e /test/ruby/test_gc.rb | |
parent | b1f2460f8dcffa9184ab916a10e1236d9b60f886 (diff) | |
download | ruby-2f7ca893a35abcde7e994c582055bd672c459058.tar.gz |
* gc.c: allow to tune growth of heap by environment variable
RUBY_HEAP_SLOTS_GROWTH_FACTOR. patched by tmm1(Aman Gupta).
[Feature #8015] [ruby-core:53131]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39746 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ruby/test_gc.rb')
-rw-r--r-- | test/ruby/test_gc.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/ruby/test_gc.rb b/test/ruby/test_gc.rb index 793ef3918e..bed58f3830 100644 --- a/test/ruby/test_gc.rb +++ b/test/ruby/test_gc.rb @@ -108,6 +108,12 @@ class TestGc < Test::Unit::TestCase assert_in_out_err([env, "-W0", "-e", "exit"], "", [], [], "[ruby-core:39795]") assert_in_out_err([env, "-W1", "-e", "exit"], "", [], [], "[ruby-core:39795]") assert_in_out_err([env, "-w", "-e", "exit"], "", [], /heap_min_slots=100000/, "[ruby-core:39795]") + + env = { + "RUBY_HEAP_SLOTS_GROWTH_FACTOR" => "2.0" + } + assert_normal_exit("exit", "", :child_env => env) + assert_in_out_err([env, "-w", "-e", "exit"], "", [], /heap_slots_growth_factor=2.0/, "") end def test_profiler_enabled |