diff options
author | David RodrÃguez <deivid.rodriguez@riseup.net> | 2023-12-07 22:10:33 +0100 |
---|---|---|
committer | git <svn-admin@ruby-lang.org> | 2023-12-07 22:29:33 +0000 |
commit | 2755cb1b2fbc4a5f08ca56345b5945bd452da74e (patch) | |
tree | 3b4500389edac16971410262ec331bae515e29e4 /spec/bundler/plugins | |
parent | 9d696aa20461d94c2d32e1e474bd036ade20c94d (diff) |
[rubygems/rubygems] Use modern hashes consistently
https://github.com/rubygems/rubygems/commit/bb66253f2c
Diffstat (limited to 'spec/bundler/plugins')
-rw-r--r-- | spec/bundler/plugins/command_spec.rb | 2 | ||||
-rw-r--r-- | spec/bundler/plugins/install_spec.rb | 20 | ||||
-rw-r--r-- | spec/bundler/plugins/source/example_spec.rb | 2 |
3 files changed, 12 insertions, 12 deletions
diff --git a/spec/bundler/plugins/command_spec.rb b/spec/bundler/plugins/command_spec.rb index 3a7adf4b48..af132d6550 100644 --- a/spec/bundler/plugins/command_spec.rb +++ b/spec/bundler/plugins/command_spec.rb @@ -69,7 +69,7 @@ RSpec.describe "command plugins" do end end - bundle "plugin install copycat --source #{file_uri_for(gem_repo2)}", :raise_on_error => false + bundle "plugin install copycat --source #{file_uri_for(gem_repo2)}", raise_on_error: false expect(out).not_to include("Installed plugin copycat") diff --git a/spec/bundler/plugins/install_spec.rb b/spec/bundler/plugins/install_spec.rb index aec131f2ee..ca8e2d2e51 100644 --- a/spec/bundler/plugins/install_spec.rb +++ b/spec/bundler/plugins/install_spec.rb @@ -9,7 +9,7 @@ RSpec.describe "bundler plugin install" do end it "shows proper message when gem in not found in the source" do - bundle "plugin install no-foo --source #{file_uri_for(gem_repo1)}", :raise_on_error => false + bundle "plugin install no-foo --source #{file_uri_for(gem_repo1)}", raise_on_error: false expect(err).to include("Could not find") plugin_should_not_be_installed("no-foo") @@ -23,14 +23,14 @@ RSpec.describe "bundler plugin install" do end it "installs from rubygems source in frozen mode" do - bundle "plugin install foo --source #{file_uri_for(gem_repo2)}", :env => { "BUNDLE_DEPLOYMENT" => "true" } + bundle "plugin install foo --source #{file_uri_for(gem_repo2)}", env: { "BUNDLE_DEPLOYMENT" => "true" } expect(out).to include("Installed plugin foo") plugin_should_be_installed("foo") end it "installs from sources configured as Gem.sources without any flags" do - bundle "plugin install foo", :env => { "BUNDLER_SPEC_GEM_SOURCES" => file_uri_for(gem_repo2).to_s } + bundle "plugin install foo", env: { "BUNDLER_SPEC_GEM_SOURCES" => file_uri_for(gem_repo2).to_s } expect(out).to include("Installed plugin foo") plugin_should_be_installed("foo") @@ -105,7 +105,7 @@ RSpec.describe "bundler plugin install" do end it "raises error when both --branch and --ref options are specified" do - bundle "plugin install foo --source #{file_uri_for(gem_repo2)} --branch main --ref v1.2.3", :raise_on_error => false + bundle "plugin install foo --source #{file_uri_for(gem_repo2)} --branch main --ref v1.2.3", raise_on_error: false expect(out).not_to include("Installed plugin foo") @@ -152,7 +152,7 @@ RSpec.describe "bundler plugin install" do build_gem "charlie" end - bundle "plugin install charlie --source #{file_uri_for(gem_repo2)}", :raise_on_error => false + bundle "plugin install charlie --source #{file_uri_for(gem_repo2)}", raise_on_error: false expect(err).to include("Failed to install plugin `charlie`, due to Bundler::Plugin::MalformattedPlugin (plugins.rb was not found in the plugin.)") @@ -171,7 +171,7 @@ RSpec.describe "bundler plugin install" do end end - bundle "plugin install chaplin --source #{file_uri_for(gem_repo2)}", :raise_on_error => false + bundle "plugin install chaplin --source #{file_uri_for(gem_repo2)}", raise_on_error: false expect(global_plugin_gem("chaplin-1.0")).not_to be_directory @@ -203,7 +203,7 @@ RSpec.describe "bundler plugin install" do end it "raises an error when both git and local git sources are specified" do - bundle "plugin install foo --local_git /phony/path/project --git git@gitphony.com:/repo/project", :raise_on_error => false + bundle "plugin install foo --local_git /phony/path/project --git git@gitphony.com:/repo/project", raise_on_error: false expect(exitstatus).not_to eq(0) expect(err).to eq("Remote and local plugin git sources can't be both specified") @@ -314,7 +314,7 @@ RSpec.describe "bundler plugin install" do end RUBY - ruby code, :env => { "BUNDLER_VERSION" => Bundler::VERSION } + ruby code, env: { "BUNDLER_VERSION" => Bundler::VERSION } expect(local_plugin_gem("foo-1.0", "plugins.rb")).to exist end end @@ -364,7 +364,7 @@ RSpec.describe "bundler plugin install" do end # outside the app - bundle "plugin install fubar --source #{file_uri_for(gem_repo2)}", :dir => tmp + bundle "plugin install fubar --source #{file_uri_for(gem_repo2)}", dir: tmp end it "inside the app takes precedence over global plugin" do @@ -373,7 +373,7 @@ RSpec.describe "bundler plugin install" do end it "outside the app global plugin is used" do - bundle "shout", :dir => tmp + bundle "shout", dir: tmp expect(out).to eq("global_one") end end diff --git a/spec/bundler/plugins/source/example_spec.rb b/spec/bundler/plugins/source/example_spec.rb index 07302e00d7..e569f3e415 100644 --- a/spec/bundler/plugins/source/example_spec.rb +++ b/spec/bundler/plugins/source/example_spec.rb @@ -421,7 +421,7 @@ RSpec.describe "real source plugins" do end it "updates the deps on change in gemfile" do - update_git "ma-gitp-gem", "1.1", :path => lib_path("ma-gitp-gem-1.0"), :gemspec => true + update_git "ma-gitp-gem", "1.1", path: lib_path("ma-gitp-gem-1.0"), gemspec: true gemfile <<-G source "#{file_uri_for(gem_repo2)}" # plugin source source "#{file_uri_for(lib_path("ma-gitp-gem-1.0"))}", :type => :gitp do |