To generate the browser logs in a separate file in the folder project dir\logs, the command used in the training video is as below:
System.setProperty(FirefoxDriver.SystemProperty.BROWSER_LOGFILE, "logs\\firefoxlog.log");
Here, just the name of folder is specified, instead of complete path.
Why don't we specify the complete path here as below?
System.getProperty("user.dir"+"\\logs\\"+firefoxlog.log)
Thank you!
Instructor
Ashish Thakur Replied on 27/08/2020
When you are writing this line in a file present inside project then it automatically takes a relative path