From c284da21d2eb9e9cbdc30cd82e9dd46ea4528683 Mon Sep 17 00:00:00 2001 From: Szczepan Zalega Date: Tue, 15 Jan 2019 13:48:49 +0100 Subject: Use logger instead of bare printing Signed-off-by: Szczepan Zalega --- unittest/conftest.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'unittest') diff --git a/unittest/conftest.py b/unittest/conftest.py index bf18fc8..ba21a38 100644 --- a/unittest/conftest.py +++ b/unittest/conftest.py @@ -21,10 +21,17 @@ SPDX-License-Identifier: LGPL-3.0 import pytest -from misc import ffi +from misc import ffi, gs device_type = None +from logging import getLogger, basicConfig, DEBUG + +basicConfig(format='* %(relativeCreated)6d %(filename)s:%(lineno)d %(message)s',level=DEBUG) +log = getLogger('conftest') +print = log.debug + + def skip_if_device_version_lower_than(allowed_devices): global device_type model, version = device_type -- cgit v1.2.3