Commit f4030dc3 authored by Balasankar "Balu" C's avatar Balasankar "Balu" C

Improve language

parent ab78b570
......@@ -67,8 +67,7 @@ module Omnibus
def wait!
loop do
if timeout?
puts "\nWaited for #{((Time.now.to_i - @start)/60)} minutes"
raise 'Pipeline timeout!'
raise "Pipeline timed out after waiting for #{duration} minutes!"
end
case status
......@@ -76,8 +75,7 @@ module Omnibus
print "."
sleep INTERVAL
when :success
puts "\nWaited for #{((Time.now.to_i - @start)/60)} minutes"
puts "Omnibus pipeline succeeded!"
puts "Omnibus pipeline succeeded in #{duration} minutes!"
break
else
raise "Omnibus pipeline did not succeed!"
......@@ -91,6 +89,10 @@ module Omnibus
Time.now.to_i > (@start + MAX_DURATION)
end
def duration
(Time.now.to_i - @start)/60
end
def status
req = Net::HTTP::Get.new(@uri)
req['PRIVATE-TOKEN'] = ENV['GITLAB_QA_ACCESS_TOKEN']
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment