aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/test/ordered_options_test.rb
diff options
context:
space:
mode:
Diffstat (limited to 'activesupport/test/ordered_options_test.rb')
-rw-r--r--activesupport/test/ordered_options_test.rb11
1 files changed, 10 insertions, 1 deletions
diff --git a/activesupport/test/ordered_options_test.rb b/activesupport/test/ordered_options_test.rb
index b215b60df3..f60f9a58e3 100644
--- a/activesupport/test/ordered_options_test.rb
+++ b/activesupport/test/ordered_options_test.rb
@@ -1,6 +1,7 @@
require 'abstract_unit'
+require 'active_support/ordered_options'
-class OrderedOptionsTest < Test::Unit::TestCase
+class OrderedOptionsTest < ActiveSupport::TestCase
def test_usage
a = ActiveSupport::OrderedOptions.new
@@ -76,4 +77,12 @@ class OrderedOptionsTest < Test::Unit::TestCase
assert copy.kind_of?(original.class)
assert_not_equal copy.object_id, original.object_id
end
+
+ def test_introspection
+ a = ActiveSupport::OrderedOptions.new
+ assert a.respond_to?(:blah)
+ assert a.respond_to?(:blah=)
+ assert_equal 42, a.method(:blah=).call(42)
+ assert_equal 42, a.method(:blah).call
+ end
end