diff options
author | mrkn <mrkn@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-08-17 06:35:21 +0000 |
---|---|---|
committer | mrkn <mrkn@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-08-17 06:35:21 +0000 |
commit | 4e8d6c105c22c40f1abf1aab357419e8f4ef2f5b (patch) | |
tree | 8663c427f448abbc89539c56d9f9e185e0e44d70 /test/bigdecimal/testbase.rb | |
parent | b30d203fed8c29fd05d010631ca8e4750ce34849 (diff) | |
download | ruby-4e8d6c105c22c40f1abf1aab357419e8f4ef2f5b.tar.gz |
Merge branch '5172_bigdecimal_gc_issue' into trunk
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32996 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/bigdecimal/testbase.rb')
-rw-r--r-- | test/bigdecimal/testbase.rb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test/bigdecimal/testbase.rb b/test/bigdecimal/testbase.rb index 275b1b2b5d..c014e61e92 100644 --- a/test/bigdecimal/testbase.rb +++ b/test/bigdecimal/testbase.rb @@ -17,4 +17,11 @@ module TestBigDecimalBase BigDecimal.mode(mode, !(@mode & mode).zero?) end end + + def under_gc_stress + stress, GC.stress = GC.stress, true + yield + ensure + GC.stress = stress + end end |