[rubygems/rubygems] Use splatted args to `lockfile_platforms_for`

Nicer :)

https://github.com/rubygems/rubygems/commit/c0ab2893c3
This commit is contained in:
David Rodríguez 2022-04-27 21:03:03 +02:00 коммит произвёл Hiroshi SHIBATA
Родитель c0866f8adb
Коммит f22765f535
5 изменённых файлов: 6 добавлений и 6 удалений

Просмотреть файл

@ -154,7 +154,7 @@ RSpec.describe Bundler::Definition do
only_java (1.1-java)
PLATFORMS
#{lockfile_platforms_for(["java", specific_local_platform])}
#{lockfile_platforms_for("java", specific_local_platform)}
DEPENDENCIES
only_java

Просмотреть файл

@ -674,7 +674,7 @@ RSpec.describe "bundle install from an existing gemspec" do
railties (6.1.4)
PLATFORMS
#{lockfile_platforms_for(["java", specific_local_platform])}
#{lockfile_platforms_for("java", specific_local_platform)}
DEPENDENCIES
activeadmin!

Просмотреть файл

@ -982,7 +982,7 @@ RSpec.describe "the lockfile format" do
rack (1.0.0)
PLATFORMS
#{lockfile_platforms_for(["java", specific_local_platform])}
#{lockfile_platforms_for("java", specific_local_platform)}
DEPENDENCIES
rack

Просмотреть файл

@ -86,7 +86,7 @@ RSpec.describe "Bundler.setup with multi platform stuff" do
racc (1.5.2)
PLATFORMS
#{lockfile_platforms_for(["ruby", specific_local_platform])}
#{lockfile_platforms_for("ruby", specific_local_platform)}
DEPENDENCIES
nokogiri (~> 1.11)

Просмотреть файл

@ -104,10 +104,10 @@ module Spec
end
def lockfile_platforms
lockfile_platforms_for([specific_local_platform])
lockfile_platforms_for(specific_local_platform)
end
def lockfile_platforms_for(platforms)
def lockfile_platforms_for(*platforms)
platforms.map(&:to_s).sort.join("\n ")
end
end