diff options
author | Terence Lee <hone02@gmail.com> | 2012-10-09 16:50:55 -1000 |
---|---|---|
committer | Terence Lee <hone02@gmail.com> | 2012-10-09 16:51:54 -1000 |
commit | 944a78293b0bc0f508a70ee99530d251297c5bcc (patch) | |
tree | 241595f7f787339e934b1c89cda83a287faa1c3b /spec/other/open_spec.rb | |
parent | 3fa809a13eeded67b1e8b3e421071f40c1f4b8f4 (diff) | |
download | bundler-944a78293b0bc0f508a70ee99530d251297c5bcc.tar.gz |
change to new expect syntax for rspec
Diffstat (limited to 'spec/other/open_spec.rb')
-rw-r--r-- | spec/other/open_spec.rb | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/spec/other/open_spec.rb b/spec/other/open_spec.rb index cf58cc67..6a601943 100644 --- a/spec/other/open_spec.rb +++ b/spec/other/open_spec.rb @@ -10,31 +10,31 @@ describe "bundle open" do it "opens the gem with BUNDLER_EDITOR as highest priority" do bundle "open rails", :env => {"EDITOR" => "echo editor", "VISUAL" => "echo visual", "BUNDLER_EDITOR" => "echo bundler_editor"} - out.should == "bundler_editor #{default_bundle_path('gems', 'rails-2.3.2')}" + expect(out).to eq("bundler_editor #{default_bundle_path('gems', 'rails-2.3.2')}") end it "opens the gem with VISUAL as 2nd highest priority" do bundle "open rails", :env => {"EDITOR" => "echo editor", "VISUAL" => "echo visual", "BUNDLER_EDITOR" => ""} - out.should == "visual #{default_bundle_path('gems', 'rails-2.3.2')}" + expect(out).to eq("visual #{default_bundle_path('gems', 'rails-2.3.2')}") end it "opens the gem with EDITOR as 3rd highest priority" do bundle "open rails", :env => {"EDITOR" => "echo editor", "VISUAL" => "", "BUNDLER_EDITOR" => ""} - out.should == "editor #{default_bundle_path('gems', 'rails-2.3.2')}" + expect(out).to eq("editor #{default_bundle_path('gems', 'rails-2.3.2')}") end it "complains if no EDITOR is set" do bundle "open rails", :env => {"EDITOR" => "", "VISUAL" => "", "BUNDLER_EDITOR" => ""} - out.should == "To open a bundled gem, set $EDITOR or $BUNDLER_EDITOR" + expect(out).to eq("To open a bundled gem, set $EDITOR or $BUNDLER_EDITOR") end it "complains if gem not in bundle" do bundle "open missing", :env => {"EDITOR" => "echo editor", "VISUAL" => "", "BUNDLER_EDITOR" => ""} - out.should match(/could not find gem 'missing'/i) + expect(out).to match(/could not find gem 'missing'/i) end it "suggests alternatives for similar-sounding gems" do bundle "open Rails", :env => {"EDITOR" => "echo editor", "VISUAL" => "", "BUNDLER_EDITOR" => ""} - out.should match(/did you mean rails\?/i) + expect(out).to match(/did you mean rails\?/i) end end |