Show More
@@ -7,6 +7,7 b'' | |||
|
7 | 7 | |
|
8 | 8 | from __future__ import absolute_import |
|
9 | 9 | |
|
10 | import codecs | |
|
10 | 11 | import collections |
|
11 | 12 | import difflib |
|
12 | 13 | import errno |
@@ -997,8 +998,8 b' def debuginstall(ui, **opts):' | |||
|
997 | 998 | fm.write('encoding', _("checking encoding (%s)...\n"), encoding.encoding) |
|
998 | 999 | err = None |
|
999 | 1000 | try: |
|
1000 | encoding.fromlocal("test") | |
|
1001 |
except |
|
|
1001 | codecs.lookup(pycompat.sysstr(encoding.encoding)) | |
|
1002 | except LookupError as inst: | |
|
1002 | 1003 | err = inst |
|
1003 | 1004 | problems += 1 |
|
1004 | 1005 | fm.condwrite(err, 'encodingerror', _(" %s\n" |
@@ -76,6 +76,11 b' hg debuginstall with no username' | |||
|
76 | 76 | 1 problems detected, please check your install! |
|
77 | 77 | [1] |
|
78 | 78 | |
|
79 | hg debuginstall with invalid encoding | |
|
80 | $ HGENCODING=invalidenc hg debuginstall | grep encoding | |
|
81 | checking encoding (invalidenc)... | |
|
82 | unknown encoding: invalidenc | |
|
83 | ||
|
79 | 84 | path variables are expanded (~ is the same as $TESTTMP) |
|
80 | 85 | $ mkdir tools |
|
81 | 86 | $ touch tools/testeditor.exe |
General Comments 0
You need to be logged in to leave comments.
Login now