From d53bc169861815ce7cffac431f76304c995bb4fa Mon Sep 17 00:00:00 2001 From: Luke Kanies Date: Sat, 19 Sep 2009 21:21:33 -0700 Subject: Adding version information to the catalog for compat We need to be able to do compatibility testing, and this allows us to do so. Signed-off-by: Luke Kanies --- spec/unit/parser/compiler.rb | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'spec/unit/parser') diff --git a/spec/unit/parser/compiler.rb b/spec/unit/parser/compiler.rb index ad6f351bf..41f03f2ac 100755 --- a/spec/unit/parser/compiler.rb +++ b/spec/unit/parser/compiler.rb @@ -131,6 +131,15 @@ describe Puppet::Parser::Compiler do @compiler.topscope.lookupvar("c").should == "d" end + it "should set the client and server versions on the catalog" do + params = {"clientversion" => "2", "serverversion" => "3"} + @node.stubs(:parameters).returns(params) + compile_stub(:set_node_parameters) + @compiler.compile + @compiler.catalog.client_version.should == "2" + @compiler.catalog.server_version.should == "3" + end + it "should evaluate any existing classes named in the node" do classes = %w{one two three four} main = stub 'main' -- cgit