diff options
author | Daniel DeLeo <dan@opscode.com> | 2010-06-10 22:29:54 -0700 |
---|---|---|
committer | Daniel DeLeo <dan@opscode.com> | 2010-06-11 15:19:18 -0700 |
commit | 1ea56c0826a56a9ad5670017819f138c196ee0d0 (patch) | |
tree | ff7b1ecc9a5207688ef213ede3cccc5f18128578 /chef/spec/unit/run_list | |
parent | 263d64f162bd750b4f3507f5efa9031396ba62d6 (diff) | |
download | chef-1ea56c0826a56a9ad5670017819f138c196ee0d0.tar.gz |
fix borken specs
Diffstat (limited to 'chef/spec/unit/run_list')
-rw-r--r-- | chef/spec/unit/run_list/run_list_expansion_spec.rb | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/chef/spec/unit/run_list/run_list_expansion_spec.rb b/chef/spec/unit/run_list/run_list_expansion_spec.rb index 53573c6684..13a964feb9 100644 --- a/chef/spec/unit/run_list/run_list_expansion_spec.rb +++ b/chef/spec/unit/run_list/run_list_expansion_spec.rb @@ -80,4 +80,22 @@ describe Chef::RunList::RunListExpansion do @expansion.override_attrs.should == {'baz' => 'qux'} end end + + describe "after expanding a run list with a non existant role" do + before do + @expansion.stub!(:fetch_role) { @expansion.role_not_found('crabrevenge') } + @expansion.expand + end + + it "is invalid" do + @expansion.should be_invalid + @expansion.errors?.should be_true # aliases + end + + it "has a list of invalid role names" do + @expansion.errors.should include('crabrevenge') + end + + end + end |