test: helpers.retry()

This commit is contained in:
Justin M. Keyes
2016-12-07 13:01:03 +01:00
parent 8da23cb919
commit 1a4f13ba8f
2 changed files with 15 additions and 9 deletions

View File

@@ -98,15 +98,7 @@ describe('undo tree:', function()
expect_line('123456abc')
end
-- Retry up to 3 times. pcall() is _not_ used for the final attempt, so
-- that failure messages can bubble up.
for _ = 1, 2 do
local success = pcall(test_earlier_later)
if success then
return
end
end
test_earlier_later()
helpers.retry(test_earlier_later)
end)
it('file-write specifications', function()