[vim/vim] Test function Test_terminal_postponed_scrollback() failed (Issue #12407)

9 views
Skip to first unread message

turkeyRD

unread,
May 17, 2023, 12:46:45 PM5/17/23
to vim/vim, Subscribed

Hi, @brammool
I ran into a problem where a test case was failing, it was always successful before, and suddenly one day it failed. I guess it has something to do with my system environment, but I can't be sure, and I'm not familiar with this test case.

My friend, can you assist me and give me some advice? Tell me why it might fail, that would be very much appreciated.

log:

[  364s] Failures: 
[  364s] 	From test_terminal.vim:
[  364s] 	Found errors in Test_terminal_postponed_scrollback():
[  364s] 	Run 1:
[  364s] 	command line..script /home/abuild/rpmbuild/BUILD/vim90/src/testdir/runtest.vim[464]..function RunTheTest[44]..Test_terminal_postponed_scrollback[24]..VerifyScreenDump line 63: See dump file difference: call term_dumpdiff("testdir/failed/Test_terminal_scrollback_3.dump", "testdir/dumps/Test_terminal_scrollback_3.dump"); difference in line 8: ">o|n|e| |m|o|r|e| |l|i|n|e| @61"; difference in line 9: "@75"
[  364s] 	Run 2:
[  364s] 	command line..script /home/abuild/rpmbuild/BUILD/vim90/src/testdir/runtest.vim[497]..function RunTheTest[44]..Test_terminal_postponed_scrollback[24]..VerifyScreenDump line 63: See dump file difference: call term_dumpdiff("testdir/failed/Test_terminal_scrollback_3.dump", "testdir/dumps/Test_terminal_scrollback_3.dump"); difference in line 8: ">o|n|e| |m|o|r|e| |l|i|n|e| @61"; difference in line 9: "@75"
[  364s] 	Run 3:
[  364s] 	command line..script /home/abuild/rpmbuild/BUILD/vim90/src/testdir/runtest.vim[497]..function RunTheTest[44]..Test_terminal_postponed_scrollback[24]..VerifyScreenDump line 63: See dump file difference: call term_dumpdiff("testdir/failed/Test_terminal_scrollback_3.dump", "testdir/dumps/Test_terminal_scrollback_3.dump"); difference in line 8: ">o|n|e| |m|o|r|e| |l|i|n|e| @61"; difference in line 9: "@75"
[  364s] 	Flaky test failed too often, giving up
[  364s] 
[  364s] TEST FAILURE
[  364s] make[2]: *** [Makefile:49: report] Error 1
[  364s] make[2]: Leaving directory '/home/abuild/rpmbuild/BUILD/vim90/src/testdir'
[  364s] make[1]: *** [Makefile:2234: scripttests] Error 2
[  364s] make[1]: Leaving directory '/home/abuild/rpmbuild/BUILD/vim90/src'
[  364s] make: *** [Makefile:39: test] Error 2
[  364s] error: Bad exit status from /var/tmp/rpm-tmp.4qiq8B (%check)


Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issues/12407@github.com>

Bram Moolenaar

unread,
May 17, 2023, 1:06:11 PM5/17/23
to vim...@googlegroups.com, turkeyRD

> Hi, @brammool
> I ran into a problem where a test case was failing, it was always
> successful before, and suddenly one day it failed. I guess it has
> something to do with my system environment, but I can't be sure, and
> I'm not familiar with this test case.
>
> My friend, can you assist me and give me some advice? Tell me why it
> might fail, that would be very much appreciated.
>
> log:
> ```bash
> [ 364s] Failures:
> [ 364s] From test_terminal.vim:
> [ 364s] Found errors in Test_terminal_postponed_scrollback():
> [ 364s] Run 1:
> [ 364s] command line..script /home/abuild/rpmbuild/BUILD/vim90/src/testdir/runtest.vim[464]..function RunTheTest[44]..Test_terminal_postponed_scrollback[24]..VerifyScreenDump line 63: See dump file difference: call term_dumpdiff("testdir/failed/Test_terminal_scrollback_3.dump", "testdir/dumps/Test_terminal_scrollback_3.dump"); difference in line 8: ">o|n|e| |m|o|r|e| |l|i|n|e| @61"; difference in line 9: "@75"
> [ 364s] Run 2:
> [ 364s] command line..script /home/abuild/rpmbuild/BUILD/vim90/src/testdir/runtest.vim[497]..function RunTheTest[44]..Test_terminal_postponed_scrollback[24]..VerifyScreenDump line 63: See dump file difference: call term_dumpdiff("testdir/failed/Test_terminal_scrollback_3.dump", "testdir/dumps/Test_terminal_scrollback_3.dump"); difference in line 8: ">o|n|e| |m|o|r|e| |l|i|n|e| @61"; difference in line 9: "@75"
> [ 364s] Run 3:
> [ 364s] command line..script /home/abuild/rpmbuild/BUILD/vim90/src/testdir/runtest.vim[497]..function RunTheTest[44]..Test_terminal_postponed_scrollback[24]..VerifyScreenDump line 63: See dump file difference: call term_dumpdiff("testdir/failed/Test_terminal_scrollback_3.dump", "testdir/dumps/Test_terminal_scrollback_3.dump"); difference in line 8: ">o|n|e| |m|o|r|e| |l|i|n|e| @61"; difference in line 9: "@75"
> [ 364s] Flaky test failed too often, giving up
> [ 364s]
> [ 364s] TEST FAILURE
> [ 364s] make[2]: *** [Makefile:49: report] Error 1
> [ 364s] make[2]: Leaving directory '/home/abuild/rpmbuild/BUILD/vim90/src/testdir'
> [ 364s] make[1]: *** [Makefile:2234: scripttests] Error 2
> [ 364s] make[1]: Leaving directory '/home/abuild/rpmbuild/BUILD/vim90/src'
> [ 364s] make: *** [Makefile:39: test] Error 2
> [ 364s] error: Bad exit status from /var/tmp/rpm-tmp.4qiq8B (%check)
> ```

I have not seen this failure. I also see no reason why this would
happen or why it would depend on the environment. The difference is
only the cursor position, indicated by ">" in the screen dump file.

If it fails consistently, you could try adding some delay in between the
commands in the test function:
sleep 2
call TermWait(buf, 500)

You can change the "2" (two seconds) into "100m" (100 milli seconds) or
something else. You can put this before and after the term_sendkeys()
calls. Not sure if it makes any difference.

--
Bumper sticker: Honk if you love peace and quiet.

/// Bram Moolenaar -- Br...@Moolenaar.net -- http://www.Moolenaar.net \\\
/// \\\
\\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///

Christian Brabandt

unread,
May 30, 2023, 3:19:08 AM5/30/23
to vim/vim, Subscribed

you need to inspect the test Test_terminal_postponed_scrollback()

You may want to check out the difference in the dumps using the command given in the output. To do so, go to the src/ directory and run

vim --clean -c 'call term_dumpdiff("testdir/failed/Test_terminal_scrollback_3.dump", "testdir/dumps/Test_terminal_scrollback_3.dump")'

Guessing from the diff output, it seems the terminal window just for the output of the additional line is suddenly much more wider than expected (75 vs 88 columns). Try to run the vim test suite in a terminal with 75 colums, not sure if this helps.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issues/12407/1567896626@github.com>

Bram Moolenaar

unread,
Jun 3, 2023, 4:53:23 PM6/3/23
to vim/vim, Subscribed

Tests can only run in a terminal with at least 80 columns.

The dump file difference indicates that the cursor ends up in a different line.
I can't explain that from the Vim side. Perhaps in your system environment the "tail" command changed?
Do you have an alias for it perhaps?


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issues/12407/1575189495@github.com>

turkeyRD

unread,
Nov 5, 2023, 9:02:37 AM11/5/23
to vim/vim, Subscribed

Closed #12407 as completed.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issue/12407/issue_event/10865062240@github.com>

Reply all
Reply to author
Forward
0 new messages