summaryrefslogtreecommitdiffstats
path: root/spec/integration/util/file_locking.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/integration/util/file_locking.rb')
-rwxr-xr-xspec/integration/util/file_locking.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/spec/integration/util/file_locking.rb b/spec/integration/util/file_locking.rb
index 680b3d1ed..e584f9ef1 100755
--- a/spec/integration/util/file_locking.rb
+++ b/spec/integration/util/file_locking.rb
@@ -7,8 +7,9 @@ require 'puppet/util/file_locking'
describe Puppet::Util::FileLocking do
it "should be able to keep file corruption from happening when there are multiple writers" do
file = Tempfile.new("puppetspec")
+ filepath = file.path
file.close!()
- file = file.path
+ file = filepath
data = {:a => :b, :c => "A string", :d => "another string", :e => %w{an array of strings}}
File.open(file, "w") { |f| f.puts YAML.dump(data) }