diff options
author | Bundlerbot <bot@bundler.io> | 2019-03-20 06:15:30 +0000 |
---|---|---|
committer | Bundlerbot <bot@bundler.io> | 2019-03-20 06:15:30 +0000 |
commit | cb2d5ba52ba957e9adbec15bd407fda8b70d9f37 (patch) | |
tree | a8c5131137db4294464c21512b431383d75e5bba | |
parent | 72399ca509105f4aa4f49e1129da2f1abeccc19a (diff) | |
parent | 1237af55f826823cff6b51829e3f7c239d87249f (diff) | |
download | bundler-cb2d5ba52ba957e9adbec15bd407fda8b70d9f37.tar.gz |
Merge #7044
7044: Unskip `--binstubs` flag deprecation r=colby-swandale a=deivid-rodriguez
### What was the end-user problem that led to this PR?
The problem was that some deprecation specs were still skipped.
### What was your diagnosis of the problem?
My diagnosis was that I should get all of them passing.
### What is your fix for the problem, implemented in this PR?
My fix is to uncomment the spec and get it passing. The only fix was to include the full deprecation message so that it matches the assertion.
### Why did you choose this fix out of the possible options?
I could've regexp-matched the existing message but I preferred to use the full message in the assertion instead. I chose this fix because although it makes it more brittle since changing the message _will_ break the test, having the whole messages inside the deprecation specs makes it easier to get a quick view and understand the stuff that we are deprecating and the quality of the existing deprecation messages.
Co-authored-by: David RodrÃguez <deivid.rodriguez@riseup.net>
-rw-r--r-- | spec/other/major_deprecation_spec.rb | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/spec/other/major_deprecation_spec.rb b/spec/other/major_deprecation_spec.rb index c59c08f93c..426b9571a1 100644 --- a/spec/other/major_deprecation_spec.rb +++ b/spec/other/major_deprecation_spec.rb @@ -74,9 +74,16 @@ RSpec.describe "major deprecations" do end describe "bundle install --binstubs" do - xit "should output a deprecation warning" do + before do bundle :install, :binstubs => true - expect(deprecations).to include("The --binstubs option will be removed") + end + + it "should print no deprecations", :bundler => "< 2" do + expect(deprecations).to be_empty + end + + it "should output a deprecation warning", :bundler => "2" do + expect(deprecations).to include("The --binstubs option will be removed in favor of `bundle binstubs`") end end end |