view tests/mockblackbox.py @ 26498:e8564e04382d

lock: add a way to prevent locks from being inherited We want to prevent locks from being inherited sometimes (e.g. when there's a currently running transaction, which will break a lot of assumptions we're making in here.)
author Siddharth Agarwal <sid0@fb.com>
date Tue, 06 Oct 2015 13:13:31 -0700
parents 0ead0a07ed9c
children ac49ecb2a897
line wrap: on
line source

from mercurial import util

def makedate():
    return 0, 0
def getuser():
    return 'bob'

# mock the date and user apis so the output is always the same
def uisetup(ui):
    util.makedate = makedate
    util.getuser = getuser