diff options
author | lamont-granquist <lamont@scriptkiddie.org> | 2014-01-30 16:18:36 -0800 |
---|---|---|
committer | lamont-granquist <lamont@scriptkiddie.org> | 2014-01-30 16:18:36 -0800 |
commit | 960463222e123c25a6a6701437a8f375794ac71c (patch) | |
tree | 2bf1f5d51dda3097372fcb4d86eba4fb387e5f08 /spec/unit/application/apply.rb | |
parent | 93e601b61ef3f049760379a94794607f8287903a (diff) | |
parent | f1c684be191f8f13961712fa9c4e6bfc402a95c5 (diff) | |
download | chef-960463222e123c25a6a6701437a8f375794ac71c.tar.gz |
Merge pull request #1238 from opscode/lcg/rspec-2.14-deprecation-warnings
Lcg/rspec 2.14 deprecation warnings
Diffstat (limited to 'spec/unit/application/apply.rb')
-rw-r--r-- | spec/unit/application/apply.rb | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/spec/unit/application/apply.rb b/spec/unit/application/apply.rb index 0dc24544b0..32c98c6ed6 100644 --- a/spec/unit/application/apply.rb +++ b/spec/unit/application/apply.rb @@ -21,7 +21,7 @@ describe Chef::Application::Apply do before do @app = Chef::Application::Recipe.new - @app.stub!(:configure_logging).and_return(true) + @app.stub(:configure_logging).and_return(true) @recipe_text = "package 'nyancat'" Chef::Config[:solo] = true end @@ -36,10 +36,10 @@ describe Chef::Application::Apply do before do @recipe_file_name = "foo.rb" @recipe_path = File.expand_path("foo.rb") - @recipe_file = mock("Tempfile (mock)", :read => @recipe_text) - @app.stub!(:open).with(@recipe_path).and_return(@recipe_file) - File.stub!(:exist?).with("foo.rb").and_return(true) - Chef::Application.stub!(:fatal!).and_return(true) + @recipe_file = double("Tempfile (mock)", :read => @recipe_text) + @app.stub(:open).with(@recipe_path).and_return(@recipe_file) + File.stub(:exist?).with("foo.rb").and_return(true) + Chef::Application.stub(:fatal!).and_return(true) end it "should read text properly" do @app.read_recipe_file(@recipe_file_name)[0].should == @recipe_text @@ -49,7 +49,7 @@ describe Chef::Application::Apply do end describe "when recipe doesn't exist" do before do - File.stub!(:exist?).with(@recipe_file_name).and_return(false) + File.stub(:exist?).with(@recipe_file_name).and_return(false) end it "should raise a fatal" do Chef::Application.should_receive(:fatal!) |