aboutsummaryrefslogtreecommitdiffstats
path: root/spec/bundler/update
diff options
context:
space:
mode:
authorDavid Rodríguez <deivid.rodriguez@riseup.net>2019-05-06 18:06:21 +0200
committerHiroshi SHIBATA <hsbt@ruby-lang.org>2019-08-03 09:29:55 +0900
commitc3ddd47ce7b546530e2241b0ea6a96817977886a (patch)
tree46515c479773d7add25773b536009e096ee9fa78 /spec/bundler/update
parentd8d5e16305ee071f7cf16980788cabcc44799c2e (diff)
downloadruby-c3ddd47ce7b546530e2241b0ea6a96817977886a.tar.gz
[bundler/bundler] Normalize file:// handling in specs
https://github.com/bundler/bundler/commit/5946d62ad0
Diffstat (limited to 'spec/bundler/update')
-rw-r--r--spec/bundler/update/gemfile_spec.rb4
-rw-r--r--spec/bundler/update/gems/post_install_spec.rb6
-rw-r--r--spec/bundler/update/git_spec.rb20
-rw-r--r--spec/bundler/update/redownload_spec.rb2
4 files changed, 16 insertions, 16 deletions
diff --git a/spec/bundler/update/gemfile_spec.rb b/spec/bundler/update/gemfile_spec.rb
index 6c47c254cd..8c2bd9ccbf 100644
--- a/spec/bundler/update/gemfile_spec.rb
+++ b/spec/bundler/update/gemfile_spec.rb
@@ -4,7 +4,7 @@ RSpec.describe "bundle update" do
context "with --gemfile" do
it "finds the gemfile" do
gemfile bundled_app("NotGemfile"), <<-G
- source "file://#{gem_repo1}"
+ source "#{file_uri_for(gem_repo1)}"
gem 'rack'
G
@@ -21,7 +21,7 @@ RSpec.describe "bundle update" do
context "with gemfile set via config" do
before do
gemfile bundled_app("NotGemfile"), <<-G
- source "file://#{gem_repo1}"
+ source "#{file_uri_for(gem_repo1)}"
gem 'rack'
G
diff --git a/spec/bundler/update/gems/post_install_spec.rb b/spec/bundler/update/gems/post_install_spec.rb
index f6b7f39d0b..5b061eb61b 100644
--- a/spec/bundler/update/gems/post_install_spec.rb
+++ b/spec/bundler/update/gems/post_install_spec.rb
@@ -5,7 +5,7 @@ RSpec.describe "bundle update" do
before do
gemfile <<-G
- source "file://#{gem_repo1}"
+ source "#{file_uri_for(gem_repo1)}"
gem 'rack', "< 1.0"
gem 'thin'
G
@@ -47,7 +47,7 @@ RSpec.describe "bundle update" do
context "when listed gem is updated" do
before do
gemfile <<-G
- source "file://#{gem_repo1}"
+ source "#{file_uri_for(gem_repo1)}"
gem 'rack'
gem 'thin'
G
@@ -62,7 +62,7 @@ RSpec.describe "bundle update" do
context "when dependency triggers update" do
before do
gemfile <<-G
- source "file://#{gem_repo1}"
+ source "#{file_uri_for(gem_repo1)}"
gem 'rack-obama'
gem 'thin'
G
diff --git a/spec/bundler/update/git_spec.rb b/spec/bundler/update/git_spec.rb
index bc230a3575..1fc3076368 100644
--- a/spec/bundler/update/git_spec.rb
+++ b/spec/bundler/update/git_spec.rb
@@ -96,7 +96,7 @@ RSpec.describe "bundle update" do
it "fetches tags from the remote" do
build_git "foo"
@remote = build_git("bar", :bare => true)
- update_git "foo", :remote => @remote.path
+ update_git "foo", :remote => file_uri_for(@remote.path)
update_git "foo", :push => "master"
install_gemfile <<-G
@@ -139,7 +139,7 @@ RSpec.describe "bundle update" do
it "it unlocks the source when submodules are added to a git source" do
install_gemfile <<-G
- source "file:#{gem_repo4}"
+ source "#{file_uri_for(gem_repo4)}"
git "#{lib_path("has_submodule-1.0")}" do
gem "has_submodule"
end
@@ -149,7 +149,7 @@ RSpec.describe "bundle update" do
expect(out).to eq("GEM")
install_gemfile <<-G
- source "file:#{gem_repo4}"
+ source "#{file_uri_for(gem_repo4)}"
git "#{lib_path("has_submodule-1.0")}", :submodules => true do
gem "has_submodule"
end
@@ -161,7 +161,7 @@ RSpec.describe "bundle update" do
it "unlocks the source when submodules are removed from git source", :git => ">= 2.9.0" do
install_gemfile! <<-G
- source "file:#{gem_repo4}"
+ source "#{file_uri_for(gem_repo4)}"
git "#{lib_path("has_submodule-1.0")}", :submodules => true do
gem "has_submodule"
end
@@ -171,7 +171,7 @@ RSpec.describe "bundle update" do
expect(out).to eq("GIT")
install_gemfile! <<-G
- source "file:#{gem_repo4}"
+ source "#{file_uri_for(gem_repo4)}"
git "#{lib_path("has_submodule-1.0")}" do
gem "has_submodule"
end
@@ -204,7 +204,7 @@ RSpec.describe "bundle update" do
end
install_gemfile <<-G
- source "file://#{gem_repo1}"
+ source "#{file_uri_for(gem_repo1)}"
gem "rack", :git => "#{lib_path("rack-0.8")}", :branch => "master"
G
@@ -246,7 +246,7 @@ RSpec.describe "bundle update" do
end
install_gemfile <<-G
- source "file://#{gem_repo2}"
+ source "#{file_uri_for(gem_repo2)}"
git "#{lib_path("foo")}" do
gem 'foo'
end
@@ -291,7 +291,7 @@ RSpec.describe "bundle update" do
@git = build_git "foo", :path => lib_path("bar")
install_gemfile <<-G
- source "file://localhost#{gem_repo2}"
+ source "#{file_uri_for(gem_repo2)}"
git "#{lib_path("bar")}" do
gem 'foo'
end
@@ -319,7 +319,7 @@ RSpec.describe "bundle update" do
foo (2.0)
GEM
- remote: file://localhost#{gem_repo2}/
+ remote: #{file_uri_for(gem_repo2)}/
specs:
rack (1.0.0)
@@ -355,7 +355,7 @@ RSpec.describe "bundle update" do
foo (2.0)
GEM
- remote: file://localhost#{gem_repo2}/
+ remote: #{file_uri_for(gem_repo2)}/
specs:
rack (1.0.0)
diff --git a/spec/bundler/update/redownload_spec.rb b/spec/bundler/update/redownload_spec.rb
index 39edac0902..b34a02c78c 100644
--- a/spec/bundler/update/redownload_spec.rb
+++ b/spec/bundler/update/redownload_spec.rb
@@ -3,7 +3,7 @@
RSpec.describe "bundle update" do
before :each do
install_gemfile <<-G
- source "file://#{gem_repo1}"
+ source "#{file_uri_for(gem_repo1)}"
gem "rack"
G
end