]> gitweb.fluxo.info Git - puppet-stdlib.git/commitdiff
Add windows support and work around issue with SCP_TO on windows systems
authorTravis Fields <travis@puppetlabs.com>
Mon, 23 Jun 2014 23:59:46 +0000 (16:59 -0700)
committerTravis Fields <travis@puppetlabs.com>
Mon, 23 Jun 2014 23:59:46 +0000 (16:59 -0700)
spec/spec_helper_acceptance.rb

index 8e56daa6830b7559e103bbd7bd8ff1fec8b617bd..dc2cfdcf7666e450dfad245654cf34ffaf4487a6 100755 (executable)
@@ -6,7 +6,12 @@ UNSUPPORTED_PLATFORMS = []
 unless ENV['RS_PROVISION'] == 'no' or ENV['BEAKER_provision'] == 'no'
   if hosts.first.is_pe?
     install_pe
-    on hosts, 'mkdir -p /etc/puppetlabs/facter/facts.d'
+    hosts.each do |host|
+      if !(host['platform'] =~ /windows/)
+        on host, 'mkdir -p /etc/puppetlabs/facter/facts.d'
+      end
+    end
+
   else
     install_puppet
     on hosts, 'mkdir -p /etc/facter/facts.d'
@@ -26,6 +31,15 @@ RSpec.configure do |c|
 
   # Configure all nodes in nodeset
   c.before :suite do
-    puppet_module_install(:source => proj_root, :module_name => 'stdlib')
+    hosts.each do |host|
+      if host['platform'] !~ /windows/i
+        copy_root_module_to(host, :source => proj_root, :module_name => 'stdlib')
+      end
+    end
+    hosts.each do |host|
+      if host['platform'] =~ /windows/i
+        on host, puppet('plugin download')
+      end
+    end
   end
 end