diff options
author | Jesse Wolfe <jes5199@gmail.com> | 2009-12-21 13:08:02 -0800 |
---|---|---|
committer | James Turnbull <james@lovedthanlost.net> | 2009-12-22 10:55:57 +1100 |
commit | b185801835cd656a8c3bab7654a8dddd2a74dba4 (patch) | |
tree | cccf22844a57a5995e5289ac653c286a8e7f9013 /spec/unit/provider | |
parent | 5e5c8b5414a69d79830b79392f0addce245c6911 (diff) | |
download | puppet-b185801835cd656a8c3bab7654a8dddd2a74dba4.tar.gz puppet-b185801835cd656a8c3bab7654a8dddd2a74dba4.tar.xz puppet-b185801835cd656a8c3bab7654a8dddd2a74dba4.zip |
Fixing #2960 Test Failed: 'Puppet::Type::Mount::ProviderParsed when modifying the filesystem tab should write the mount to disk when :flush is called
I found this doing idempotency tests (#2879), but there are apparently
other ways for external state to leak into this test, as reported by
James.
Signed-off-by: Jesse Wolfe <jes5199@gmail.com>
Diffstat (limited to 'spec/unit/provider')
-rwxr-xr-x | spec/unit/provider/mount/parsed.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/spec/unit/provider/mount/parsed.rb b/spec/unit/provider/mount/parsed.rb index cf9feaa94..10329e404 100755 --- a/spec/unit/provider/mount/parsed.rb +++ b/spec/unit/provider/mount/parsed.rb @@ -140,10 +140,12 @@ describe provider_class do end it "should write the mount to disk when :flush is called" do + old_text = @provider_class.target_object(@provider_class.default_target).read + @mount.flush text = @provider_class.target_object(@provider_class.default_target).read - text.should == @mount.class.to_line(@mount.property_hash) + "\n" + text.should == old_text + @mount.class.to_line(@mount.property_hash) + "\n" end end |