test/paths/sftp_test.rb in iostreams-1.2.1 vs test/paths/sftp_test.rb in iostreams-1.3.0

- old
+ new

@@ -40,11 +40,11 @@ root_path.join("writer_test.txt") end describe "#reader" do it "reads" do - assert_equal raw, existing_path.reader(&:read) + assert_equal raw, existing_path.read end it "fails when the file does not exist" do assert_raises IOStreams::Errors::CommunicationsFailure do missing_file_path.read @@ -58,11 +58,11 @@ end end describe "#writer" do it "writes" do - assert_equal raw.size, write_path.writer { |io| io.write(raw) } + assert_equal(raw.size, write_path.writer { |io| io.write(raw) }) assert_equal raw, write_path.read end it "fails when the directory does not exist" do assert_raises IOStreams::Errors::CommunicationsFailure do @@ -75,11 +75,11 @@ IOStreams::Paths::SFTP.new(url, username: identity_username, ssh_options: {"IdentityFile" => ENV["SFTP_IDENTITY_FILE"]}) end it "writes" do skip "No identity file env var set: SFTP_IDENTITY_FILE" unless ENV["SFTP_IDENTITY_FILE"] - assert_equal raw.size, write_path.writer { |io| io.write(raw) } + assert_equal(raw.size, write_path.writer { |io| io.write(raw) }) assert_equal raw, write_path.read end end describe "use identity key instead of password" do @@ -88,10 +88,10 @@ IOStreams::Paths::SFTP.new(url, username: identity_username, ssh_options: {"IdentityKey" => key}) end it "writes" do skip "No identity file env var set: SFTP_IDENTITY_FILE" unless ENV["SFTP_IDENTITY_FILE"] - assert_equal raw.size, write_path.writer { |io| io.write(raw) } + assert_equal(raw.size, write_path.writer { |io| io.write(raw) }) assert_equal raw, write_path.read end end end end