зеркало из https://github.com/github/ruby.git
[rubygems/rubygems] Improve gemspec assignment and error message
https://github.com/rubygems/rubygems/commit/dc70c5a192
This commit is contained in:
Родитель
68937fe0e4
Коммит
bcf51dd763
|
@ -62,10 +62,8 @@ Gems can be saved to a specified filename with the output option:
|
|||
|
||||
private
|
||||
|
||||
def build_gem(gemspec = get_one_optional_argument)
|
||||
unless File.exist?(gemspec)
|
||||
gemspec += ".gemspec" if File.exist?(gemspec + ".gemspec")
|
||||
end
|
||||
def build_gem(gem_name = get_one_optional_argument)
|
||||
gemspec = File.exist?(gem_name) ? gem_name : "#{gem_name}.gemspec"
|
||||
|
||||
if File.exist?(gemspec)
|
||||
spec = Gem::Specification.load(gemspec)
|
||||
|
|
|
@ -189,7 +189,7 @@ class TestGemCommandsBuildCommand < Gem::TestCase
|
|||
end
|
||||
|
||||
assert_equal '', @ui.output
|
||||
assert_equal "ERROR: Gemspec file not found: some_gem\n", @ui.error
|
||||
assert_equal "ERROR: Gemspec file not found: some_gem.gemspec\n", @ui.error
|
||||
end
|
||||
|
||||
def test_execute_outside_dir
|
||||
|
|
Загрузка…
Ссылка в новой задаче