diff options
Diffstat (limited to 'spec/commands/show_spec.rb')
-rw-r--r-- | spec/commands/show_spec.rb | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/spec/commands/show_spec.rb b/spec/commands/show_spec.rb index 8e3d0194e6..f5e1743b8e 100644 --- a/spec/commands/show_spec.rb +++ b/spec/commands/show_spec.rb @@ -172,6 +172,19 @@ RSpec.describe "bundle show" do expect(out).to include("Installing foo 1.0") end + context "with a valid regexp for gem name" do + it "presents alternatives" do + install_gemfile <<-G + source "file://#{gem_repo1}" + gem "rack" + gem "rack-obama" + G + + bundle "show rac" + expect(out).to eq "1 : rack\n2 : rack-obama\n0 : - exit -\n>" + end + end + context "with an invalid regexp for gem name" do it "does not find the gem" do install_gemfile <<-G |