mirror of
https://github.com/httprunner/httprunner.git
synced 2026-05-12 02:21:29 +08:00
fix: log_with_color wrapper
This commit is contained in:
@@ -79,10 +79,9 @@ def color_print(msg, color="WHITE"):
|
||||
def log_with_color(level):
|
||||
""" log with color by different level
|
||||
"""
|
||||
_logger = get_logger()
|
||||
|
||||
def wrapper(text):
|
||||
color = log_colors_config[level.upper()]
|
||||
_logger = get_logger()
|
||||
getattr(_logger, level.lower())(coloring(text, color))
|
||||
|
||||
return wrapper
|
||||
|
||||
Reference in New Issue
Block a user