Skip to content
Snippets Groups Projects
Commit cd22a722 authored by Xu Cheng's avatar Xu Cheng
Browse files

test: use Formula#full_name

parent c1830828
No related branches found
No related tags found
No related merge requests found
......@@ -11,17 +11,17 @@ module Homebrew
ARGV.resolved_formulae.each do |f|
# Cannot test uninstalled formulae
unless f.installed?
ofail "Testing requires the latest version of #{f.name}"
ofail "Testing requires the latest version of #{f.full_name}"
next
end
# Cannot test formulae without a test method
unless f.test_defined?
ofail "#{f.name} defines no test"
ofail "#{f.full_name} defines no test"
next
end
puts "Testing #{f.name}"
puts "Testing #{f.full_name}"
env = ENV.to_hash
......@@ -48,10 +48,10 @@ module Homebrew
end
end
rescue Assertions::FailedAssertion => e
ofail "#{f.name}: failed"
ofail "#{f.full_name}: failed"
puts e.message
rescue Exception => e
ofail "#{f.name}: failed"
ofail "#{f.full_name}: failed"
puts e, e.backtrace
ensure
ENV.replace(env)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment