Fix deprecation warnings from log.warn and inspect.getargspec

Signed-off-by: Chenxiong Qi <cqi@redhat.com>
This commit is contained in:
Chenxiong Qi
2018-11-23 23:01:08 +08:00
parent 25b6a93a07
commit 0c642a0944
12 changed files with 41 additions and 36 deletions

View File

@@ -77,7 +77,7 @@ class TestLogger:
# No log file should be created.
log.debug("ignore this test msg")
log.info("ignore this test msg")
log.warn("ignore this test msg")
log.warning("ignore this test msg")
log.error("ignore this test msg")
self.build_log.stop(build)
assert not os.path.exists(path)
@@ -89,13 +89,13 @@ class TestLogger:
MBSConsumer.current_module_build_id = 1
log.debug("ignore this test msg1")
log.info("ignore this test msg1")
log.warn("ignore this test msg1")
log.warning("ignore this test msg1")
log.error("ignore this test msg1")
MBSConsumer.current_module_build_id = 2
log.debug("ignore this test msg2")
log.info("ignore this test msg2")
log.warn("ignore this test msg2")
log.warning("ignore this test msg2")
log.error("ignore this test msg2")
self.build_log.stop(build)
@@ -111,7 +111,7 @@ class TestLogger:
MBSConsumer.current_module_build_id = 2
log.debug("ignore this test msg3")
log.info("ignore this test msg3")
log.warn("ignore this test msg3")
log.warning("ignore this test msg3")
log.error("ignore this test msg3")
self.build_log.stop(build)
with open(path, "r") as f: