test: show internal exception with batchable rpcs over ssh
authorValentin Gatien-Baron <vgatien-baron@janestreet.com>
Thu, 25 Feb 2021 09:59:23 -0500
changeset 46670 fe36ce0fbcdd
parent 46669 e8cd519a0a34
child 46671 fa30292b680b
test: show internal exception with batchable rpcs over ssh Differential Revision: https://phab.mercurial-scm.org/D10072
tests/test-ssh-batch.t
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-ssh-batch.t	Thu Feb 25 09:59:23 2021 -0500
@@ -0,0 +1,13 @@
+  $ hg init a
+  $ cd a
+  $ touch a; hg commit -qAm_
+  $ hg bookmark $(for i in $($TESTDIR/seq.py 0 20); do echo b$i; done)
+  $ hg clone . ../b -q
+  $ cd ../b
+
+Checking that when lookup multiple bookmarks in one go, if one of them
+fails (thus causing the sshpeer to be stopped), the errors from the
+further lookups don't result in tracebacks.
+
+  $ hg pull -r b0 -r nosuchbookmark $(for i in $($TESTDIR/seq.py 1 20); do echo -r b$i; done) -e "\"$PYTHON\" \"$TESTDIR/dummyssh\"" ssh://user@dummy/$(pwd)/../a |& tail -n 1
+  ValueError: I/O operation on closed file