summaryrefslogtreecommitdiff
path: root/spec/ruby/library/net/ftp/nlst_spec.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/ruby/library/net/ftp/nlst_spec.rb')
-rw-r--r--spec/ruby/library/net/ftp/nlst_spec.rb20
1 files changed, 10 insertions, 10 deletions
diff --git a/spec/ruby/library/net/ftp/nlst_spec.rb b/spec/ruby/library/net/ftp/nlst_spec.rb
index 36ca7a6127..34384fb8c4 100644
--- a/spec/ruby/library/net/ftp/nlst_spec.rb
+++ b/spec/ruby/library/net/ftp/nlst_spec.rb
@@ -35,32 +35,32 @@ describe "Net::FTP#nlst" do
describe "when the NLST command fails" do
it "raises a Net::FTPTempError when the response code is 450" do
@server.should_receive(:nlst).and_respond("450 Requested file action not taken..")
- lambda { @ftp.nlst }.should raise_error(Net::FTPTempError)
+ -> { @ftp.nlst }.should raise_error(Net::FTPTempError)
end
it "raises a Net::FTPPermError when the response code is 500" do
@server.should_receive(:nlst).and_respond("500 Syntax error, command unrecognized.")
- lambda { @ftp.nlst }.should raise_error(Net::FTPPermError)
+ -> { @ftp.nlst }.should raise_error(Net::FTPPermError)
end
it "raises a Net::FTPPermError when the response code is 501" do
@server.should_receive(:nlst).and_respond("501 Syntax error, command unrecognized.")
- lambda { @ftp.nlst }.should raise_error(Net::FTPPermError)
+ -> { @ftp.nlst }.should raise_error(Net::FTPPermError)
end
it "raises a Net::FTPPermError when the response code is 502" do
@server.should_receive(:nlst).and_respond("502 Command not implemented.")
- lambda { @ftp.nlst }.should raise_error(Net::FTPPermError)
+ -> { @ftp.nlst }.should raise_error(Net::FTPPermError)
end
it "raises a Net::FTPTempError when the response code is 421" do
@server.should_receive(:nlst).and_respond("421 Service not available, closing control connection.")
- lambda { @ftp.nlst }.should raise_error(Net::FTPTempError)
+ -> { @ftp.nlst }.should raise_error(Net::FTPTempError)
end
it "raises a Net::FTPPermError when the response code is 530" do
@server.should_receive(:nlst).and_respond("530 Not logged in.")
- lambda { @ftp.nlst }.should raise_error(Net::FTPPermError)
+ -> { @ftp.nlst }.should raise_error(Net::FTPPermError)
end
end
@@ -68,25 +68,25 @@ describe "Net::FTP#nlst" do
it "raises a Net::FTPPermError when the response code is 500" do
@server.should_receive(:eprt).and_respond("500 Syntax error, command unrecognized.")
@server.should_receive(:port).and_respond("500 Syntax error, command unrecognized.")
- lambda { @ftp.nlst }.should raise_error(Net::FTPPermError)
+ -> { @ftp.nlst }.should raise_error(Net::FTPPermError)
end
it "raises a Net::FTPPermError when the response code is 501" do
@server.should_receive(:eprt).and_respond("501 Syntax error in parameters or arguments.")
@server.should_receive(:port).and_respond("501 Syntax error in parameters or arguments.")
- lambda { @ftp.nlst }.should raise_error(Net::FTPPermError)
+ -> { @ftp.nlst }.should raise_error(Net::FTPPermError)
end
it "raises a Net::FTPTempError when the response code is 421" do
@server.should_receive(:eprt).and_respond("421 Service not available, closing control connection.")
@server.should_receive(:port).and_respond("421 Service not available, closing control connection.")
- lambda { @ftp.nlst }.should raise_error(Net::FTPTempError)
+ -> { @ftp.nlst }.should raise_error(Net::FTPTempError)
end
it "raises a Net::FTPPermError when the response code is 530" do
@server.should_receive(:eprt).and_respond("530 Not logged in.")
@server.should_receive(:port).and_respond("530 Not logged in.")
- lambda { @ftp.nlst }.should raise_error(Net::FTPPermError)
+ -> { @ftp.nlst }.should raise_error(Net::FTPPermError)
end
end
end