[Pkg-puppet-devel] [SCM] Puppet packaging for Debian branch, upstream, updated. puppet-0.24.5-rc3-1601-gf8c1b08

James Turnbull james at lovedthanlost.net
Fri Jan 15 09:07:51 UTC 2010


The following commit has been merged in the upstream branch:
commit 2d88926b76e14c8aa105ad7b1480cee9132fc699
Author: Markus Roberts <Markus at reality.com>
Date:   Thu Dec 17 11:31:25 2009 -0800

    Fix for #2869 (SELinux tests failing under some load orderings)
    
    The problem was that the setup for the tests was expecting the defaultprovider
    for Selboolean and Selmodule to be called, rather than stubbing it.  This
    worked as long as no other spec which initializes the providers was run before
    it.
    
    The fix here (stubbing rather than expecting) is minimal but not ideal; if
    there were some other provider for these types it could result in a test
    indetermenacy (different results depending on which provider) but I'm not
    seeing an easy way to address that.
    
    Signed-off-by: Markus Roberts <Markus at reality.com>

diff --git a/spec/unit/other/selinux.rb b/spec/unit/other/selinux.rb
index 3e39afc..2287570 100644
--- a/spec/unit/other/selinux.rb
+++ b/spec/unit/other/selinux.rb
@@ -28,7 +28,7 @@ end
 describe Puppet::Type.type(:selboolean), " when manipulating booleans" do
     before :each do
         provider_class = Puppet::Type::Selboolean.provider(Puppet::Type::Selboolean.providers[0])
-        Puppet::Type::Selboolean.expects(:defaultprovider).returns provider_class
+        Puppet::Type::Selboolean.stubs(:defaultprovider).returns provider_class
 
         @bool = Puppet::Type::Selboolean.new(
             :name => "foo",
@@ -57,7 +57,7 @@ end
 describe Puppet::Type.type(:selmodule), " when checking policy modules" do
     before :each do
         provider_class = Puppet::Type::Selmodule.provider(Puppet::Type::Selmodule.providers[0])
-        Puppet::Type::Selmodule.expects(:defaultprovider).returns provider_class
+        Puppet::Type::Selmodule.stubs(:defaultprovider).returns provider_class
 
         @module = Puppet::Type::Selmodule.new(
             :name => "foo",

-- 
Puppet packaging for Debian



More information about the Pkg-puppet-devel mailing list