comparison tests/f @ 40246:be0a5d2d5c78

tests: fix last failure in test-tools.t Differential Revision: https://phab.mercurial-scm.org/D5072
author Augie Fackler <augie@google.com>
date Sat, 13 Oct 2018 06:34:53 -0400
parents 06c85cbd6824
children da1629c7dda1
comparison
equal deleted inserted replaced
40245:e7e70c033783 40246:be0a5d2d5c78
64 with open(f, 'rb') as fobj: 64 with open(f, 'rb') as fobj:
65 content = fobj.read() 65 content = fobj.read()
66 elif islink: 66 elif islink:
67 if opts.type: 67 if opts.type:
68 facts.append(b'link') 68 facts.append(b'link')
69 content = os.readlink(f) 69 content = os.readlink(f).encode('utf8')
70 elif isstdin: 70 elif isstdin:
71 content = getattr(sys.stdin, 'buffer', sys.stdin).read() 71 content = getattr(sys.stdin, 'buffer', sys.stdin).read()
72 if opts.size: 72 if opts.size:
73 facts.append(b'size=%d' % len(content)) 73 facts.append(b'size=%d' % len(content))
74 elif isdir: 74 elif isdir: