Skip to content

Commit db900dc

Browse files
committed
refactor(Appveyor): Modify Appveyor status checker to log status information
1 parent df8f1a1 commit db900dc

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

test/appveyor_status.rb

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,14 @@ class AppVeyorStatusTest < Minitest::Test
1414
def test_appveyor_status
1515
skip "Branch is NOT master and/or Ruby != 2.5.1, so AppVeyor check before deployment will not be run." if ENV["TRAVIS_BRANCH"] != "master" || ENV["TRAVIS_RUBY_VERSION"] != "2.5.1"
1616
client = HTTP::Client.new
17+
attempts = 0
1718
status = JSON.parse(client.get("https://ci.appveyor.com/api/projects/maxnussbaum/ruby-sdk").body.to_s)["build"]["status"]
19+
puts("0 AppVeyor Status: #{status}")
1820
while status != "success" && status != "failed" && status != "cancelled"
19-
sleep(3)
21+
attempts += 1
22+
sleep(15)
2023
status = JSON.parse(client.get("https://ci.appveyor.com/api/projects/maxnussbaum/ruby-sdk").body.to_s)["build"]["status"]
24+
puts("#{attempts} AppVeyor Status: #{status}")
2125
end
2226
if status == "success"
2327
assert(true)

0 commit comments

Comments
 (0)