+1 :)
On Nov 2, 2009, at 1:28 PM, Brice Figureau wrote: > > It seems we never finalize the catalog, so the various default > resources are never created including the default schedules. > > Signed-off-by: Brice Figureau <[email protected]> > --- > lib/puppet/configurer.rb | 1 + > spec/unit/configurer.rb | 6 ++++++ > 2 files changed, 7 insertions(+), 0 deletions(-) > > diff --git a/lib/puppet/configurer.rb b/lib/puppet/configurer.rb > index afe56c7..12726e7 100644 > --- a/lib/puppet/configurer.rb > +++ b/lib/puppet/configurer.rb > @@ -123,6 +123,7 @@ class Puppet::Configurer > # Convert a plain resource catalog into our full host catalog. > def convert_catalog(result, duration) > catalog = result.to_ral > + catalog.finalize > catalog.retrieval_duration = duration > catalog.host_config = true > catalog.write_class_file > diff --git a/spec/unit/configurer.rb b/spec/unit/configurer.rb > index 0490967..cd51025 100755 > --- a/spec/unit/configurer.rb > +++ b/spec/unit/configurer.rb > @@ -183,6 +183,12 @@ describe Puppet::Configurer, "when converting > the catalog" do > @agent.convert_catalog(@oldcatalog, 10).should equal(@catalog) > end > > + it "should finalize the catalog" do > + @catalog.expects(:finalize) > + > + @agent.convert_catalog(@oldcatalog, 10) > + end > + > it "should record the passed retrieval time with the RAL > catalog" do > @catalog.expects(:retrieval_duration=).with 10 > > -- > 1.6.4 > > > > -- Tradition is what you resort to when you don't have the time or the money to do it right. -- Kurt Herbert Alder --------------------------------------------------------------------- Luke Kanies | http://reductivelabs.com | http://madstop.com --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Puppet Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/puppet-dev?hl=en -~----------~----~----~----~------~----~------~--~---
