Allura/allura/tests/decorators.py
def out_audits(*messages, **kwargs):
    """
    Asserts none the messages exist in audit log.  "without audits"

    :param messages: list of regex strings
    :param bool user: if this is a user log

    """
    M.AuditLog.query.remove()
    yield
    if kwargs.get('user'):
        actor = kwargs.get('actor', '.*')
        ip_addr = kwargs.get('ip_addr', '.*')
        preamble = '(Done by user: {}\n)?IP Address: {}\n'.format(actor, ip_addr)
    else:
        preamble = ''
    for message in messages:
        assert not M.AuditLog.query.find(dict(
            message=re.compile(preamble + message))).count(), 'Found unexpected: "%s"' % message

    Asserts none the messages exist in audit log.  "without audits"

    :param messages: list of regex strings
    :param bool user: if this is a user log

    
Asserts none the messages exist in audit log.  "without audits"
Asserts none the messages exist in audit log . " without audits "
def out_audits(*messages, **kwargs):
    M.AuditLog.query.remove()
    yield
    if kwargs.get('user'):
        actor = kwargs.get('actor', '.*')
        ip_addr = kwargs.get('ip_addr', '.*')
        preamble = '(Done by user: {}\n)?IP Address: {}\n'.format(actor, ip_addr)
    else:
        preamble = ''
    for message in messages:
        assert not M.AuditLog.query.find(dict(
            message=re.compile(preamble + message))).count(), 'Found unexpected: "%s"' % message
def out_audits ( * messages , ** kwargs ) : M . AuditLog . query . remove ( ) yield if kwargs . get ( 'user' ) : actor = kwargs . get ( 'actor' , '.*' ) ip_addr = kwargs . get ( 'ip_addr' , '.*' ) preamble = '(Done by user: {}\n)?IP Address: {}\n' . format ( actor , ip_addr ) else : preamble = '' for message in messages : assert not M . AuditLog . query . find ( dict ( message = re . compile ( preamble + message ) ) ) . count ( ) , 'Found unexpected: "%s"' % message
Asserts none the messages exist in audit log.
Asserts none the messages exist in audit log .
"""
    Asserts none the messages exist in audit log.  "without audits"

    :param messages: list of regex strings
    :param bool user: if this is a user log

    """
messages
list of regex strings
list of regex strings
user
if this is a user log
if this is a user log