summaryrefslogtreecommitdiff
path: root/spec/bundler/install/gems/native_extensions_spec.rb
diff options
context:
space:
mode:
authorDaniel Niknam <mhmd.niknam@gmail.com>2021-07-25 01:27:02 +1000
committerHiroshi SHIBATA <hsbt@ruby-lang.org>2021-07-27 09:25:57 +0900
commit2f9e0cf1819b8679abe79494f622e1a42d7e021d (patch)
tree6ea1693b78ff3769dde6f7c5a24d2547c26f755e /spec/bundler/install/gems/native_extensions_spec.rb
parentb500e8fab445d5a4ad91fd71e622aff88d0c7dd6 (diff)
[rubygems/rubygems] Explicitly define a global source for tests
This is in preparation for deprecating source-less gemfiles. https://github.com/rubygems/rubygems/commit/d6493fa3e2
Diffstat (limited to 'spec/bundler/install/gems/native_extensions_spec.rb')
-rw-r--r--spec/bundler/install/gems/native_extensions_spec.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/spec/bundler/install/gems/native_extensions_spec.rb b/spec/bundler/install/gems/native_extensions_spec.rb
index 8a4de3cf92..d5cafcfc2c 100644
--- a/spec/bundler/install/gems/native_extensions_spec.rb
+++ b/spec/bundler/install/gems/native_extensions_spec.rb
@@ -78,6 +78,7 @@ RSpec.describe "installing a gem with native extensions", :ruby_repo do
bundle "config set build.c_extension --with-c_extension=hello"
install_gemfile <<-G
+ source "#{file_uri_for(gem_repo1)}"
gem "c_extension", :git => #{lib_path("c_extension-1.0").to_s.dump}
G
@@ -126,11 +127,13 @@ RSpec.describe "installing a gem with native extensions", :ruby_repo do
# 1st time, require only one gem -- only one of the extensions gets built.
install_gemfile <<-G
+ source "#{file_uri_for(gem_repo1)}"
gem "c_extension_one", :git => #{lib_path("gems").to_s.dump}
G
# 2nd time, require both gems -- we need both extensions to be built now.
install_gemfile <<-G
+ source "#{file_uri_for(gem_repo1)}"
gem "c_extension_one", :git => #{lib_path("gems").to_s.dump}
gem "c_extension_two", :git => #{lib_path("gems").to_s.dump}
G
@@ -171,6 +174,7 @@ RSpec.describe "installing a gem with native extensions", :ruby_repo do
bundle "config set build.c_extension --with-c_extension=hello --with-c_extension_bundle-dir=hola"
install_gemfile <<-G
+ source "#{file_uri_for(gem_repo1)}"
gem "c_extension", :git => #{lib_path("c_extension-1.0").to_s.dump}
G