summaryrefslogtreecommitdiff
path: root/spec/runtime/with_unbundled_env_spec.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/runtime/with_unbundled_env_spec.rb')
-rw-r--r--spec/runtime/with_unbundled_env_spec.rb16
1 files changed, 8 insertions, 8 deletions
diff --git a/spec/runtime/with_unbundled_env_spec.rb b/spec/runtime/with_unbundled_env_spec.rb
index 5ddcc24ed4..605bed8254 100644
--- a/spec/runtime/with_unbundled_env_spec.rb
+++ b/spec/runtime/with_unbundled_env_spec.rb
@@ -106,8 +106,8 @@ RSpec.describe "Bundler.with_env helpers" do
it "prints a deprecation", :bundler => 2 do
code = "Bundler.clean_env"
bundle_exec_ruby! code.dump
- expect(last_command.stdboth).to include(
- "[DEPRECATED FOR 2.0] `Bundler.clean_env` has been deprecated in favor of `Bundler.unbundled_env`. " \
+ expect(err).to include(
+ "[DEPRECATED] `Bundler.clean_env` has been deprecated in favor of `Bundler.unbundled_env`. " \
"If you instead want the environment before bundler was originally loaded, use `Bundler.original_env`"
)
end
@@ -115,8 +115,8 @@ RSpec.describe "Bundler.with_env helpers" do
it "does not print a deprecation", :bundler => "< 2" do
code = "Bundler.clean_env"
bundle_exec_ruby! code.dump
- expect(last_command.stdboth).not_to include(
- "[DEPRECATED FOR 2.0] `Bundler.clean_env` has been deprecated in favor of `Bundler.unbundled_env`. " \
+ expect(out).not_to include(
+ "[DEPRECATED] `Bundler.clean_env` has been deprecated in favor of `Bundler.unbundled_env`. " \
"If you instead want the environment before bundler was originally loaded, use `Bundler.original_env`"
)
end
@@ -156,8 +156,8 @@ RSpec.describe "Bundler.with_env helpers" do
it "prints a deprecation", :bundler => 2 do
code = "Bundler.with_clean_env {}"
bundle_exec_ruby! code.dump
- expect(last_command.stdboth).to include(
- "[DEPRECATED FOR 2.0] `Bundler.with_clean_env` has been deprecated in favor of `Bundler.with_unbundled_env`. " \
+ expect(err).to include(
+ "[DEPRECATED] `Bundler.with_clean_env` has been deprecated in favor of `Bundler.with_unbundled_env`. " \
"If you instead want the environment before bundler was originally loaded, use `Bundler.with_original_env`"
)
end
@@ -165,8 +165,8 @@ RSpec.describe "Bundler.with_env helpers" do
it "does not print a deprecation", :bundler => "< 2" do
code = "Bundler.with_clean_env {}"
bundle_exec_ruby! code.dump
- expect(last_command.stdboth).not_to include(
- "[DEPRECATED FOR 2.0] `Bundler.with_clean_env` has been deprecated in favor of `Bundler.with_unbundled_env`. " \
+ expect(out).not_to include(
+ "[DEPRECATED] `Bundler.with_clean_env` has been deprecated in favor of `Bundler.with_unbundled_env`. " \
"If you instead want the environment before bundler was originally loaded, use `Bundler.with_original_env`"
)
end