view tests/mockblackbox.py @ 28707:af5f90f23515

revset: inline isvalidfunc(), getfuncname() and getfuncargs() See the previous commit for why. These functions are also trivial.
author Yuya Nishihara <yuya@tcha.org>
date Mon, 29 Feb 2016 16:35:58 +0900
parents ac49ecb2a897
children 417380aa5bbe
line wrap: on
line source

from mercurial import util

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

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