currently i am logging all my test from the console. I mean whatever is being displayed in console is being logged in the log file. However, if there is any exception raised during the script execution it is not being logged though its shows in the console.
Following is my logger class:
class Logging(object):
def __init__(self, *files):
self.files = files
def write(self, obj):
for f in self.files:
f.write(obj)
sys.stdout = functions.Logging(sys.stdout, logfile)}
Thanks, Tejas