diff options
author | Bram Moolenaar <Bram@vim.org> | 2022-09-03 13:58:47 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2022-09-03 13:58:47 +0100 |
commit | 06d32a0c177e4166ff0491668cd459464bc2ef45 (patch) | |
tree | 7170e33bcc8e37240d37f053e9bb75aa17c09de8 /src/testdir/runtest.vim | |
parent | 89083466fa565bea22832687ec5fe89a70a3b8f7 (diff) |
patch 9.0.0369: a failing flaky test doesn't mention the timev9.0.0369
Problem: A failing flaky test doesn't mention the time.
Solution: Add the time for debugging. Improve error message.
Diffstat (limited to 'src/testdir/runtest.vim')
-rw-r--r-- | src/testdir/runtest.vim | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/testdir/runtest.vim b/src/testdir/runtest.vim index c7140e5300..91977c9491 100644 --- a/src/testdir/runtest.vim +++ b/src/testdir/runtest.vim @@ -465,6 +465,7 @@ for g:testfunc in sort(s:tests) " A test can set g:test_is_flaky to retry running the test. let g:test_is_flaky = 0 + let starttime = strftime("%T") call RunTheTest(g:testfunc) " Repeat a flaky test. Give up when: @@ -475,10 +476,10 @@ for g:testfunc in sort(s:tests) \ && $TEST_NO_RETRY == '' \ && g:test_is_flaky while 1 - call add(s:messages, 'Found errors in ' . g:testfunc . ':') + call add(s:messages, 'Found errors in ' .. g:testfunc .. ':') call extend(s:messages, v:errors) - call add(total_errors, 'Run ' . g:run_nr . ':') + call add(total_errors, starttime .. ' Run ' .. g:run_nr .. ':') call extend(total_errors, v:errors) if g:run_nr >= 5 || prev_error == v:errors[0] @@ -498,6 +499,7 @@ for g:testfunc in sort(s:tests) let v:errors = [] let g:run_nr += 1 + let starttime = strftime("%T") call RunTheTest(g:testfunc) if len(v:errors) == 0 |