aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/test
diff options
context:
space:
mode:
authorMatthew Draper <matthew@trebex.net>2016-03-12 02:53:33 +1030
committerMatthew Draper <matthew@trebex.net>2016-03-12 02:53:33 +1030
commit120517706e778035ecb9920a8538a00578e79a63 (patch)
tree93e39cf1642947d8b3f9c4520267b2598829e4c4 /activesupport/test
parentf8d9c0510742b4f2d440f5223803453aaf0fbab0 (diff)
parent4f2c25d39d264aca09a000a1c44be0f1937203fa (diff)
downloadrails-120517706e778035ecb9920a8538a00578e79a63.tar.gz
rails-120517706e778035ecb9920a8538a00578e79a63.tar.bz2
rails-120517706e778035ecb9920a8538a00578e79a63.zip
Merge pull request #24143 from perceptec/fix-thread-mattr-accessor-refs
Fix `thread_mattr_accessor` thread-local variable naming
Diffstat (limited to 'activesupport/test')
-rw-r--r--activesupport/test/core_ext/module/attribute_accessor_per_thread_test.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/activesupport/test/core_ext/module/attribute_accessor_per_thread_test.rb b/activesupport/test/core_ext/module/attribute_accessor_per_thread_test.rb
index 65fadc5c20..a9fd878b80 100644
--- a/activesupport/test/core_ext/module/attribute_accessor_per_thread_test.rb
+++ b/activesupport/test/core_ext/module/attribute_accessor_per_thread_test.rb
@@ -106,4 +106,10 @@ class ModuleAttributeAccessorPerThreadTest < ActiveSupport::TestCase
end
assert_equal "invalid attribute name: 2valid_part", exception.message
end
+
+ def test_should_return_same_value_by_class_or_instance_accessor
+ @class.foo = 'fries'
+
+ assert_equal @class.foo, @object.foo
+ end
end