changeset 44640:51ffb2a6c08a

tests: pass str to matchoutput() It accepts a str, not bytes. This fixes a failure in test-hghave.t on Windows. Why it wasn't failing on Linux, I don't know. I suspect the Windows process code in Python doesn't accept bytes and the POSIX code does? Differential Revision: https://phab.mercurial-scm.org/D8334
author Gregory Szorc <gregory.szorc@gmail.com>
date Sat, 28 Mar 2020 09:21:46 -0700
parents bc847878f4c0
children e74af49aa3c9
files tests/hghave.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/tests/hghave.py	Tue Mar 31 19:44:28 2020 -0700
+++ b/tests/hghave.py	Sat Mar 28 09:21:46 2020 -0700
@@ -335,7 +335,7 @@
 @check("rust", "Using the Rust extensions")
 def has_rust():
     """Check is the mercurial currently running is using some rust code"""
-    cmd = b'hg debuginstall --quiet 2>&1'
+    cmd = 'hg debuginstall --quiet 2>&1'
     match = br'checking module policy \(([^)]+)\)'
     policy = matchoutput(cmd, match)
     if not policy: