summaryrefslogtreecommitdiff
path: root/test/net/ftp/test_ftp.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/net/ftp/test_ftp.rb')
-rw-r--r--test/net/ftp/test_ftp.rb9
1 files changed, 6 insertions, 3 deletions
diff --git a/test/net/ftp/test_ftp.rb b/test/net/ftp/test_ftp.rb
index ba076dd779..ae3649ec1c 100644
--- a/test/net/ftp/test_ftp.rb
+++ b/test/net/ftp/test_ftp.rb
@@ -1,3 +1,6 @@
+#
+# -*- frozen_string_literal: true -*-
+
require "net/ftp"
require "test/unit"
require "ostruct"
@@ -545,7 +548,7 @@ class FTPTest < Test::Unit::TestCase
assert_match(/\AUSER /, commands.shift)
assert_match(/\APASS /, commands.shift)
assert_equal("TYPE I\r\n", commands.shift)
- buf = ""
+ buf = String.new
assert_raise(Net::ReadTimeout) do
ftp.retrbinary("RETR foo", 1024) do |s|
buf << s
@@ -602,7 +605,7 @@ class FTPTest < Test::Unit::TestCase
assert_match(/\AUSER /, commands.shift)
assert_match(/\APASS /, commands.shift)
assert_equal("TYPE I\r\n", commands.shift)
- buf = ""
+ buf = String.new
ftp.retrbinary("RETR foo", 1024) do |s|
buf << s
end
@@ -785,7 +788,7 @@ EOF
assert_match(/\AUSER /, commands.shift)
assert_match(/\APASS /, commands.shift)
assert_equal("TYPE I\r\n", commands.shift)
- buf = ""
+ buf = String.new
ftp.retrlines("RETR foo") do |line|
buf << line + "\r\n"
end