From daf0d9db5dc400a9795a5f741c8c63184f5e8982 Mon Sep 17 00:00:00 2001 From: Luke Kanies Date: Wed, 2 Jul 2008 21:16:45 -0500 Subject: Backporting a test that was failing in master, and fixing it Signed-off-by: Luke Kanies --- spec/unit/node/catalog.rb | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'spec/unit/node') diff --git a/spec/unit/node/catalog.rb b/spec/unit/node/catalog.rb index b4f1503da..45174e5e5 100755 --- a/spec/unit/node/catalog.rb +++ b/spec/unit/node/catalog.rb @@ -472,6 +472,11 @@ describe Puppet::Node::Catalog, " when functioning as a resource container" do @catalog.resource("me", "other").should equal(@one) end + it "should ignore conflicting aliases that point to the aliased resource" do + @catalog.alias(@one, "other") + lambda { @catalog.alias(@one, "other") }.should_not raise_error + end + it "should fail to add an alias if the aliased name already exists" do @catalog.add_resource @one proc { @catalog.alias @two, "one" }.should raise_error(ArgumentError) -- cgit