mirror of
https://github.com/ViViDboarder/abuse-the-force.git
synced 2024-11-25 05:46:36 +00:00
Fix bug when running tests and there are no errors
This commit is contained in:
parent
ca9b5dcd2a
commit
3f5c5c095b
@ -130,12 +130,15 @@ module AbuseTheForce
|
|||||||
|
|
||||||
# Need messages in an array
|
# Need messages in an array
|
||||||
if result.run_test_result != nil
|
if result.run_test_result != nil
|
||||||
|
|
||||||
|
puts "TESTS RUN: #{result.run_test_result.num_tests_run} FAILURES: #{result.run_test_result.num_failures}"
|
||||||
|
|
||||||
|
if result.run_test_result.failures != nil
|
||||||
|
|
||||||
unless result.run_test_result.failures.kind_of? Array
|
unless result.run_test_result.failures.kind_of? Array
|
||||||
result.run_test_result.failures = [].push result.run_test_result.failures
|
result.run_test_result.failures = [].push result.run_test_result.failures
|
||||||
end
|
end
|
||||||
|
|
||||||
puts "TESTS RUN: #{result.run_test_result.num_tests_run} FAILURES: #{result.run_test_result.num_failures}"
|
|
||||||
|
|
||||||
result.run_test_result.failures.each do |m|
|
result.run_test_result.failures.each do |m|
|
||||||
|
|
||||||
# Print our error in teh format "filename:line:column type in object message"
|
# Print our error in teh format "filename:line:column type in object message"
|
||||||
@ -148,6 +151,7 @@ module AbuseTheForce
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
end
|
||||||
}.
|
}.
|
||||||
on_error { |job| puts "Something bad happened!" }.
|
on_error { |job| puts "Something bad happened!" }.
|
||||||
on_poll { |job| puts "Polling for #{job.id}!" }.
|
on_poll { |job| puts "Polling for #{job.id}!" }.
|
||||||
|
Loading…
Reference in New Issue
Block a user