Ask a Question

Groovy: Redirect log.info output from console to the file

trans-am
Occasional Contributor

Groovy: Redirect log.info output from console to the file

With Groovy I can create directory and file so following lines works fine:

 

def file = new File("C:/Log") // create directory Log
file.mkdir()
def newFile = new File("C:/Log/log.txt") // create log.txt
newFile.createNewFile() 

 

Now during test execution I want to have all log.info from console window to this file. Already tried few things but file is empty.

 

Any tips?

 

2 REPLIES 2
Shashavali
Contributor

I think you need to change the configuration in the soapui-log4j.xml 

trans-am
Occasional Contributor

Yep, that's what I thought and it requires Admin rights

cancel
Showing results for 
Search instead for 
Did you mean: