From b70fc698e157f2a768ba42efac08c08f4786b01c Mon Sep 17 00:00:00 2001 From: Akira Matsuda Date: Thu, 12 Jan 2017 17:39:16 +0900 Subject: Reduce string objects by using \ instead of + or << for concatenating strings (I personally prefer writing one string in one line no matter how long it is, though) --- .../activerecord/form_helper_activerecord_test.rb | 2 +- .../test/template/form_helper/form_with_test.rb | 382 +++++++++---------- actionview/test/template/form_helper_test.rb | 414 ++++++++++----------- .../test/template/form_options_helper_test.rb | 236 ++++++------ actionview/test/template/render_test.rb | 10 +- actionview/test/template/url_helper_test.rb | 2 +- 6 files changed, 523 insertions(+), 523 deletions(-) (limited to 'actionview/test') diff --git a/actionview/test/activerecord/form_helper_activerecord_test.rb b/actionview/test/activerecord/form_helper_activerecord_test.rb index 0f7960b408..3b314588c7 100644 --- a/actionview/test/activerecord/form_helper_activerecord_test.rb +++ b/actionview/test/activerecord/form_helper_activerecord_test.rb @@ -45,7 +45,7 @@ class FormHelperActiveRecordTest < ActionView::TestCase end expected = whole_form("/developers/123", "edit_developer_123", "edit_developer", method: "patch") do - '' + + '' \ '' end diff --git a/actionview/test/template/form_helper/form_with_test.rb b/actionview/test/template/form_helper/form_with_test.rb index 3a91c7dce7..a4a2966ff9 100644 --- a/actionview/test/template/form_helper/form_with_test.rb +++ b/actionview/test/template/form_helper/form_with_test.rb @@ -310,13 +310,13 @@ class FormWithActsLikeFormForTest < FormWithTest end expected = whole_form("/posts/123", "create-post", method: "patch") do - "" + - "" + - "" + - "" + - "" + - "" + - "" + + "" \ + "" \ + "" \ + "" \ + "" \ + "" \ + "" \ "" end @@ -330,7 +330,7 @@ class FormWithActsLikeFormForTest < FormWithTest end expected = whole_form("/posts") do - '' + + '' \ '' end @@ -344,7 +344,7 @@ class FormWithActsLikeFormForTest < FormWithTest end expected = whole_form("/posts/123") do - '' + + '' \ '' end @@ -400,10 +400,10 @@ class FormWithActsLikeFormForTest < FormWithTest end expected = whole_form("/posts") do - "" + - "" + - "" + - "" + + "" \ + "" \ + "" \ + "" \ "" end @@ -422,12 +422,12 @@ class FormWithActsLikeFormForTest < FormWithTest end expected = whole_form("/posts") do - "" + - "" + - "