One of the file spec tests was attempting to use X: as a fully
qualified file path, and the file type was correctly rejecting it,
since it is a relative path. This commit changes the spec test to
expect the file type to raise an exception.

Reviewed-by: Jacob Helwig <ja...@puppetlabs.com>
Signed-off-by: Josh Cooper <j...@puppetlabs.com>
---
Local-branch: ticket/master/8663-windows-spec-tests
 spec/unit/type/file_spec.rb |    5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/spec/unit/type/file_spec.rb b/spec/unit/type/file_spec.rb
index f416e98..6be8acf 100755
--- a/spec/unit/type/file_spec.rb
+++ b/spec/unit/type/file_spec.rb
@@ -305,9 +305,8 @@ describe Puppet::Type.type(:file) do
         file[:path].should == "X:/"
       end
 
-      it "should add a slash to a drive letter", :'fails_on_windows' => true, 
:'fails_on_ruby_1.9.2' => true do
-        file = Puppet::Type::File.new(:path => "X:")
-        file[:path].should == "X:/"
+      it "should not accept a drive letter without a slash", 
:'fails_on_ruby_1.9.2' => true do
+        lambda { Puppet::Type::File.new(:path => "X:") }.should 
raise_error(/File paths must be fully qualified/)
       end
     end
 
-- 
1.7.5.4

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Developers" group.
To post to this group, send email to puppet-dev@googlegroups.com.
To unsubscribe from this group, send email to 
puppet-dev+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/puppet-dev?hl=en.

Reply via email to