diff options
author | Thom May <thom@may.lt> | 2017-01-17 18:39:58 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-01-17 18:39:58 +0000 |
commit | 6003f2f82210163573076633c9cb3a64ea30a995 (patch) | |
tree | 0be3ee1896b73c3bf209662729ef8bdc4b16a058 | |
parent | 866991252303e1f41ec8008b6ed137bb3724e216 (diff) | |
parent | 948d10e6a683e31ebefd33298a82f5a0fccfdc24 (diff) | |
download | chef-6003f2f82210163573076633c9cb3a64ea30a995.tar.gz |
Merge pull request #5539 from atward/remote_sftp_test_fix
Correct SFTP remote_file tests
-rw-r--r-- | spec/unit/provider/remote_file/sftp_spec.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/spec/unit/provider/remote_file/sftp_spec.rb b/spec/unit/provider/remote_file/sftp_spec.rb index 7be507dc89..ddab1605f0 100644 --- a/spec/unit/provider/remote_file/sftp_spec.rb +++ b/spec/unit/provider/remote_file/sftp_spec.rb @@ -117,7 +117,7 @@ describe Chef::Provider::RemoteFile::SFTP do end context "and the URI specifies an alternate port" do - let(:uri) { URI.parse("ftp://conan:cthu1hu@opscode.com:8021/seattle.txt") } + let(:uri) { URI.parse("sftp://conan:cthu1hu@opscode.com:8021/seattle.txt") } it "should connect on an alternate port when one is provided" do expect(Net::SFTP).to receive(:start).with("opscode.com:8021", "conan", :password => "cthu1hu") @@ -127,10 +127,10 @@ describe Chef::Provider::RemoteFile::SFTP do end context "and the uri specifies a nested path" do - let(:uri) { URI.parse("ftp://conan:cthu1hu@opscode.com/the/whole/path/seattle.txt") } + let(:uri) { URI.parse("sftp://conan:cthu1hu@opscode.com/the/whole/path/seattle.txt") } it "should fetch the file from the correct path" do - expect(sftp).to receive(:download!).with("the/whole/path/seattle.txt", "/tmp/somedir/remote-file-sftp-backend-spec-test") + expect(sftp).to receive(:download!).with("/the/whole/path/seattle.txt", "/tmp/somedir/remote-file-sftp-backend-spec-test") fetcher.fetch end end |