test-dispatch: make the test compatible with chg
The test is broken when run with chg because it prints a different
error message when chg is running. This commit fixes the test by special casing
for chg.
Test Plan:
Ran the test 'test-dispatch.t' with and without '--chg' option.
Differential Revision: https://phab.mercurial-scm.org/D1126
--- a/tests/test-dispatch.t Mon Oct 16 12:15:00 2017 -0700
+++ b/tests/test-dispatch.t Mon Oct 16 17:14:21 2017 -0700
@@ -69,7 +69,8 @@
$ cd $TESTTMP/repo1
$ rm -rf $TESTTMP/repo1
$ HGDEMANDIMPORT=disable hg version -q
- abort: error getting current working directory: * (glob)
+ abort: error getting current working directory: * (glob) (no-chg !)
+ chg: abort: failed to getcwd (errno = *) (glob) (chg !)
[255]
#endif