diff options
author | Utkarsh Gupta <utkarsh@debian.org> | 2020-06-19 16:14:18 +0530 |
---|---|---|
committer | Hiroshi SHIBATA <hsbt@ruby-lang.org> | 2020-07-15 16:05:12 +0900 |
commit | 3b0d2a3d6ddd4f3d361e15af96881275e8923a5e (patch) | |
tree | 5b6b5fad9de78ab0b8096ebe866ec4eabb5760ce /lib/bundler/templates/newgem/spec | |
parent | 2b73f26fdefc88d25daf0d712105f4340c239062 (diff) |
[rubygems/rubygems] Fix RuboCop offenses
These offenses appear when you create a gem with
`bundle gem foo` and run `rubocop` over it.
Initially, there were around 45 offenses detected,
but with #3731 and this, the number of offenses
have been reduced to 2.
Signed-off-by: Utkarsh Gupta <utkarsh@debian.org>
https://github.com/rubygems/rubygems/commit/fe9dcaa1b4
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/3275
Diffstat (limited to 'lib/bundler/templates/newgem/spec')
-rw-r--r-- | lib/bundler/templates/newgem/spec/newgem_spec.rb.tt | 2 | ||||
-rw-r--r-- | lib/bundler/templates/newgem/spec/spec_helper.rb.tt | 2 |
2 files changed, 4 insertions, 0 deletions
diff --git a/lib/bundler/templates/newgem/spec/newgem_spec.rb.tt b/lib/bundler/templates/newgem/spec/newgem_spec.rb.tt index c63b487830..82cada988c 100644 --- a/lib/bundler/templates/newgem/spec/newgem_spec.rb.tt +++ b/lib/bundler/templates/newgem/spec/newgem_spec.rb.tt @@ -1,3 +1,5 @@ +# frozen_string_literal: true + RSpec.describe <%= config[:constant_name] %> do it "has a version number" do expect(<%= config[:constant_name] %>::VERSION).not_to be nil diff --git a/lib/bundler/templates/newgem/spec/spec_helper.rb.tt b/lib/bundler/templates/newgem/spec/spec_helper.rb.tt index 805cf57e01..0bb8e6f165 100644 --- a/lib/bundler/templates/newgem/spec/spec_helper.rb.tt +++ b/lib/bundler/templates/newgem/spec/spec_helper.rb.tt @@ -1,3 +1,5 @@ +# frozen_string_literal: true + require "bundler/setup" require "<%= config[:namespaced_path] %>" |