aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/test/test_test.rb
diff options
context:
space:
mode:
Diffstat (limited to 'activesupport/test/test_test.rb')
-rw-r--r--activesupport/test/test_test.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/activesupport/test/test_test.rb b/activesupport/test/test_test.rb
index d8a02b5497..e29534ccaf 100644
--- a/activesupport/test/test_test.rb
+++ b/activesupport/test/test_test.rb
@@ -46,4 +46,11 @@ class AssertDifferenceTest < Test::Unit::TestCase
@object.decrement
end
end
+
+ def test_expression_is_evaluated_in_the_appropriate_scope
+ local_scope = 'foo'
+ assert_difference 'local_scope; @object.num' do
+ @object.increment
+ end
+ end
end