From abd688ea1a0ebd555eac20185d82cc6430507edf Mon Sep 17 00:00:00 2001 From: Luke Kanies Date: Thu, 28 Feb 2008 15:55:39 -0600 Subject: Fixing #1092 by no longer using the resource reference to look resources up, which means there's no concern about not finding the resource, which is where the nil was coming from. We now just iterate over the vertices. --- spec/unit/parser/compiler.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'spec/unit/parser') diff --git a/spec/unit/parser/compiler.rb b/spec/unit/parser/compiler.rb index 9980f2c6a..ab430da62 100755 --- a/spec/unit/parser/compiler.rb +++ b/spec/unit/parser/compiler.rb @@ -7,7 +7,7 @@ describe Puppet::Parser::Compiler do @node = Puppet::Node.new "testnode" @parser = Puppet::Parser::Parser.new :environment => "development" - @scope_resource = stub 'scope_resource', :builtin? => true + @scope_resource = stub 'scope_resource', :builtin? => true, :finish => nil, :ref => 'Class[main]' @scope = stub 'scope', :resource => @scope_resource, :source => mock("source") @compiler = Puppet::Parser::Compiler.new(@node, @parser) end @@ -529,4 +529,4 @@ describe Puppet::Parser::Compiler do lambda { @compiler.class_set("one", @node) }.should raise_error(Puppet::ParseError) end end -end \ No newline at end of file +end -- cgit