summaryrefslogtreecommitdiffstats
path: root/spec/unit
diff options
context:
space:
mode:
authorJesse Wolfe <jes5199@gmail.com>2010-03-30 16:33:44 -0700
committertest branch <puppet-dev@googlegroups.com>2010-02-17 06:50:53 -0800
commit8f9fc30bb3b992322a553aa7dc0c504af5e44250 (patch)
tree858c75522bc018ff65ae5ca5e0e76158ffc433dc /spec/unit
parent23ccefe0e8b51af19a0283c0d8eb3de09b6e4c31 (diff)
downloadpuppet-8f9fc30bb3b992322a553aa7dc0c504af5e44250.tar.gz
puppet-8f9fc30bb3b992322a553aa7dc0c504af5e44250.tar.xz
puppet-8f9fc30bb3b992322a553aa7dc0c504af5e44250.zip
REST FileBucket: REST barfs on relative paths
Force FileBucket to always send absolute (real) paths
Diffstat (limited to 'spec/unit')
-rwxr-xr-xspec/unit/file_bucket/dipper.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/spec/unit/file_bucket/dipper.rb b/spec/unit/file_bucket/dipper.rb
index 5d6625103..5ada34e9d 100755
--- a/spec/unit/file_bucket/dipper.rb
+++ b/spec/unit/file_bucket/dipper.rb
@@ -4,6 +4,12 @@ require File.dirname(__FILE__) + '/../../spec_helper'
require 'puppet/file_bucket/dipper'
describe Puppet::FileBucket::Dipper do
+ before do
+ ['/my/file'].each do |x|
+ Puppet::FileBucket::Dipper.any_instance.stubs(:absolutize_path).with(x).returns(x)
+ end
+ end
+
it "should fail in an informative way when there are failures backing up to the server" do
File.stubs(:exist?).returns true
File.stubs(:read).returns "content"