Try fix upload_spec flakys and remove logging from tasks/uploads_spec

This commit is contained in:
Martin Brennan
2020-02-18 15:08:58 +10:00
parent 64b3512084
commit 500185dc11
4 changed files with 12 additions and 9 deletions

View File

@@ -2,10 +2,12 @@
class RakeHelpers
def self.print_status_with_label(label, current, max)
return if Rails.env.test? && !ENV['RAILS_ENABLE_TEST_LOG']
print "\r\033[K%s%9d / %d (%5.1f%%)" % [label, current, max, ((current.to_f / max.to_f) * 100).round(1)]
end
def self.print_status(current, max)
return if Rails.env.test? && !ENV['RAILS_ENABLE_TEST_LOG']
print "\r\033[K%9d / %d (%5.1f%%)" % [current, max, ((current.to_f / max.to_f) * 100).round(1)]
end
end