aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test
diff options
context:
space:
mode:
Diffstat (limited to 'actionpack/test')
-rw-r--r--actionpack/test/template/prototype_helper_test.rb10
1 files changed, 10 insertions, 0 deletions
diff --git a/actionpack/test/template/prototype_helper_test.rb b/actionpack/test/template/prototype_helper_test.rb
index 719a2f83ab..3954e38dcd 100644
--- a/actionpack/test/template/prototype_helper_test.rb
+++ b/actionpack/test/template/prototype_helper_test.rb
@@ -262,6 +262,16 @@ Element.update("baz", "<p>This is a test</p>");
@generator['hello'].hide
assert_equal %($("hello").hide();), @generator.to_s
end
+
+ def test_element_proxy_variable_access
+ @generator['hello']['style']
+ assert_equal %($("hello").style;), @generator.to_s
+ end
+
+ def test_element_proxy_variable_access_with_assignment
+ @generator['hello']['style']['color'] = 'red'
+ assert_equal %($("hello").style.color = "red";), @generator.to_s
+ end
def test_element_proxy_assignment
@generator['hello'].width = 400