summaryrefslogtreecommitdiffstats
path: root/spec/unit/parser
diff options
context:
space:
mode:
authorLuke Kanies <luke@madstop.com>2008-03-18 18:16:03 -0500
committerLuke Kanies <luke@madstop.com>2008-03-18 18:16:03 -0500
commita40e9b7dc58eef2e965e81f6c7be2dc7c14910d9 (patch)
tree133ce47fcf4de7107fd8a351d3bc3eaed9daf66f /spec/unit/parser
parent7d35ae8fed989ef3edb8a304f625786a04ee5faa (diff)
downloadpuppet-a40e9b7dc58eef2e965e81f6c7be2dc7c14910d9.tar.gz
puppet-a40e9b7dc58eef2e965e81f6c7be2dc7c14910d9.tar.xz
puppet-a40e9b7dc58eef2e965e81f6c7be2dc7c14910d9.zip
Fixing some tests that only failed under certain
circumstances (mostly, when loaded with other files, or when loaded from rake or autotest rather than separately).
Diffstat (limited to 'spec/unit/parser')
-rwxr-xr-xspec/unit/parser/resource.rb4
1 files changed, 1 insertions, 3 deletions
diff --git a/spec/unit/parser/resource.rb b/spec/unit/parser/resource.rb
index 1948a3c07..776e9c742 100755
--- a/spec/unit/parser/resource.rb
+++ b/spec/unit/parser/resource.rb
@@ -257,9 +257,7 @@ describe Puppet::Parser::Resource do
it "should fail when the override was not created by a parent class" do
@override.source = "source2"
@override.source.expects(:child_of?).with("source1").returns(false)
- assert_raise(Puppet::ParseError, "Allowed unrelated resources to override") do
- @resource.merge(@override)
- end
+ lambda { @resource.merge(@override) }.should raise_error(Puppet::ParseError)
end
it "should succeed when the override was created in the current scope" do