##// END OF EJS Templates
narrow: fix flaky behavior described in issue6150...
narrow: fix flaky behavior described in issue6150 This has been plaguing the CI for a good while, and it doesn't appear to have an easy fix proposed yet. The solution in this change is to always do an unambiguous (but expensive) lookup in case of comparison. This should always be correct, albeit suboptimal. Differential Revision: https://phab.mercurial-scm.org/D10034

File last commit:

r47043:e5e6282f default
r47280:b994db7c stable
Show More
test-revert-interactive-curses.t
55 lines | 936 B | text/troff | Tads3Lexer
/ tests / test-revert-interactive-curses.t
Matt Harbison
hghave: split apart testing for the curses module and `tic` executable...
r47043 #require curses
Rodrigo Damazio Bovendorp
revert: fix interactive reverting of end-of-file newline changes...
r45713
Revert interactive tests with the Curses interface
$ cat <<EOF >> $HGRCPATH
> [ui]
> interactive = true
> interface = curses
> [experimental]
> crecordtest = testModeCommands
> EOF
TODO: Make a curses version of the other tests from test-revert-interactive.t.
When a line without EOL is selected during "revert -i"
$ hg init $TESTTMP/revert-i-curses-eol
$ cd $TESTTMP/revert-i-curses-eol
$ echo 0 > a
$ hg ci -qAm 0
$ printf 1 >> a
$ hg ci -qAm 1
$ cat a
0
1 (no-eol)
$ cat <<EOF >testModeCommands
> c
> EOF
$ hg revert -ir'.^'
reverting a
$ cat a
0
When a selected line is reverted to have no EOL
$ hg init $TESTTMP/revert-i-curses-eol2
$ cd $TESTTMP/revert-i-curses-eol2
$ printf 0 > a
$ hg ci -qAm 0
$ echo 0 > a
$ hg ci -qAm 1
$ cat a
0
$ cat <<EOF >testModeCommands
> c
> EOF
$ hg revert -ir'.^'
reverting a
$ cat a
0 (no-eol)