summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
Diffstat (limited to 'spec')
-rw-r--r--spec/bundler/support/builders.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/spec/bundler/support/builders.rb b/spec/bundler/support/builders.rb
index b2de94601a..cb7f419f42 100644
--- a/spec/bundler/support/builders.rb
+++ b/spec/bundler/support/builders.rb
@@ -245,7 +245,8 @@ module Spec
end
def update_repo(path, build_compact_index: true)
- if path == gem_repo1 && caller.first.split(" ").last != "`build_repo'"
+ exempted_caller = Gem.ruby_version >= Gem::Version.new("3.4.0.dev") ? "#{Module.nesting.first}#build_repo" : "build_repo"
+ if path == gem_repo1 && caller_locations(1, 1).first.label != exempted_caller
raise "Updating gem_repo1 is unsupported -- use gem_repo2 instead"
end
return unless block_given?