test_win32ole_event.rb: fire message_loop on retry

because it's failing even after sleeping 31s in total.
https://ci.appveyor.com/project/ruby/ruby/builds/19642619/job/pkaj5svr8glk8twt
https://ci.appveyor.com/project/ruby/ruby/builds/19641381/job/spdvrptpaq1d5778

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65188 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
k0kubun 2018-10-20 01:10:09 +00:00
parent 0c1684eb73
commit 8f43080f4b

View File

@ -78,7 +78,8 @@ if defined?(WIN32OLE_EVENT)
tries = 0
while tries < 5 && instance_variable_get(watch_ivar) == orig_ivar
seconds = 2 ** tries # sleep at most 31s in total
$stderr.puts "test_win32ole_event.rb: sleeping #{seconds}s until #{watch_ivar} is changed from #{orig_ivar.inspect}..."
$stderr.puts "test_win32ole_event.rb: retrying and sleeping #{seconds}s until #{watch_ivar} is changed from #{orig_ivar.inspect}..."
WIN32OLE_EVENT.message_loop
sleep(seconds)
tries += 1
end