mirror of
https://github.com/ruby/ruby.git
synced 2025-08-15 13:39:04 +02:00
[rubygems/rubygems] Fix assertions to not depend on specific gem name
27a4af859e
This commit is contained in:
parent
e95adbfa68
commit
8a802f7e4e
1 changed files with 7 additions and 7 deletions
|
@ -190,7 +190,7 @@ RSpec.describe "bundle gem" do
|
|||
|
||||
it "generates a gem skeleton with rubocop" do
|
||||
gem_skeleton_assertions
|
||||
expect(bundled_app("test-gem/Rakefile")).to read_as(
|
||||
expect(bundled_app("#{gem_name}/Rakefile")).to read_as(
|
||||
include("# frozen_string_literal: true").
|
||||
and(include('require "rubocop/rake_task"').
|
||||
and(include("RuboCop::RakeTask.new").
|
||||
|
@ -227,8 +227,8 @@ RSpec.describe "bundle gem" do
|
|||
|
||||
it "generates a gem skeleton without rubocop" do
|
||||
gem_skeleton_assertions
|
||||
expect(bundled_app("test-gem/Rakefile")).to read_as(exclude("rubocop"))
|
||||
expect(bundled_app("test-gem/#{gem_name}.gemspec")).to read_as(exclude("rubocop"))
|
||||
expect(bundled_app("#{gem_name}/Rakefile")).to read_as(exclude("rubocop"))
|
||||
expect(bundled_app("#{gem_name}/#{gem_name}.gemspec")).to read_as(exclude("rubocop"))
|
||||
end
|
||||
|
||||
it "does not include rubocop in generated Gemfile" do
|
||||
|
@ -257,7 +257,7 @@ RSpec.describe "bundle gem" do
|
|||
|
||||
it "generates a gem skeleton with rubocop" do
|
||||
gem_skeleton_assertions
|
||||
expect(bundled_app("test-gem/Rakefile")).to read_as(
|
||||
expect(bundled_app("#{gem_name}/Rakefile")).to read_as(
|
||||
include("# frozen_string_literal: true").
|
||||
and(include('require "rubocop/rake_task"').
|
||||
and(include("RuboCop::RakeTask.new").
|
||||
|
@ -290,7 +290,7 @@ RSpec.describe "bundle gem" do
|
|||
|
||||
it "generates a gem skeleton with standard" do
|
||||
gem_skeleton_assertions
|
||||
expect(bundled_app("test-gem/Rakefile")).to read_as(
|
||||
expect(bundled_app("#{gem_name}/Rakefile")).to read_as(
|
||||
include('require "standard/rake"').
|
||||
and(match(/default:.+:standard/))
|
||||
)
|
||||
|
@ -323,8 +323,8 @@ RSpec.describe "bundle gem" do
|
|||
|
||||
it "generates a gem skeleton without rubocop" do
|
||||
gem_skeleton_assertions
|
||||
expect(bundled_app("test-gem/Rakefile")).to read_as(exclude("rubocop"))
|
||||
expect(bundled_app("test-gem/#{gem_name}.gemspec")).to read_as(exclude("rubocop"))
|
||||
expect(bundled_app("#{gem_name}/Rakefile")).to read_as(exclude("rubocop"))
|
||||
expect(bundled_app("#{gem_name}/#{gem_name}.gemspec")).to read_as(exclude("rubocop"))
|
||||
end
|
||||
|
||||
it "does not include rubocop in generated Gemfile" do
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue