def TestConstant(constName, pyConst):
    try:
        comConst = getattr(constants, constName)
    except:
        raise error(('Constant %s missing' % (constName,)))
    if (comConst != pyConst):
        raise error(('Constant value wrong for %s - got %s, wanted %s' % (constName, comConst, pyConst)))
def TestConstant(constName, pyConst):
    try:
        comConst = getattr(constants, constName)
    except:
        raise error(('Constant %s missing' % (constName,)))
    if (comConst != pyConst):
        raise error(('Constant value wrong for %s - got %s, wanted %s' % (constName, comConst, pyConst)))