# HG changeset patch # User Boris Feld # Date 2018-12-09 15:49:55 # Node ID 44378796c5e5eec7bc3bc3881a0399c8050ec712 # Parent 07e181ed82efe7e4c61ea9dc0a58168cc81ba1c1 test: update test-logtoprocess.t to not requires less The test previously assumed that a working pager was present in the test environment. Update it to use the fakepager instead. Differential Revision: https://phab.mercurial-scm.org/D5399 diff --git a/tests/test-logtoprocess.t b/tests/test-logtoprocess.t --- a/tests/test-logtoprocess.t +++ b/tests/test-logtoprocess.t @@ -89,6 +89,16 @@ another file or die after 5 seconds. If script will die after the timeout before we could touch the file and the resulting file will not exists. If not, we will touch the file and see it. + $ cat >> fakepager.py < import sys + > printed = False + > for line in sys.stdin: + > sys.stdout.write(line) + > printed = True + > if not printed: + > sys.stdout.write('paged empty output!\n') + > EOF + $ cat > $TESTTMP/wait-output.sh << EOF > #!/bin/sh > for i in \`$TESTDIR/seq.py 50\`; do @@ -107,6 +117,8 @@ resulting file will not exists. If not, > [extensions] > logtoprocess= > pager= + > [pager] + > pager = "$PYTHON" $TESTTMP/fakepager.py > [logtoprocess] > commandfinish=$TESTTMP/wait-output.sh > EOF