summaryrefslogtreecommitdiff
path: root/spec/unit/provider/file/windows_spec.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/unit/provider/file/windows_spec.rb')
-rwxr-xr-xspec/unit/provider/file/windows_spec.rb14
1 files changed, 7 insertions, 7 deletions
diff --git a/spec/unit/provider/file/windows_spec.rb b/spec/unit/provider/file/windows_spec.rb
index a0e9d3a4e..f6d7ef0e7 100755
--- a/spec/unit/provider/file/windows_spec.rb
+++ b/spec/unit/provider/file/windows_spec.rb
@@ -49,22 +49,22 @@ describe Puppet::Type.type(:file).provider(:windows), :if => Puppet.features.mic
describe "#id2name" do
it "should return the name of the user identified by the sid" do
- Puppet::Util::Windows::Security.expects(:valid_sid?).with(sid).returns(true)
- Puppet::Util::Windows::Security.expects(:sid_to_name).with(sid).returns(account)
+ Puppet::Util::Windows::SID.expects(:valid_sid?).with(sid).returns(true)
+ Puppet::Util::Windows::SID.expects(:sid_to_name).with(sid).returns(account)
provider.id2name(sid).should == account
end
it "should return the argument if it's already a name" do
- Puppet::Util::Windows::Security.expects(:valid_sid?).with(account).returns(false)
- Puppet::Util::Windows::Security.expects(:sid_to_name).never
+ Puppet::Util::Windows::SID.expects(:valid_sid?).with(account).returns(false)
+ Puppet::Util::Windows::SID.expects(:sid_to_name).never
provider.id2name(account).should == account
end
it "should return nil if the user doesn't exist" do
- Puppet::Util::Windows::Security.expects(:valid_sid?).with(sid).returns(true)
- Puppet::Util::Windows::Security.expects(:sid_to_name).with(sid).returns(nil)
+ Puppet::Util::Windows::SID.expects(:valid_sid?).with(sid).returns(true)
+ Puppet::Util::Windows::SID.expects(:sid_to_name).with(sid).returns(nil)
provider.id2name(sid).should == nil
end
@@ -72,7 +72,7 @@ describe Puppet::Type.type(:file).provider(:windows), :if => Puppet.features.mic
describe "#name2id" do
it "should delegate to name_to_sid" do
- Puppet::Util::Windows::Security.expects(:name_to_sid).with(account).returns(sid)
+ Puppet::Util::Windows::SID.expects(:name_to_sid).with(account).returns(sid)
provider.name2id(account).should == sid
end