py3: add b'' prefixes in fakedirstatewritetime.py
# skip-blame because we are just adding b''
Differential Revision: https://phab.mercurial-scm.org/D2350
--- a/tests/fakedirstatewritetime.py Mon Feb 19 15:26:07 2018 +0530
+++ b/tests/fakedirstatewritetime.py Mon Feb 19 15:27:25 2018 +0530
@@ -19,7 +19,7 @@
configtable = {}
configitem = registrar.configitem(configtable)
-configitem('fakedirstatewritetime', 'fakenow',
+configitem(b'fakedirstatewritetime', b'fakenow',
default=None,
)
@@ -39,7 +39,7 @@
def fakewrite(ui, func):
# fake "now" of 'pack_dirstate' only if it is invoked while 'func'
- fakenow = ui.config('fakedirstatewritetime', 'fakenow')
+ fakenow = ui.config(b'fakedirstatewritetime', b'fakenow')
if not fakenow:
# Execute original one, if fakenow isn't configured. This is
# useful to prevent subrepos from executing replaced one,
@@ -49,7 +49,7 @@
# parsing 'fakenow' in YYYYmmddHHMM format makes comparison between
# 'fakenow' value and 'touch -t YYYYmmddHHMM' argument easy
- fakenow = util.parsedate(fakenow, ['%Y%m%d%H%M'])[0]
+ fakenow = util.parsedate(fakenow, [b'%Y%m%d%H%M'])[0]
orig_pack_dirstate = parsers.pack_dirstate
orig_dirstate_getfsnow = dirstate._getfsnow