diff options
Diffstat (limited to 'vendor/rails-2.0.2/actionpack/test/testing_sandbox.rb')
-rw-r--r-- | vendor/rails-2.0.2/actionpack/test/testing_sandbox.rb | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/vendor/rails-2.0.2/actionpack/test/testing_sandbox.rb b/vendor/rails-2.0.2/actionpack/test/testing_sandbox.rb new file mode 100644 index 000000000..b3b8b0f4d --- /dev/null +++ b/vendor/rails-2.0.2/actionpack/test/testing_sandbox.rb @@ -0,0 +1,11 @@ +module TestingSandbox + # Temporarily replaces KCODE for the block + def with_kcode(kcode) + old_kcode, $KCODE = $KCODE, kcode + begin + yield + ensure + $KCODE = old_kcode + end + end +end |