I use python logging moduleto enter console and text file. I use HTMLTestRunnerto enter the html file. I assume I'm using HTMLTestRunner 0.8.0
However, the problem is that it HTMLTestRunneronly prints expressions print, and the logging module does not print print statements. Is there a way that I can get instructions for logging inside the html file
Below is the htmlrunner code
runner = HTMLTestRunner.HTMLTestRunner(
stream=outfile,
title='Test Report',
description='Regression Test Suite',
verbosity=3
)
result = runner.run(suite)
Edited: I use import unittest, and I use for logging import logging. For HTML runner I useimport HTMLTestRunner
I use logging.infoand to print instructions on the console logging.debug. If I use print instructions using python print, then I do not get this output in the console or in the logs. But for HTML logging, I only have printand operators stderr.
My request is: is there something that HTMLTestRunner.HTMLTestRunnerwill have instructions that are printed to the console using logging.debugandlogging.info
source
share