diff options
author | Utkarsh Gupta <utkarsh@debian.org> | 2020-06-16 19:07:21 +0530 |
---|---|---|
committer | Hiroshi SHIBATA <hsbt@ruby-lang.org> | 2020-06-18 19:14:15 +0900 |
commit | 22ee047f7328f05e75634d4c4b177a94642c4032 (patch) | |
tree | 40bf9fbdb0d574c41334a6f779f6de100741d76d | |
parent | ec98d5615360c33fa2419b22cf2ac7d1834d9c18 (diff) | |
download | ruby-22ee047f7328f05e75634d4c4b177a94642c4032.tar.gz |
[rubygems/rubygems] Only add .rubocop.yml when --rubocop flag is passed
Signed-off-by: Utkarsh Gupta <utkarsh@debian.org>
https://github.com/rubygems/rubygems/commit/ef2dae4222
-rw-r--r-- | lib/bundler/cli/gem.rb | 1 | ||||
-rw-r--r-- | spec/bundler/commands/newgem_spec.rb | 7 |
2 files changed, 0 insertions, 8 deletions
diff --git a/lib/bundler/cli/gem.rb b/lib/bundler/cli/gem.rb index df93fd92a6..5b4e436d99 100644 --- a/lib/bundler/cli/gem.rb +++ b/lib/bundler/cli/gem.rb @@ -79,7 +79,6 @@ module Bundler ] templates.merge!("gitignore.tt" => ".gitignore") if Bundler.git_present? - templates.merge!("rubocop.yml.tt" => ".rubocop.yml") if test_framework = ask_and_set_test_framework config[:test] = test_framework diff --git a/spec/bundler/commands/newgem_spec.rb b/spec/bundler/commands/newgem_spec.rb index 0216e31019..d0add6dfde 100644 --- a/spec/bundler/commands/newgem_spec.rb +++ b/spec/bundler/commands/newgem_spec.rb @@ -326,7 +326,6 @@ RSpec.describe "bundle gem" do expect(bundled_app("#{gem_name}/lib/#{require_path}.rb")).to exist expect(bundled_app("#{gem_name}/lib/#{require_path}/version.rb")).to exist expect(bundled_app("#{gem_name}/.gitignore")).to exist - expect(bundled_app("#{gem_name}/.rubocop.yml")).to exist expect(bundled_app("#{gem_name}/bin/setup")).to exist expect(bundled_app("#{gem_name}/bin/console")).to exist @@ -385,12 +384,6 @@ RSpec.describe "bundle gem" do expect(bundled_app("#{gem_name}/lib/#{require_path}.rb").read).to match(/class Error < StandardError; end$/) end - it "creates a default .rubocop.yml" do - bundle "gem #{gem_name}" - - expect(bundled_app("#{gem_name}/.rubocop.yml")).to exist - end - it "runs rake without problems" do bundle "gem #{gem_name}" |