aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/template/text_helper_test.rb
diff options
context:
space:
mode:
authorJeremy Kemper <jeremy@bitsweat.net>2008-06-06 18:00:01 -0700
committerJeremy Kemper <jeremy@bitsweat.net>2008-06-06 18:00:01 -0700
commit26ec1be24a820327d00e22fb65764a3dc06977e2 (patch)
treeef57f2e85a8c22ae6a6ea2dffa98c03723845742 /actionpack/test/template/text_helper_test.rb
parente732a405ab7d0d04f8a254764970c9dcda988f01 (diff)
downloadrails-26ec1be24a820327d00e22fb65764a3dc06977e2.tar.gz
rails-26ec1be24a820327d00e22fb65764a3dc06977e2.tar.bz2
rails-26ec1be24a820327d00e22fb65764a3dc06977e2.zip
concat should ignore nil
Diffstat (limited to 'actionpack/test/template/text_helper_test.rb')
-rw-r--r--actionpack/test/template/text_helper_test.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/actionpack/test/template/text_helper_test.rb b/actionpack/test/template/text_helper_test.rb
index 62cdca03d1..0f5c62acad 100644
--- a/actionpack/test/template/text_helper_test.rb
+++ b/actionpack/test/template/text_helper_test.rb
@@ -11,6 +11,14 @@ class TextHelperTest < ActionView::TestCase
@_cycles = nil if (defined? @_cycles)
end
+ def test_concat
+ @output_buffer = 'foo'
+ concat 'bar'
+ assert_equal 'foobar', @output_buffer
+ assert_nothing_raised { concat nil }
+ assert_equal 'foobar', @output_buffer
+ end
+
def test_simple_format
assert_equal "<p></p>", simple_format(nil)