summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorshugo <shugo@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-10-09 07:28:10 +0000
committershugo <shugo@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-10-09 07:28:10 +0000
commitae6555aa25de6aadeeb0dd1efc9aca9b5dbba9d7 (patch)
tree1de6a6fa2bf380b47ca475ccf3b0248e05e6d15b /test
parentd8d51b6708d08c2ce60aee352dacb16d864d77b2 (diff)
* lib/net/ftp.rb: use frozen_string_literal: true.
* test/net/ftp/test_buffered_socket.rb: ditto. * test/net/ftp/test_ftp.rb: ditto. * test/net/ftp/test_mlsx_entry.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52092 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
-rw-r--r--test/net/ftp/test_buffered_socket.rb3
-rw-r--r--test/net/ftp/test_ftp.rb9
-rw-r--r--test/net/ftp/test_mlsx_entry.rb3
3 files changed, 12 insertions, 3 deletions
diff --git a/test/net/ftp/test_buffered_socket.rb b/test/net/ftp/test_buffered_socket.rb
index 8d7cc2e..419d50b 100644
--- a/test/net/ftp/test_buffered_socket.rb
+++ b/test/net/ftp/test_buffered_socket.rb
@@ -1,3 +1,6 @@
+#
+# -*- frozen_string_literal: true -*-
+
require "net/ftp"
require "test/unit"
require "ostruct"
diff --git a/test/net/ftp/test_ftp.rb b/test/net/ftp/test_ftp.rb
index ba076dd..ae3649e 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
diff --git a/test/net/ftp/test_mlsx_entry.rb b/test/net/ftp/test_mlsx_entry.rb
index 865cf91..7321caa 100644
--- a/test/net/ftp/test_mlsx_entry.rb
+++ b/test/net/ftp/test_mlsx_entry.rb
@@ -1,3 +1,6 @@
+#
+# -*- frozen_string_literal: true -*-
+
require "net/ftp"
require "test/unit"
require "ostruct"