summaryrefslogtreecommitdiffstats
path: root/spec/integration
diff options
context:
space:
mode:
Diffstat (limited to 'spec/integration')
-rwxr-xr-xspec/integration/network/server/webrick_spec.rb14
-rwxr-xr-xspec/integration/type/tidy_spec.rb2
-rwxr-xr-xspec/integration/util/autoload_spec.rb2
3 files changed, 8 insertions, 10 deletions
diff --git a/spec/integration/network/server/webrick_spec.rb b/spec/integration/network/server/webrick_spec.rb
index 2390fcab1..7365462d3 100755
--- a/spec/integration/network/server/webrick_spec.rb
+++ b/spec/integration/network/server/webrick_spec.rb
@@ -4,7 +4,9 @@ require 'puppet/network/server'
require 'puppet/ssl/certificate_authority'
require 'socket'
-describe Puppet::Network::Server do
+describe Puppet::Network::Server, :unless => Puppet.features.microsoft_windows? do
+ include PuppetSpec::Files
+
describe "when using webrick" do
before :each do
Puppet[:servertype] = 'webrick'
@@ -12,11 +14,10 @@ describe Puppet::Network::Server do
@params = { :port => 34343, :handlers => [ :node ], :xmlrpc_handlers => [ :status ] }
# Get a safe temporary file
- @tmpfile = Tempfile.new("webrick_integration_testing")
- @dir = @tmpfile.path + "_dir"
+ dir = tmpdir("webrick_integration_testing")
- Puppet.settings[:confdir] = @dir
- Puppet.settings[:vardir] = @dir
+ Puppet.settings[:confdir] = dir
+ Puppet.settings[:vardir] = dir
Puppet.settings[:group] = Process.gid
Puppet::SSL::Host.ca_location = :local
@@ -26,11 +27,8 @@ describe Puppet::Network::Server do
end
after do
- @tmpfile.delete
Puppet.settings.clear
- system("rm -rf #{@dir}")
-
Puppet::SSL::Host.ca_location = :none
end
diff --git a/spec/integration/type/tidy_spec.rb b/spec/integration/type/tidy_spec.rb
index 08a24099c..d1bb62d6e 100755
--- a/spec/integration/type/tidy_spec.rb
+++ b/spec/integration/type/tidy_spec.rb
@@ -12,7 +12,7 @@ describe Puppet::Type.type(:tidy) do
end
# Testing #355.
- it "should be able to remove dead links", :fails_on_windows => true do
+ it "should be able to remove dead links", :unless => Puppet.features.microsoft_windows? do
dir = tmpfile("tidy_link_testing")
link = File.join(dir, "link")
target = tmpfile("no_such_file_tidy_link_testing")
diff --git a/spec/integration/util/autoload_spec.rb b/spec/integration/util/autoload_spec.rb
index 771e6a718..92fc6554c 100755
--- a/spec/integration/util/autoload_spec.rb
+++ b/spec/integration/util/autoload_spec.rb
@@ -94,7 +94,7 @@ describe Puppet::Util::Autoload do
}
end
- it "should be able to load files directly from modules", :fails_on_windows => true do
+ it "should be able to load files directly from modules" do
modulepath = tmpfile("autoload_module_testing")
libdir = File.join(modulepath, "mymod", "lib", "foo")
FileUtils.mkdir_p(libdir)