Example #1
0
def test_startlogger_stderr():
    """Does the logging system start (to stderr)?"""
    logfile = logname()
    save = sys.stderr
    out = open(logfile, 'w')
    sys.stderr = out
    config.start_logger(logfile, 'DEBUG', True)
    sys.stderr = save
    tools.eq_(getlines(), 1)
    
Example #2
0
def test_startlogger_file():
    """Does the logging system start (to file)?"""
    logfile = logname()
    config.start_logger(logfile, 'DEBUG')
    tools.eq_(getlines(), 1)