Example #1
0
 def test_get_level_id(self):
     for name, level in (
         ('NOTSET', logger.NOTSET),
         ('DEBUG', logger.DEBUG),
         ('INFO', logger.INFO),
         ('WARNING', logger.WARNING),
         ('ERROR', logger.ERROR),
         ('CRITICAL', logger.CRITICAL),
     ):
         self.assertEqual(logger.get_level_id(level), name)
Example #2
0
 def test_get_level_id(self):
     for name , level in (
         ('NOTSET',   logger.NOTSET),
         ('DEBUG',    logger.DEBUG),
         ('INFO',     logger.INFO),
         ('WARNING',  logger.WARNING),
         ('ERROR',    logger.ERROR),
         ('CRITICAL', logger.CRITICAL),
         ):
         self.assertEqual(logger.get_level_id(level), name)
Example #3
0
 def pythonize(self, val):
     return logger.get_level_id(val)
Example #4
0
 def pythonize(self, val):
     val = unique_value(val)
     return logger.get_level_id(val)
Example #5
0
 def pythonize(self, val):
     return logger.get_level_id(val)
Example #6
0
 def pythonize(self, val):
     val = unique_value(val)
     return logger.get_level_id(val)