diff options
-rw-r--r-- | activesupport/test/core_ext/hash_ext_test.rb | 4 | ||||
-rw-r--r-- | railties/test/application/server_test.rb | 16 |
2 files changed, 9 insertions, 11 deletions
diff --git a/activesupport/test/core_ext/hash_ext_test.rb b/activesupport/test/core_ext/hash_ext_test.rb index 90a5f2dcd1..8572d56722 100644 --- a/activesupport/test/core_ext/hash_ext_test.rb +++ b/activesupport/test/core_ext/hash_ext_test.rb @@ -81,7 +81,7 @@ class HashExtTest < ActiveSupport::TestCase end def test_deep_transform_values - assert_equal({ "a" => "1", "b" => "2" }, @strings.deep_transform_values{ |value| value.to_s }) + assert_equal({ "a" => "1", "b" => "2" }, @strings.deep_transform_values { |value| value.to_s }) assert_equal({ "a" => { "b" => { "c" => "3" } } }, @nested_strings.deep_transform_values { |value| value.to_s }) assert_equal({ "a" => [ { "b" => "2" }, { "c" => "3" }, "4" ] }, @string_array_of_hashes.deep_transform_values { |value| value.to_s }) end @@ -93,7 +93,7 @@ class HashExtTest < ActiveSupport::TestCase end def test_deep_transform_values! - assert_equal({ "a" => "1", "b" => "2" }, @strings.deep_transform_values!{ |value| value.to_s }) + assert_equal({ "a" => "1", "b" => "2" }, @strings.deep_transform_values! { |value| value.to_s }) assert_equal({ "a" => { "b" => { "c" => "3" } } }, @nested_strings.deep_transform_values! { |value| value.to_s }) assert_equal({ "a" => [ { "b" => "2" }, { "c" => "3" }, "4" ] }, @string_array_of_hashes.deep_transform_values! { |value| value.to_s }) end diff --git a/railties/test/application/server_test.rb b/railties/test/application/server_test.rb index 5b8aab08d5..9df36b3444 100644 --- a/railties/test/application/server_test.rb +++ b/railties/test/application/server_test.rb @@ -30,17 +30,15 @@ module ApplicationTests pid = nil Bundler.with_original_env do - begin - pid = Process.spawn("bin/rails server -P tmp/dummy.pid", chdir: app_path, in: replica, out: replica, err: replica) - assert_output("Listening", primary) + pid = Process.spawn("bin/rails server -P tmp/dummy.pid", chdir: app_path, in: replica, out: replica, err: replica) + assert_output("Listening", primary) - rails("restart") + rails("restart") - assert_output("Restarting", primary) - assert_output("Inherited", primary) - ensure - kill(pid) if pid - end + assert_output("Restarting", primary) + assert_output("Inherited", primary) + ensure + kill(pid) if pid end end |