diff options
| author | Luke Kanies <luke@madstop.com> | 2009-09-19 21:56:05 -0700 |
|---|---|---|
| committer | James Turnbull <james@lovedthanlost.net> | 2009-09-22 09:27:23 +1000 |
| commit | af57483e618ace39c0d4540fd0f8479f5430f0ef (patch) | |
| tree | d9ddab25529e482bb715e9b799b519169f5cb127 /spec/integration/parser | |
| parent | d42bda1f22e3beca321700a78aab9c1399537c30 (diff) | |
Fixing #2632 - 'require' works for 0.25 clients
I couldn't find a way to make it compatible with
earlier clients, so the docs specify that
it doesn't work with them, and it helpfully fails.
Signed-off-by: Luke Kanies <luke@madstop.com>
Diffstat (limited to 'spec/integration/parser')
| -rwxr-xr-x | spec/integration/parser/functions/require.rb | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/spec/integration/parser/functions/require.rb b/spec/integration/parser/functions/require.rb index 79ba13d24..960594b21 100755 --- a/spec/integration/parser/functions/require.rb +++ b/spec/integration/parser/functions/require.rb @@ -10,6 +10,7 @@ describe "the require function" do @compiler = Puppet::Parser::Compiler.new(@node, @parser) @compiler.send(:evaluate_main) + @compiler.catalog.client_version = "0.25" @scope = @compiler.topscope # preload our functions Puppet::Parser::Functions.function(:include) @@ -20,10 +21,11 @@ describe "the require function" do @parser.newclass("requiredclass") @scope.function_require("requiredclass") - - @compiler.catalog.edge?(@scope.resource,@compiler.findresource(:class,"requiredclass")).should be_true + @scope.resource["require"].should_not be_nil + ref = @scope.resource["require"] + ref.type.should == "Class" + ref.title.should == "requiredclass" end - end describe "the include function" do |
